Library/ManagedCuda/CudaBlas/CudaBlasHandler.cs
/// <summary>
/// This function computes the dot product of vectors x and y.
/// </summary>
/// <param name="x"></param>
/// <param name="incx"></param>
/// <param name="y"></param>
/// <param name="incy"></param>
This function computes the dot product of vectors x and y.
This function computes the dot product of vectors x and y .
public float Dot(CudaDeviceVariable<float> x, int incx, CudaDeviceVariable<float> y, int incy)
		{
			float result = 0;
			_status = CudaBlasNativeMethods.cublasSdot_v2(_blasHandle, x.Size, x.DevicePointer, incx, y.DevicePointer, incy, ref result);
			Debug.WriteLine(String.Format("{0:G}, {1}: {2}", DateTime.Now, "cublasSdot_v2", _status));
			if (_status != CublasStatus.Success) throw new CudaBlasException(_status);
			return result;
		}
public float Dot ( CudaDeviceVariable < float > x , int incx , CudaDeviceVariable < float > y , int incy ) { float result = 0 ; _status = CudaBlasNativeMethods . cublasSdot_v2 ( _blasHandle , x . Size , x . DevicePointer , incx , y . DevicePointer , incy , ref result ) ; Debug . WriteLine ( String . Format ( " " , DateTime . Now , " " , _status ) ) ; if ( _status != CublasStatus . Success ) throw new CudaBlasException ( _status ) ; return result ; }
This function computes the dot product of vectors x and y.
This function computes the dot product of vectors x and y .
x
CudaDeviceVariable<float>
None
incx
int
None
y
CudaDeviceVariable<float>
None
incy
int
None