summaryrefslogtreecommitdiff
path: root/test/files/pos/SI-7060.flags
diff options
context:
space:
mode:
authorVlad Ureche <vlad.ureche@gmail.com>2013-02-03 23:47:44 +0100
committerVlad Ureche <vlad.ureche@gmail.com>2013-02-05 15:52:52 +0100
commite5c0e59373897d9f9dc6c49f8458666e88419586 (patch)
tree7e78e237d3db3c33e2feff4d811084aedfb9dd9b /test/files/pos/SI-7060.flags
parent3d318be51f8e8cdec314565920327486212f5020 (diff)
downloadscala-e5c0e59373897d9f9dc6c49f8458666e88419586.tar.gz
scala-e5c0e59373897d9f9dc6c49f8458666e88419586.tar.bz2
scala-e5c0e59373897d9f9dc6c49f8458666e88419586.zip
SI-7060 More conservative dead code elim marking
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.
Diffstat (limited to 'test/files/pos/SI-7060.flags')
-rw-r--r--test/files/pos/SI-7060.flags1
1 files changed, 1 insertions, 0 deletions
diff --git a/test/files/pos/SI-7060.flags b/test/files/pos/SI-7060.flags
new file mode 100644
index 0000000000..c926ad6493
--- /dev/null
+++ b/test/files/pos/SI-7060.flags
@@ -0,0 +1 @@
+-Yinline -Ydead-code