Propagating values from if clauses to its successors
We have knowledge of the value of some variables at compile time due
to the fact they are used in if clauses. For example:
if (variable == constant) {
// SSA `variable` guaranteed to be equal to constant here.
} else {
// No guarantees can be made here (except for booleans since
// they only have two values).
}
Similarly with `variable != constant`.
We can also apply this to boolean parameters e.g.
void foo (boolean val) {
if (val) {
// `val` guaranteed to be true here.
...
}
...
}
Test: art/test/testrunner/testrunner.py --host --64 --optimizing -b
Change-Id: I55df0252d672870993d06e5ac92f5bba44d902bd
19 files changed