summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/torture/pr48600.C
diff options
context:
space:
mode:
authorhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-10 12:21:16 +0000
committerhubicka <hubicka@138bc75d-0d04-0410-961f-82ee72b054a4>2012-02-10 12:21:16 +0000
commitd34430114a1c24c97fdcc37f005576a981ad7d94 (patch)
tree5b6fdd5a22647ed052e64b528c984e777237ece1 /gcc/testsuite/g++.dg/torture/pr48600.C
parent151d02b11cece7ede9d50a5673b047185e98a39d (diff)
downloadgcc-d34430114a1c24c97fdcc37f005576a981ad7d94.tar.gz
PR middle-end/48600
* predict.c (predict_paths_for_bb): Prevent looping. (predict_paths_leading_to_edge, predict_paths_leading_to): Update. * g++.dg/torture/pr48600.C: New testcase. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@184089 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/g++.dg/torture/pr48600.C')
-rw-r--r--gcc/testsuite/g++.dg/torture/pr48600.C16
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/torture/pr48600.C b/gcc/testsuite/g++.dg/torture/pr48600.C
new file mode 100644
index 00000000000..b60a0a011ec
--- /dev/null
+++ b/gcc/testsuite/g++.dg/torture/pr48600.C
@@ -0,0 +1,16 @@
+/* { dg-do compile } */
+
+class mx {
+public:
+ mx();
+};
+
+int main()
+{
+ while (true) {
+ mx *bar = new mx;
+ mx *baz = new mx;
+ continue;
+ }
+ return 0;
+}