summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg
diff options
context:
space:
mode:
authorhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2011-02-04 17:23:30 +0000
committerhjl <hjl@138bc75d-0d04-0410-961f-82ee72b054a4>2011-02-04 17:23:30 +0000
commit797db64b9ef75f3e65c967a73582b3760f354b4a (patch)
tree6a6544f768adc3aaeb768daf40feb9a4832815ca /gcc/testsuite/g++.dg
parent351b6ccf86d48ad98795df9defe0af7f35fdd66d (diff)
downloadgcc-797db64b9ef75f3e65c967a73582b3760f354b4a.tar.gz
Add a testcase for PR tree-optimization/43695.
2011-02-04 H.J. Lu <hongjiu.lu@intel.com> PR tree-optimization/43695 * g++.dg/ipa/pr43695.C: New. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@169835 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/g++.dg')
-rw-r--r--gcc/testsuite/g++.dg/ipa/pr43695.C20
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/ipa/pr43695.C b/gcc/testsuite/g++.dg/ipa/pr43695.C
new file mode 100644
index 00000000000..a01478324b0
--- /dev/null
+++ b/gcc/testsuite/g++.dg/ipa/pr43695.C
@@ -0,0 +1,20 @@
+/* { dg-do compile } */
+/* { dg-options "-fipa-cp -fipa-cp-clone" } */
+
+extern void baz(int) __attribute__ ((noreturn));
+
+struct S {
+ ~S();
+};
+
+__attribute__ ((noreturn, noinline))
+void bar(int i)
+{
+ baz(i);
+}
+
+void foo()
+{
+ S s;
+ bar(0);
+}