Mercurial > hg > truffle
comparison graal/com.oracle.truffle.api.test/src/com/oracle/truffle/api/test/FrameTest.java @ 14991:64dcb92ee75a
Truffle: Change signature for Truffle calls from (PackedFrame, Arguments) to (Object[]).
author | Thomas Wuerthinger <thomas.wuerthinger@oracle.com> |
---|---|
date | Sun, 06 Apr 2014 17:46:24 +0200 |
parents | a08b8694f556 |
children |
comparison
equal
deleted
inserted
replaced
14989:a0dbb3628f2a | 14991:64dcb92ee75a |
---|---|
28 import com.oracle.truffle.api.frame.*; | 28 import com.oracle.truffle.api.frame.*; |
29 import com.oracle.truffle.api.nodes.*; | 29 import com.oracle.truffle.api.nodes.*; |
30 | 30 |
31 /** | 31 /** |
32 * <h3>Storing Values in Frame Slots</h3> | 32 * <h3>Storing Values in Frame Slots</h3> |
33 * | 33 * |
34 * <p> | 34 * <p> |
35 * The frame is the preferred data structure for passing values between nodes. It can in particular | 35 * The frame is the preferred data structure for passing values between nodes. It can in particular |
36 * be used for storing the values of local variables of the guest language. The | 36 * be used for storing the values of local variables of the guest language. The |
37 * {@link FrameDescriptor} represents the current structure of the frame. The method | 37 * {@link FrameDescriptor} represents the current structure of the frame. The method |
38 * {@link FrameDescriptor#addFrameSlot(Object, FrameSlotKind)} can be used to create predefined | 38 * {@link FrameDescriptor#addFrameSlot(Object, FrameSlotKind)} can be used to create predefined |
39 * frame slots. The setter and getter methods in the {@link Frame} class can be used to access the | 39 * frame slots. The setter and getter methods in the {@link Frame} class can be used to access the |
40 * current value of a particular frame slot. Values can be removed from a frame via the | 40 * current value of a particular frame slot. Values can be removed from a frame via the |
41 * {@link FrameDescriptor#removeFrameSlot(Object)} method. | 41 * {@link FrameDescriptor#removeFrameSlot(Object)} method. |
42 * </p> | 42 * </p> |
43 * | 43 * |
44 * <p> | 44 * <p> |
45 * There are five primitive types for slots available: {@link java.lang.Boolean}, | 45 * There are five primitive types for slots available: {@link java.lang.Boolean}, |
46 * {@link java.lang.Integer}, {@link java.lang.Long}, {@link java.lang.Float}, and | 46 * {@link java.lang.Integer}, {@link java.lang.Long}, {@link java.lang.Float}, and |
47 * {@link java.lang.Double} . It is encouraged to use those types whenever possible. Dynamically | 47 * {@link java.lang.Double} . It is encouraged to use those types whenever possible. Dynamically |
48 * typed languages can speculate on the type of a value fitting into a primitive (see | 48 * typed languages can speculate on the type of a value fitting into a primitive (see |
51 * {@link Frame#getBoolean}, {@link Frame#getInt}, {@link Frame#getLong}, {@link Frame#getFloat}, or | 51 * {@link Frame#getBoolean}, {@link Frame#getInt}, {@link Frame#getLong}, {@link Frame#getFloat}, or |
52 * {@link Frame#getDouble}) or setter method ({@link Frame#setBoolean}, {@link Frame#setInt}, | 52 * {@link Frame#getDouble}) or setter method ({@link Frame#setBoolean}, {@link Frame#setInt}, |
53 * {@link Frame#setLong}, {@link Frame#setFloat}, or {@link Frame#setDouble}) in the {@link Frame} | 53 * {@link Frame#setLong}, {@link Frame#setFloat}, or {@link Frame#setDouble}) in the {@link Frame} |
54 * class. | 54 * class. |
55 * </p> | 55 * </p> |
56 * | 56 * |
57 * <p> | 57 * <p> |
58 * The next part of the Truffle API introduction is at | 58 * The next part of the Truffle API introduction is at |
59 * {@link com.oracle.truffle.api.test.FrameSlotTypeSpecializationTest}. | 59 * {@link com.oracle.truffle.api.test.FrameSlotTypeSpecializationTest}. |
60 * </p> | 60 * </p> |
61 */ | 61 */ |