Class ShadowBuffer
java.lang.Object
org.apache.sysds.runtime.instructions.gpu.context.ShadowBuffer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidRemoves the content from shadow bufferbooleanCheck if the gpu object is shadow bufferedbooleanisEligibleForBuffering(boolean isEviction, boolean eagerDelete) Checks if the GPU object is eligible for shadow bufferingvoidmoveFromDevice(String instName) Move the data from GPU to shadow buffervoidMove the data from shadow buffer to GPUvoidMove the data from shadow buffer to Matrix object
-
Constructor Details
-
ShadowBuffer
-
-
Method Details
-
isBuffered
public boolean isBuffered()Check if the gpu object is shadow buffered- Returns:
- true if the gpu object is shadow buffered
-
moveFromDevice
Move the data from GPU to shadow buffer- Parameters:
instName- name of the instruction
-
moveToHost
public void moveToHost()Move the data from shadow buffer to Matrix object -
moveToDevice
public void moveToDevice()Move the data from shadow buffer to GPU -
isEligibleForBuffering
public boolean isEligibleForBuffering(boolean isEviction, boolean eagerDelete) Checks if the GPU object is eligible for shadow buffering- Parameters:
isEviction- true if this method is called during evictioneagerDelete- true if the data on device has to be eagerly deleted- Returns:
- true if the given GPU object is eligible to be shadow buffered
-
clearShadowPointer
public void clearShadowPointer()Removes the content from shadow buffer
-