@@ -131,8 +131,8 @@ Object callSpecialMethodSlotCallTarget(VirtualFrame frame, BuiltinMethodDescript
131
131
return invokeNode .execute (frame , callTarget , arguments );
132
132
}
133
133
134
- @ Specialization (guards = {"func == cachedFunc" , "builtinNode != null" ,
135
- "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" , assumptions = "singleContextAssumption()" )
134
+ @ Specialization (guards = {"isSingleContext()" , " func == cachedFunc" , "builtinNode != null" ,
135
+ "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
136
136
static Object callObjectSingleContext (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinFunction func , Object arg1 , Object arg2 ,
137
137
@ SuppressWarnings ("unused" ) @ Cached ("func" ) PBuiltinFunction cachedFunc ,
138
138
@ SuppressWarnings ("unused" ) @ Cached ("isForReverseBinaryOperation(func.getCallTarget())" ) boolean isReverse ,
@@ -145,7 +145,8 @@ static Object callObjectSingleContext(VirtualFrame frame, @SuppressWarnings("unu
145
145
}
146
146
}
147
147
148
- @ Specialization (guards = {"func.getCallTarget() == ct" , "builtinNode != null" , "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
148
+ @ Specialization (guards = {"func.getCallTarget() == ct" , "builtinNode != null" , "frame != null || unusedFrame" }, //
149
+ limit = "getCallSiteInlineCacheMaxDepth()" )
149
150
static Object callObject (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinFunction func , Object arg1 , Object arg2 ,
150
151
@ SuppressWarnings ("unused" ) @ Cached ("func.getCallTarget()" ) RootCallTarget ct ,
151
152
@ SuppressWarnings ("unused" ) @ Cached ("isForReverseBinaryOperation(func.getCallTarget())" ) boolean isReverse ,
@@ -158,8 +159,8 @@ static Object callObject(VirtualFrame frame, @SuppressWarnings("unused") PBuilti
158
159
}
159
160
}
160
161
161
- @ Specialization (guards = {"func == cachedFunc" , "builtinNode != null" , "!takesSelfArg" ,
162
- "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" , assumptions = "singleContextAssumption()" )
162
+ @ Specialization (guards = {"isSingleContext()" , " func == cachedFunc" , "builtinNode != null" , "!takesSelfArg" ,
163
+ "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
163
164
static Object callMethodSingleContext (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinMethod func , Object arg1 , Object arg2 ,
164
165
@ SuppressWarnings ("unused" ) @ Cached ("func" ) PBuiltinMethod cachedFunc ,
165
166
@ SuppressWarnings ("unused" ) @ Cached ("takesSelfArg(func)" ) boolean takesSelfArg ,
@@ -168,8 +169,8 @@ static Object callMethodSingleContext(VirtualFrame frame, @SuppressWarnings("unu
168
169
return builtinNode .execute (frame , arg1 , arg2 );
169
170
}
170
171
171
- @ Specialization (guards = {"func == cachedFunc" , "builtinNode != null" , "takesSelfArg" ,
172
- "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" , assumptions = "singleContextAssumption()" )
172
+ @ Specialization (guards = {"isSingleContext()" , " func == cachedFunc" , "builtinNode != null" , "takesSelfArg" ,
173
+ "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
173
174
static Object callSelfMethodSingleContext (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinMethod func , Object arg1 , Object arg2 ,
174
175
@ SuppressWarnings ("unused" ) @ Cached (value = "func" , weak = true ) PBuiltinMethod cachedFunc ,
175
176
@ SuppressWarnings ("unused" ) @ Cached ("takesSelfArg(func)" ) boolean takesSelfArg ,
@@ -178,7 +179,8 @@ static Object callSelfMethodSingleContext(VirtualFrame frame, @SuppressWarnings(
178
179
return builtinNode .execute (frame , func .getSelf (), arg1 , arg2 );
179
180
}
180
181
181
- @ Specialization (guards = {"builtinNode != null" , "getCallTarget(func, getCt) == ct" , "!takesSelfArg" , "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
182
+ @ Specialization (guards = {"builtinNode != null" , "getCallTarget(func, getCt) == ct" , "!takesSelfArg" ,
183
+ "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
182
184
static Object callMethod (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinMethod func , Object arg1 , Object arg2 ,
183
185
@ SuppressWarnings ("unused" ) @ Cached GetCallTargetNode getCt ,
184
186
@ SuppressWarnings ("unused" ) @ Cached ("getCallTarget(func, getCt)" ) RootCallTarget ct ,
@@ -188,7 +190,8 @@ static Object callMethod(VirtualFrame frame, @SuppressWarnings("unused") PBuilti
188
190
return builtinNode .execute (frame , arg1 , arg2 );
189
191
}
190
192
191
- @ Specialization (guards = {"builtinNode != null" , "getCallTarget(func, getCt) == ct" , "takesSelfArg" , "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
193
+ @ Specialization (guards = {"builtinNode != null" , "getCallTarget(func, getCt) == ct" , "takesSelfArg" ,
194
+ "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
192
195
static Object callSelfMethod (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinMethod func , Object arg1 , Object arg2 ,
193
196
@ SuppressWarnings ("unused" ) @ Cached GetCallTargetNode getCt ,
194
197
@ SuppressWarnings ("unused" ) @ Cached ("getCallTarget(func, getCt)" ) RootCallTarget ct ,
@@ -202,7 +205,8 @@ static Object callSelfMethod(VirtualFrame frame, @SuppressWarnings("unused") PBu
202
205
* In case the function takes less or equal to 2 arguments (so it is <it>at least</it> binary)
203
206
* we also try to call a ternary function.
204
207
*/
205
- @ Specialization (guards = {"builtinNode != null" , "minArgs <= 2" , "func.getCallTarget() == ct" , "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
208
+ @ Specialization (guards = {"builtinNode != null" , "minArgs <= 2" , "func.getCallTarget() == ct" , "frame != null || unusedFrame" }, //
209
+ limit = "getCallSiteInlineCacheMaxDepth()" )
206
210
static Object callTernaryFunction (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinFunction func , Object arg1 , Object arg2 ,
207
211
@ SuppressWarnings ("unused" ) @ Cached ("func.getCallTarget()" ) RootCallTarget ct ,
208
212
@ SuppressWarnings ("unused" ) @ Cached ("getMinArgs(func)" ) int minArgs ,
@@ -219,7 +223,8 @@ static Object callTernaryFunction(VirtualFrame frame, @SuppressWarnings("unused"
219
223
* In case the function takes less or equal to 2 arguments (so it is <it>at least</it> binary)
220
224
* we also try to call a quaternary function.
221
225
*/
222
- @ Specialization (guards = {"builtinNode != null" , "minArgs <= 2" , "func.getCallTarget() == ct" , "frame != null || unusedFrame" }, limit = "getCallSiteInlineCacheMaxDepth()" )
226
+ @ Specialization (guards = {"builtinNode != null" , "minArgs <= 2" , "func.getCallTarget() == ct" , "frame != null || unusedFrame" }, //
227
+ limit = "getCallSiteInlineCacheMaxDepth()" )
223
228
static Object callQuaternaryFunction (VirtualFrame frame , @ SuppressWarnings ("unused" ) PBuiltinFunction func , Object arg1 , Object arg2 ,
224
229
@ SuppressWarnings ("unused" ) @ Cached ("func.getCallTarget()" ) RootCallTarget ct ,
225
230
@ SuppressWarnings ("unused" ) @ Cached ("getMinArgs(func)" ) int minArgs ,
0 commit comments