src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File hotspot Cdiff src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java

src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java

Print this page

        

*** 40,50 **** import java.util.List; import java.util.function.Function; import org.graalvm.compiler.bytecode.Bytecode; import org.graalvm.compiler.bytecode.ResolvedJavaMethodBytecode; ! import org.graalvm.compiler.common.PermanentBailoutException; import org.graalvm.compiler.core.common.type.StampFactory; import org.graalvm.compiler.core.common.type.StampPair; import org.graalvm.compiler.debug.Debug; import org.graalvm.compiler.graph.NodeSourcePosition; import org.graalvm.compiler.java.BciBlockMapping.BciBlock; --- 40,51 ---- import java.util.List; import java.util.function.Function; import org.graalvm.compiler.bytecode.Bytecode; import org.graalvm.compiler.bytecode.ResolvedJavaMethodBytecode; ! import org.graalvm.compiler.core.common.PermanentBailoutException; ! import org.graalvm.compiler.core.common.GraalOptions; import org.graalvm.compiler.core.common.type.StampFactory; import org.graalvm.compiler.core.common.type.StampPair; import org.graalvm.compiler.debug.Debug; import org.graalvm.compiler.graph.NodeSourcePosition; import org.graalvm.compiler.java.BciBlockMapping.BciBlock;
*** 97,106 **** --- 98,108 ---- */ private boolean rethrowException; private MonitorIdNode[] monitorIds; private final StructuredGraph graph; + private final boolean clearNonLiveLocals; private FrameState outerFrameState; /** * The closest {@link StateSplit#hasSideEffect() side-effect} predecessors. There will be more * than one when the current block contains no side-effects but merging predecessor blocks do.
*** 140,149 **** --- 142,152 ---- assert graph != null; this.monitorIds = EMPTY_MONITOR_ARRAY; this.graph = graph; + this.clearNonLiveLocals = GraalOptions.OptClearNonLiveLocals.getValue(graph.getOptions()); this.canVerifyKind = true; } public void disableKindVerification() { canVerifyKind = false;
*** 261,270 **** --- 264,274 ---- assert locals.length == code.getMaxLocals(); assert stack.length == Math.max(1, code.getMaxStackSize()); assert other.graph != null; graph = other.graph; + clearNonLiveLocals = other.clearNonLiveLocals; monitorIds = other.monitorIds.length == 0 ? other.monitorIds : other.monitorIds.clone(); assert locals.length == code.getMaxLocals(); assert stack.length == Math.max(1, code.getMaxStackSize()); assert lockedObjects.length == monitorIds.length;
*** 345,355 **** } } public NodeSourcePosition createBytecodePosition(int bci) { BytecodeParser parent = parser.getParent(); ! if (HideSubstitutionStates.getValue()) { if (parser.parsingIntrinsic()) { // Attribute to the method being replaced return new NodeSourcePosition(constantReceiver, parent.getFrameStateBuilder().createBytecodePosition(parent.bci()), parser.intrinsicContext.getOriginalMethod(), -1); } // Skip intrinsic frames --- 349,359 ---- } } public NodeSourcePosition createBytecodePosition(int bci) { BytecodeParser parent = parser.getParent(); ! if (HideSubstitutionStates.getValue(parser.graph.getOptions())) { if (parser.parsingIntrinsic()) { // Attribute to the method being replaced return new NodeSourcePosition(constantReceiver, parent.getFrameStateBuilder().createBytecodePosition(parent.bci()), parser.intrinsicContext.getOriginalMethod(), -1); } // Skip intrinsic frames
*** 622,632 **** * (lstadler) if somebody is tempted to remove/disable this clearing code: it's possible to * remove it for normal compilations, but not for OSR compilations - otherwise dead object * slots at the OSR entry aren't cleared. it is also not enough to rely on PiNodes with * Kind.Illegal, because the conflicting branch might not have been parsed. */ ! if (!parser.graphBuilderConfig.clearNonLiveLocals()) { return; } if (liveIn) { for (int i = 0; i < locals.length; i++) { if (!liveness.localIsLiveIn(block, i)) { --- 626,636 ---- * (lstadler) if somebody is tempted to remove/disable this clearing code: it's possible to * remove it for normal compilations, but not for OSR compilations - otherwise dead object * slots at the OSR entry aren't cleared. it is also not enough to rely on PiNodes with * Kind.Illegal, because the conflicting branch might not have been parsed. */ ! if (!clearNonLiveLocals) { return; } if (liveIn) { for (int i = 0; i < locals.length; i++) { if (!liveness.localIsLiveIn(block, i)) {
src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.java/src/org/graalvm/compiler/java/FrameStateBuilder.java
Index Unified diffs Context diffs Sdiffs Patch New Old Previous File Next File