Skip to content

Commit 0f5266b

Browse files
committed
PE fix: always explode StoreRange
1 parent 9ed689f commit 0f5266b

File tree

1 file changed

+1
-18
lines changed

1 file changed

+1
-18
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/nodes/bytecode_dsl/PBytecodeDSLRootNode.java

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -3143,32 +3143,15 @@ public static PCell[] doLoadClosure(VirtualFrame frame) {
31433143
@ConstantOperand(type = LocalRangeAccessor.class)
31443144
public static final class StoreRange {
31453145
@Specialization
3146+
@ExplodeLoop
31463147
public static void perform(VirtualFrame frame, LocalRangeAccessor locals, Object[] values,
31473148
@Bind BytecodeNode bytecode) {
3148-
if (values.length <= EXPLODE_LOOP_THRESHOLD) {
3149-
doExploded(frame, locals, values, bytecode);
3150-
} else {
3151-
doRegular(frame, locals, values, bytecode);
3152-
}
3153-
}
3154-
3155-
@ExplodeLoop
3156-
private static void doExploded(VirtualFrame frame, LocalRangeAccessor locals, Object[] values,
3157-
BytecodeNode bytecode) {
31583149
CompilerAsserts.partialEvaluationConstant(locals.getLength());
31593150
assert values.length == locals.getLength();
31603151
for (int i = 0; i < locals.getLength(); i++) {
31613152
locals.setObject(bytecode, frame, i, values[i]);
31623153
}
31633154
}
3164-
3165-
private static void doRegular(VirtualFrame frame, LocalRangeAccessor locals, Object[] values,
3166-
BytecodeNode bytecode) {
3167-
assert values.length == locals.getLength();
3168-
for (int i = 0; i < locals.getLength(); i++) {
3169-
locals.setObject(bytecode, frame, i, values[i]);
3170-
}
3171-
}
31723155
}
31733156

31743157
@Operation

0 commit comments

Comments
 (0)