summaryrefslogtreecommitdiff
path: root/test/files/pos/SI-7060.flags
Commit message (Collapse)AuthorAgeFilesLines
* SI-7060 More conservative dead code elim markingVlad Ureche2013-02-051-0/+1
In dead code elimination, a DROP instruction that gets marked as useful and can be reached via several paths needs to also mark all the reaching definitions as useful, else we'll get unbalanced stacks on the two paths. A simplistic example: ``` BB1: CALL X // useful, leaves a LONG on the stack JUMP BB3 BB2: LOAD_FIELD Y // not useful JUMP BB3 BB3: DROP LONG // useful because "CALL X" is useful // but unless we mark "LOAD_FIELD Y" as useful too // we'll get unbalanced stacks when reaching BB3 ``` This patch addresses the unbalanced stack problem by adding all the reaching definitions of a useful DROP as useful instructions too.