Package com.oracle.truffle.api.bytecode
Class BytecodeDSLAccess
java.lang.Object
com.oracle.truffle.api.bytecode.BytecodeDSLAccess
Accessor class used to abstract away frame and bytecode array accesses in the generated code.
Do not use directly.
- Since:
- 24.2
-
Method Summary
Modifier and TypeMethodDescriptionabstract ByteArraySupport
Returns aByteArraySupport
to use for byte array accesses.abstract FrameExtensions
Returns aFrameExtensions
to use for frame accesses.static final BytecodeDSLAccess
Obtains an accessor.abstract int
readInt
(int[] arr, int index) Reads from an int array.abstract <T> T
readObject
(T[] arr, int index) Reads from an Object array.abstract <T> T
uncheckedCast
(Object arr, Class<T> clazz) Casts a value to the given class.abstract void
writeInt
(int[] arr, int index, int value) Writes to an int array.abstract <T> void
writeObject
(T[] arr, int index, T value) Writes to an Object array.
-
Method Details
-
lookup
Obtains an accessor. Used by generated code; do not use directly.- Since:
- 24.2
-
getByteArraySupport
Returns aByteArraySupport
to use for byte array accesses.- Since:
- 24.2
-
getFrameExtensions
Returns aFrameExtensions
to use for frame accesses.- Since:
- 24.2
-
readInt
public abstract int readInt(int[] arr, int index) Reads from an int array.- Since:
- 24.2
-
writeInt
public abstract void writeInt(int[] arr, int index, int value) Writes to an int array.- Since:
- 24.2
-
readObject
public abstract <T> T readObject(T[] arr, int index) Reads from an Object array.- Since:
- 24.2
-
writeObject
public abstract <T> void writeObject(T[] arr, int index, T value) Writes to an Object array.- Since:
- 24.2
-
uncheckedCast
Casts a value to the given class. Also assumes non-null.- Since:
- 24.2
-