diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-10-04 22:04:26 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-10-04 22:04:26 +0200 |
commit | 78511449da5212b0283c3d6bf5a95958d6d0dbfb (patch) | |
tree | 36117519d03700e11895b78192a2e4da1ed02439 | |
parent | 0cd579d6a5d2935fb035488bc1ba002083acd45c (diff) | |
download | uxp-78511449da5212b0283c3d6bf5a95958d6d0dbfb.tar.gz |
Bug 1493900.
DiD fix.
-rw-r--r-- | js/src/jit/BacktrackingAllocator.cpp | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/js/src/jit/BacktrackingAllocator.cpp b/js/src/jit/BacktrackingAllocator.cpp index 73aceeccbc..741ed1592d 100644 --- a/js/src/jit/BacktrackingAllocator.cpp +++ b/js/src/jit/BacktrackingAllocator.cpp @@ -1843,10 +1843,19 @@ BacktrackingAllocator::resolveControlFlow() LiveRange* from = vreg(input).rangeFor(exitOf(predecessor), /* preferRegister = */ true); MOZ_ASSERT(from); - if (!alloc().ensureBallast()) - return false; - if (!moveAtExit(predecessor, from, to, def->type())) + if (!alloc().ensureBallast()) { return false; + } + if (mSuccessor->numPredecessors() > 1) { + MOZ_ASSERT(predecessor->mir()->numSuccessors() == 1); + if (!moveAtExit(predecessor, from, to, def->type())) { + return false; + } + } else { + if (!moveAtEntry(successor, from, to, def->type())) { + return false; + } + } } } } |