Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upthe ICode optimizer doesn't DCE-away trivial branches #7560
Comments
This comment has been minimized.
This comment has been minimized.
Imported From: https://issues.scala-lang.org/browse/SI-7560?orig=1 |
This comment has been minimized.
This comment has been minimized.
@magarciaEPFL said: If you need help fixing this bug, take a look at how the new optimizer ( http://magarciaepfl.github.io/scala/ ) does it, in particular: Quoting from its documentation:
|
This comment has been minimized.
This comment has been minimized.
@adriaanm said: |
scabug
closed this
May 16, 2014
scabug
added
won't fix
optimizer
labels
Apr 7, 2017
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
scabug commentedJun 6, 2013
The discussion at scala/scala#2620
uncovered that the ICode-based optimizer's DCE doesn't eliminate a redundant conditional jump,
where both branches lead to one and the same instruction.
The example showing the above is
test/files/jvm/bytecode-test-example/Foo_1.scala
reproduced below:With GenASM and
-optimise
we get the two conditional jumps thatbytecode-test-example.check
expects:including a useless
(useless because, whether the conditional jump is taken or not,
L1
is the target anyway)