/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws jcuda.CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * If the given result is different to cublasStatus.CUBLAS_STATUS_SUCCESS * and exceptions have been enabled, this method will throw a * CudaException with an error message that corresponds to the * given result code. Otherwise, the given result is simply * returned. * * @param result The result to check * @return The result that was given as the parameter * @throws CudaException If exceptions have been enabled and * the given result code is not cublasStatus.CUBLAS_STATUS_SUCCESS */ private static int checkResult(int result) { if (exceptionsEnabled && result != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(result)); } return result; }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }
/** * Obtain the current CUBLAS status by calling cublasGetErrorNative, * and store the result as the lastResult. If the obtained result * code is not cublasStatus.CUBLAS_STATUS_SUCCESS and exceptions * have been enabled, an CudaException will be thrown. */ private static void checkResultBLAS() { if (exceptionsEnabled) { lastResult = cublasGetErrorNative(); if (lastResult != cublasStatus.CUBLAS_STATUS_SUCCESS) { throw new CudaException(cublasStatus.stringFor(lastResult)); } } }