Python: Prevent bad magic during pruning.

Fixes the performance regression seen on `uncompyle2` and similar projects.
This commit is contained in:
Taus Brock-Nannestad
2019-08-20 16:18:42 +02:00
parent 35017786cf
commit a58c16f91c

View File

@@ -525,6 +525,7 @@ module Pruner {
}
/** Holds if `cond` holds for `var` on conditional edge `pred` -> `succ` as a result of the test for that edge */
pragma [nomagic]
predicate constraintOnBranch(UnprunedBasicBlock pred, UnprunedBasicBlock succ, Constraint cond, SsaVariable var) {
cond = constraintFromTest(var, pred.last()) and
succ = pred.getATrueSuccessor()