57
57
import com .oracle .graal .python .nodes .builtins .FunctionNodesFactory .GetSignatureNodeGen ;
58
58
import com .oracle .truffle .api .Assumption ;
59
59
import com .oracle .truffle .api .dsl .Cached ;
60
+ import com .oracle .truffle .api .dsl .GenerateUncached ;
60
61
import com .oracle .truffle .api .dsl .ImportStatic ;
61
62
import com .oracle .truffle .api .dsl .Specialization ;
62
63
63
64
public abstract class FunctionNodes {
65
+ @ GenerateUncached
64
66
public abstract static class GetFunctionDefaultsNode extends PNodeWithContext {
65
67
public abstract Object [] execute (PFunction function );
66
68
@@ -83,6 +85,7 @@ public static GetFunctionDefaultsNode create() {
83
85
}
84
86
85
87
@ ImportStatic (PGuards .class )
88
+ @ GenerateUncached
86
89
public abstract static class GetDefaultsNode extends PNodeWithContext {
87
90
private static Object [] doFunctionInternal (GetFunctionDefaultsNode getFunctionDefaultsNode , PFunction function ) {
88
91
return getFunctionDefaultsNode .execute (function );
@@ -118,6 +121,7 @@ public static GetDefaultsNode create() {
118
121
}
119
122
}
120
123
124
+ @ GenerateUncached
121
125
public abstract static class GetFunctionKeywordDefaultsNode extends PNodeWithContext {
122
126
public abstract PKeyword [] execute (PFunction function );
123
127
@@ -140,6 +144,7 @@ public static GetFunctionKeywordDefaultsNode create() {
140
144
}
141
145
142
146
@ ImportStatic (PGuards .class )
147
+ @ GenerateUncached
143
148
public abstract static class GetKeywordDefaultsNode extends PNodeWithContext {
144
149
private static PKeyword [] doFunctionInternal (GetFunctionKeywordDefaultsNode getFunctionKeywordDefaultsNode , PFunction function ) {
145
150
return getFunctionKeywordDefaultsNode .execute (function );
@@ -175,6 +180,7 @@ public static GetKeywordDefaultsNode create() {
175
180
}
176
181
}
177
182
183
+ @ GenerateUncached
178
184
public abstract static class GetFunctionCodeNode extends PNodeWithContext {
179
185
public abstract PCode execute (PFunction function );
180
186
@@ -186,7 +192,7 @@ PCode getCodeCached(@SuppressWarnings("unused") PFunction self,
186
192
return cachedCode ;
187
193
}
188
194
189
- @ Specialization
195
+ @ Specialization ( replaces = "getCodeCached" )
190
196
PCode getCodeUncached (PFunction self ) {
191
197
return self .getCode ();
192
198
}
@@ -197,6 +203,7 @@ public static GetFunctionCodeNode create() {
197
203
}
198
204
199
205
@ ImportStatic (PGuards .class )
206
+ @ GenerateUncached
200
207
public abstract static class GetSignatureNode extends PNodeWithContext {
201
208
private static Signature doFunctionInternal (GetFunctionCodeNode getFunctionCodeNode , PFunction function ) {
202
209
return getFunctionCodeNode .execute (function ).getSignature ();
0 commit comments