Interface GpuRuntime
public interface GpuRuntime
-
Method Summary
Modifier and TypeMethodDescriptionvoidallocBuffers(int[] ids, int[] sizes, int count) default voidallocTypedBuffers(int[] ids, int[] sizes, DType[] dtypes, int count) Physical element counts and dtypes, independent of logical Tensor shape.voiddownloadBuffer(int bufId, float[] out) default voiddownloadBuffer16(int bufId, short[] out) voidflushOps(int[] cmdStream, int cmdStreamLength) default voidflushOps(int[] commands, int length, long[] layouts) voidreleaseBuffers(int[] ids, int count) default booleanvoiduploadBuffer(int bufId, float[] data) default voiduploadBuffer16(int bufId, short[] data) default voidzeroBuffer(int bufId, int floatCount) Initializes the whole buffer with positive zero; custom runtimes retain a portable fallback.default voidzeroBuffer(int bufId, int elements, DType dtype)
-
Method Details
-
supportsLayouts
default boolean supportsLayouts() -
allocBuffers
void allocBuffers(int[] ids, int[] sizes, int count) -
allocTypedBuffers
Physical element counts and dtypes, independent of logical Tensor shape. -
uploadBuffer
void uploadBuffer(int bufId, float[] data) -
uploadBuffer16
default void uploadBuffer16(int bufId, short[] data) -
zeroBuffer
default void zeroBuffer(int bufId, int floatCount) Initializes the whole buffer with positive zero; custom runtimes retain a portable fallback. -
downloadBuffer
void downloadBuffer(int bufId, float[] out) -
downloadBuffer16
default void downloadBuffer16(int bufId, short[] out) -
zeroBuffer
-
releaseBuffers
void releaseBuffers(int[] ids, int count) -
flushOps
void flushOps(int[] cmdStream, int cmdStreamLength) -
flushOps
default void flushOps(int[] commands, int length, long[] layouts)
-