Class CudaMemoryAlignment
- Namespace
- DotCompute.Backends.CUDA.Types
- Assembly
- DotCompute.Backends.CUDA.dll
CUDA memory alignment requirements
public static class CudaMemoryAlignment
- Inheritance
-
CudaMemoryAlignment
- Inherited Members
Fields
MinAlignment
The min alignment.
public const int MinAlignment = 256
Field Value
OptimalAlignment
The optimal alignment.
public const int OptimalAlignment = 512
Field Value
SurfaceAlignment
The surface alignment.
public const int SurfaceAlignment = 512
Field Value
TextureAlignment
The texture alignment.
public const int TextureAlignment = 512
Field Value
Methods
AlignUp(long, int)
Gets align up.
public static long AlignUp(long size, int alignment = 512)
Parameters
Returns
- long
The result of the operation.
IsAligned(long, int)
Determines whether aligned.
public static bool IsAligned(long size, int alignment = 512)
Parameters
Returns
- bool
true if the condition is met; otherwise, false.