src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.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.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
Print this page
*** 179,192 ****
public boolean isMarked(AbstractBlockBase<?> block) {
return get(Flags.SUBTREE, block);
}
public boolean isLeafBlock(AbstractBlockBase<?> block) {
! for (AbstractBlockBase<?> dom : block.getDominated()) {
if (isMarked(dom)) {
return false;
}
}
return true;
}
public void setSolution(AbstractBlockBase<?> block) {
--- 179,194 ----
public boolean isMarked(AbstractBlockBase<?> block) {
return get(Flags.SUBTREE, block);
}
public boolean isLeafBlock(AbstractBlockBase<?> block) {
! AbstractBlockBase<?> dom = block.getFirstDominated();
! while (dom != null) {
if (isMarked(dom)) {
return false;
}
+ dom = dom.getDominatedSibling();
}
return true;
}
public void setSolution(AbstractBlockBase<?> block) {
*** 198,207 ****
}
public void traverseTreeWhileTrue(AbstractBlockBase<?> block, Predicate<AbstractBlockBase<?>> action) {
assert block != null : "block must not be null!";
if (action.test(block)) {
! block.getDominated().stream().filter(this::isMarked).forEach(dominated -> traverseTreeWhileTrue(dominated, action));
}
}
}
--- 200,215 ----
}
public void traverseTreeWhileTrue(AbstractBlockBase<?> block, Predicate<AbstractBlockBase<?>> action) {
assert block != null : "block must not be null!";
if (action.test(block)) {
! AbstractBlockBase<?> dom = block.getFirstDominated();
! while (dom != null) {
! if (this.isMarked(dom)) {
! traverseTreeWhileTrue(dom, action);
! }
! dom = dom.getDominatedSibling();
! }
}
}
}
src/jdk.internal.vm.compiler/share/classes/org.graalvm.compiler.lir/src/org/graalvm/compiler/lir/constopt/ConstantTree.java
Index
Unified diffs
Context diffs
Sdiffs
Patch
New
Old
Previous File
Next File