Skip to content

Commit 4f051a2

Browse files
committed
Enable uncached Bytecode DSL interpreter
1 parent 2690c0d commit 4f051a2

49 files changed

Lines changed: 115 additions & 69 deletions

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/asyncio/GetAwaitableNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@
6262
import com.oracle.truffle.api.nodes.Node;
6363

6464
@GenerateUncached
65-
@OperationProxy.Proxyable(storeBytecodeIndex = true)
65+
@OperationProxy.Proxyable(allowUncached = true, storeBytecodeIndex = true)
6666
@GenerateInline(false)
6767
public abstract class GetAwaitableNode extends Node {
6868
public abstract Object execute(VirtualFrame frame, Object arg);

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/common/HashingStorage.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@
7575
import com.oracle.truffle.api.dsl.Fallback;
7676
import com.oracle.truffle.api.dsl.GenerateCached;
7777
import com.oracle.truffle.api.dsl.GenerateInline;
78+
import com.oracle.truffle.api.dsl.GenerateUncached;
7879
import com.oracle.truffle.api.dsl.NeverDefault;
7980
import com.oracle.truffle.api.dsl.Specialization;
8081
import com.oracle.truffle.api.frame.VirtualFrame;
@@ -190,6 +191,7 @@ public static HashingStorage addKeyValuesToStorage(VirtualFrame frame, HashingSt
190191
// partial impl dict_update_arg
191192
@GenerateCached
192193
@GenerateInline(false)
194+
@GenerateUncached
193195
public abstract static class ObjectToArrayPairNode extends PNodeWithContext {
194196
public abstract ArrayBuilder<KeyValue> execute(VirtualFrame frame, Object mapping, Object keyAttr);
195197

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/dict/DictNodes.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -131,6 +131,7 @@ static void doForeign(Object dict, HashingStorage oldStorage, HashingStorage new
131131
}
132132

133133
@GenerateInline(false) // footprint reduction 52 -> 36
134+
@GenerateUncached
134135
public abstract static class UpdateNode extends PNodeWithContext {
135136
public abstract void execute(Frame frame, Object self, Object other);
136137

@@ -155,6 +156,7 @@ public static UpdateNode create() {
155156
}
156157

157158
@GenerateInline
159+
@GenerateUncached
158160
@GenerateCached(false)
159161
public abstract static class UpdateInnerNode extends PNodeWithContext {
160162
public abstract void execute(Frame frame, Node inliningTarget, Object self, HashingStorage selfStorage, Object other, Object otherStorage);

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/set/SetNodes.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ public static ConstructSetNode getUncached() {
117117
}
118118

119119
@GenerateUncached
120-
@OperationProxy.Proxyable(storeBytecodeIndex = true)
120+
@OperationProxy.Proxyable(storeBytecodeIndex = true, allowUncached = true)
121121
@GenerateInline(false) // footprint reduction 92 -> 73
122122
public abstract static class AddNode extends PNodeWithContext {
123123
public abstract void execute(Frame frame, PSet self, Object o);

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberAddNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@
7575

7676
@GenerateInline(false)
7777
@GenerateUncached
78-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
78+
@OperationProxy.Proxyable(allowUncached = true, storeBytecodeIndex = false)
7979
public abstract class PyNumberAddNode extends PyNumberAddFastPathsBase {
8080

8181
@Specialization(guards = {"isBuiltinList(left)", "isBuiltinList(right)"})

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberAndNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
@GenerateInline(false)
5858
@GenerateUncached
59-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
59+
@OperationProxy.Proxyable(storeBytecodeIndex = false, allowUncached = true)
6060
public abstract class PyNumberAndNode extends PyNumberAndFastPathsBase {
6161

6262
@Fallback

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberFloorDivideNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@
5555

5656
@GenerateInline(false)
5757
@GenerateUncached
58-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
58+
@OperationProxy.Proxyable(storeBytecodeIndex = false, allowUncached = true)
5959
public abstract class PyNumberFloorDivideNode extends PyNumberFloorDivideFastPathsBase {
6060

6161
@Fallback

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberInPlaceAddNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767

6868
@GenerateInline(false)
6969
@GenerateUncached
70-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
70+
@OperationProxy.Proxyable(allowUncached = true, storeBytecodeIndex = false)
7171
public abstract class PyNumberInPlaceAddNode extends PyNumberAddFastPathsBase {
7272

7373
@Fallback

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberInPlaceAndNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
@GenerateInline(false)
5858
@GenerateUncached
59-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
59+
@OperationProxy.Proxyable(allowUncached = true, storeBytecodeIndex = false)
6060
public abstract class PyNumberInPlaceAndNode extends PyNumberAndFastPathsBase {
6161
@Fallback
6262
@InliningCutoff

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/lib/PyNumberInPlaceFloorDivideNode.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@
5656

5757
@GenerateInline(false)
5858
@GenerateUncached
59-
@OperationProxy.Proxyable(storeBytecodeIndex = false)
59+
@OperationProxy.Proxyable(allowUncached = true, storeBytecodeIndex = false)
6060
public abstract class PyNumberInPlaceFloorDivideNode extends PyNumberFloorDivideFastPathsBase {
6161
@Fallback
6262
@InliningCutoff

0 commit comments

Comments
 (0)