aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c')
-rw-r--r--gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c b/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c
new file mode 100644
index 000000000..033b567d8
--- /dev/null
+++ b/gcc-4.9/gcc/testsuite/gcc.c-torture/compile/pr25860.c
@@ -0,0 +1,20 @@
+/* We used to ICE because PRE would try to PRE the load of *Note from the
+ loop. */
+
+struct g
+{
+ int i;
+};
+struct f
+{
+ struct g i;
+};
+int GSM_RingNoteGetFullDuration(struct g)__attribute__((const));
+void savewav(struct f *gg)
+{
+ struct g *Note;
+ long i = 0,j,length=0;
+ Note = &gg->i;
+ for (j=0;j<GSM_RingNoteGetFullDuration(*Note);j++)
+ ;
+}