summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg
diff options
context:
space:
mode:
authorbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2011-07-21 19:37:05 +0000
committerbstarynk <bstarynk@138bc75d-0d04-0410-961f-82ee72b054a4>2011-07-21 19:37:05 +0000
commitb2009e332c150356085f0fb0e35a3a452b10c378 (patch)
treec188ce224e4d028d0ab5f3313b2bc6e749eb88e9 /gcc/testsuite/gcc.dg
parent323d3e1d50a7a2022e587b786d010c22812a6d5a (diff)
downloadgcc-b2009e332c150356085f0fb0e35a3a452b10c378.tar.gz
2011-07-21 Basile Starynkevitch <basile@starynkevitch.net>
MELT branch merged with trunk rev 176576 using svnmerge. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/branches/melt-branch@176583 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite/gcc.dg')
-rw-r--r--gcc/testsuite/gcc.dg/20040813-1.c2
-rw-r--r--gcc/testsuite/gcc.dg/binop-xor1.c5
-rw-r--r--gcc/testsuite/gcc.dg/binop-xor3.c5
-rw-r--r--gcc/testsuite/gcc.dg/bitfld-15.c1
-rw-r--r--gcc/testsuite/gcc.dg/bitfld-16.c1
-rw-r--r--gcc/testsuite/gcc.dg/bitfld-17.c1
-rw-r--r--gcc/testsuite/gcc.dg/bitfld-18.c1
-rw-r--r--gcc/testsuite/gcc.dg/builtins-config.h2
-rw-r--r--gcc/testsuite/gcc.dg/cdce1.c3
-rw-r--r--gcc/testsuite/gcc.dg/cdce2.c3
-rw-r--r--gcc/testsuite/gcc.dg/cpp/assert4.c8
-rw-r--r--gcc/testsuite/gcc.dg/debug/pr35154.c2
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-1.c3
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-2.c3
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-3.c7
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-4.c2
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-5.c3
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-7.c4
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-8.c3
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipacost-1.c8
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipacost-2.c25
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipcp-1.c52
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipcp-2.c99
-rw-r--r--gcc/testsuite/gcc.dg/pr32912-2.c1
-rw-r--r--gcc/testsuite/gcc.dg/pr44674.c1
-rw-r--r--gcc/testsuite/gcc.dg/torture/20110718-1.c23
-rw-r--r--gcc/testsuite/gcc.dg/torture/20110719-1.c10
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/bitwise-sink.c2
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/bool-10.c2
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/bool-11.c2
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c8
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/pr18908.c9
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/pr30978.c5
-rw-r--r--gcc/testsuite/gcc.dg/tree-ssa/ssa-fre-6.c2
-rw-r--r--gcc/testsuite/gcc.dg/vect/pr49038.c2
-rw-r--r--gcc/testsuite/gcc.dg/vect/pr49771.c26
36 files changed, 279 insertions, 57 deletions
diff --git a/gcc/testsuite/gcc.dg/20040813-1.c b/gcc/testsuite/gcc.dg/20040813-1.c
index fa01a530208..bf87f4172cf 100644
--- a/gcc/testsuite/gcc.dg/20040813-1.c
+++ b/gcc/testsuite/gcc.dg/20040813-1.c
@@ -2,7 +2,7 @@
/* Contributed by Devang Patel <dpatel@apple.com> */
/* { dg-do compile } */
-/* { dg-skip-if "No stabs" { mmix-*-* *-*-aix* *-*-netware* alpha*-*-* hppa*64*-*-* ia64-*-* *-*-vxworks* } { "*" } { "" } } */
+/* { dg-skip-if "No stabs" { mmix-*-* *-*-aix* alpha*-*-* hppa*64*-*-* ia64-*-* *-*-vxworks* } { "*" } { "" } } */
/* { dg-options "-gstabs" } */
int
diff --git a/gcc/testsuite/gcc.dg/binop-xor1.c b/gcc/testsuite/gcc.dg/binop-xor1.c
index 53a2ce23ab3..48f6b425959 100644
--- a/gcc/testsuite/gcc.dg/binop-xor1.c
+++ b/gcc/testsuite/gcc.dg/binop-xor1.c
@@ -7,8 +7,5 @@ foo (int a, int b, int c)
return ((a && !b && c) || (!a && b && c));
}
-/* We expect to see "<bb N>"; confirm that, so that we know to count
- it in the real test. */
-/* { dg-final { scan-tree-dump-times "<bb\[^>\]*>" 5 "optimized" } } */
-/* { dg-final { scan-tree-dump-times "\\\^" 1 "optimized" } } */
+/* { dg-final { scan-tree-dump-times "\\\^" 1 "optimized" { xfail *-*-* } } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/binop-xor3.c b/gcc/testsuite/gcc.dg/binop-xor3.c
index 97c7888189a..9d3b50bd4ee 100644
--- a/gcc/testsuite/gcc.dg/binop-xor3.c
+++ b/gcc/testsuite/gcc.dg/binop-xor3.c
@@ -7,8 +7,5 @@ foo (int a, int b)
return ((a && !b) || (!a && b));
}
-/* We expect to see "<bb N>"; confirm that, so that we know to count
- it in the real test. */
-/* { dg-final { scan-tree-dump-times "<bb\[^>\]*>" 1 "optimized" } } */
-/* { dg-final { scan-tree-dump-times "\\\^" 1 "optimized" } } */
+/* { dg-final { scan-tree-dump-times "\\\^" 1 "optimized" { xfail *-*-* } } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/bitfld-15.c b/gcc/testsuite/gcc.dg/bitfld-15.c
index 03f43f2de8c..32878d74dbc 100644
--- a/gcc/testsuite/gcc.dg/bitfld-15.c
+++ b/gcc/testsuite/gcc.dg/bitfld-15.c
@@ -1,7 +1,6 @@
/* { dg-do compile } */
/* Remove pedantic. Allow the GCC extension to use char for bitfields. */
/* { dg-options "" } */
-/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
/* { dg-options "-mno-ms-bitfields -Wno-packed-bitfield-compat" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
struct t
diff --git a/gcc/testsuite/gcc.dg/bitfld-16.c b/gcc/testsuite/gcc.dg/bitfld-16.c
index 5ed30f74392..75d290f00e1 100644
--- a/gcc/testsuite/gcc.dg/bitfld-16.c
+++ b/gcc/testsuite/gcc.dg/bitfld-16.c
@@ -1,6 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-Wno-packed-bitfield-compat" } */
-/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
struct t
diff --git a/gcc/testsuite/gcc.dg/bitfld-17.c b/gcc/testsuite/gcc.dg/bitfld-17.c
index 9512f5fdf2a..6dc6989df7b 100644
--- a/gcc/testsuite/gcc.dg/bitfld-17.c
+++ b/gcc/testsuite/gcc.dg/bitfld-17.c
@@ -1,6 +1,5 @@
/* { dg-do compile } */
/* { dg-options "" } */
-/* { dg-options "-mno-ms-bitfields" { target i?86-*-netware } } */
/* { dg-options "-mno-ms-bitfields -Wno-packed-bitfield-compat" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
struct t
diff --git a/gcc/testsuite/gcc.dg/bitfld-18.c b/gcc/testsuite/gcc.dg/bitfld-18.c
index 067d9ae3851..748669543c1 100644
--- a/gcc/testsuite/gcc.dg/bitfld-18.c
+++ b/gcc/testsuite/gcc.dg/bitfld-18.c
@@ -1,6 +1,5 @@
/* { dg-do compile } */
/* { dg-options "-Wno-packed-bitfield-compat" } */
-/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target i?86-*-netware } } */
/* { dg-options "-Wno-packed-bitfield-compat -mno-ms-bitfields" { target { i?86-*-mingw* x86_64-*-mingw* } } } */
struct t
diff --git a/gcc/testsuite/gcc.dg/builtins-config.h b/gcc/testsuite/gcc.dg/builtins-config.h
index 49ec0dcc8e4..fc1ade677a2 100644
--- a/gcc/testsuite/gcc.dg/builtins-config.h
+++ b/gcc/testsuite/gcc.dg/builtins-config.h
@@ -15,8 +15,6 @@
/* AVR doesn't have the entire C99 runtime. */
#elif defined(__FreeBSD__) && (__FreeBSD__ < 9)
/* FreeBSD up to version 8 lacks support for cexp and friends. */
-#elif defined(__netware__)
-/* NetWare doesn't have the entire C99 runtime. */
#elif defined(__vxworks)
/* VxWorks doesn't have a full C99 time. (cabs is missing, for example.) */
#elif defined(_WIN32) && !defined(__CYGWIN__)
diff --git a/gcc/testsuite/gcc.dg/cdce1.c b/gcc/testsuite/gcc.dg/cdce1.c
index 58a3ddfb3a9..3bd35ecb786 100644
--- a/gcc/testsuite/gcc.dg/cdce1.c
+++ b/gcc/testsuite/gcc.dg/cdce1.c
@@ -1,7 +1,6 @@
/* { dg-do run } */
/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -lm" } */
-/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
-/* { dg-final { scan-tree-dump "cdce1.c:17: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
+/* { dg-final { scan-tree-dump "cdce1.c:16: note: function call is shrink-wrapped into error conditions\." "cdce" } } */
/* { dg-final { cleanup-tree-dump "cdce" } } */
/* { dg-require-effective-target large_double } */
diff --git a/gcc/testsuite/gcc.dg/cdce2.c b/gcc/testsuite/gcc.dg/cdce2.c
index eebebaa2390..a461ce7ac30 100644
--- a/gcc/testsuite/gcc.dg/cdce2.c
+++ b/gcc/testsuite/gcc.dg/cdce2.c
@@ -1,8 +1,7 @@
/* { dg-do run } */
/* { dg-skip-if "doubles are floats" { "avr-*-*" } { "*" } { "" } } */
/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details -lm" } */
-/* { dg-options "-O2 -fmath-errno -fdump-tree-cdce-details" { target *-*-netware* } } */
-/* { dg-final { scan-tree-dump "cdce2.c:17: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
+/* { dg-final { scan-tree-dump "cdce2.c:16: note: function call is shrink-wrapped into error conditions\." "cdce" } }*/
/* { dg-final { cleanup-tree-dump "cdce" } } */
#include <stdlib.h>
diff --git a/gcc/testsuite/gcc.dg/cpp/assert4.c b/gcc/testsuite/gcc.dg/cpp/assert4.c
index ff53946c6ce..a05ef130206 100644
--- a/gcc/testsuite/gcc.dg/cpp/assert4.c
+++ b/gcc/testsuite/gcc.dg/cpp/assert4.c
@@ -128,14 +128,6 @@
# error
#endif
-#if defined __netware__
-# if !#system(netware)
-# error
-# endif
-#elif #system(netware)
-# error
-#endif
-
/* Check for #cpu and #machine assertions. */
diff --git a/gcc/testsuite/gcc.dg/debug/pr35154.c b/gcc/testsuite/gcc.dg/debug/pr35154.c
index 8706c5c295a..fa658be2cbe 100644
--- a/gcc/testsuite/gcc.dg/debug/pr35154.c
+++ b/gcc/testsuite/gcc.dg/debug/pr35154.c
@@ -23,7 +23,7 @@ main()
optb.f2 = 'D';
i_outer = 'e';
/* { dg-do compile } */
-/* { dg-skip-if "No stabs" { mmix-*-* *-*-netware* alpha*-*-* hppa*64*-*-* ia64-*-* *-*-vxworks* } { "*" } { "" } } */
+/* { dg-skip-if "No stabs" { mmix-*-* alpha*-*-* hppa*64*-*-* ia64-*-* *-*-vxworks* } { "*" } { "" } } */
/* { dg-skip-if "stabs only" { *-*-* } { "*" } { "-gstabs" } } */
return 0;
}
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-1.c b/gcc/testsuite/gcc.dg/ipa/ipa-1.c
index e3212853cf5..3517b035f1c 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-1.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-1.c
@@ -24,9 +24,8 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 2 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
-/* { dg-final { scan-ipa-dump "replacing param b with const 7" "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-2.c b/gcc/testsuite/gcc.dg/ipa/ipa-2.c
index 1d57fb00828..122a4a0181a 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-2.c
@@ -22,7 +22,6 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 2 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
-/* { dg-final { scan-ipa-dump "replacing param c with const 3" "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-3.c b/gcc/testsuite/gcc.dg/ipa/ipa-3.c
index a3334c34543..e15f084b400 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-3.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-3.c
@@ -7,12 +7,12 @@
#include <stdio.h>
void t(void);
-int g (double b, double c)
+static int g (double b, double c)
{
t();
return (int)(b+c);
}
-int f (double a)
+static int f (double a)
{
if (a > 0)
g (a, 3.1);
@@ -28,8 +28,9 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 2 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of g" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param b with const 7" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param c with const 3" "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-4.c b/gcc/testsuite/gcc.dg/ipa/ipa-4.c
index 3cb0cd4d27e..88716dd8f4c 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-4.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-4.c
@@ -25,6 +25,6 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
/* { dg-final { scan-ipa-dump-times "replacing param a with const 7" 1 "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-5.c b/gcc/testsuite/gcc.dg/ipa/ipa-5.c
index 50af18e2b01..22d1be89c0e 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-5.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-5.c
@@ -26,8 +26,7 @@ int main ()
return 0;
}
-
-/* { dg-final { scan-ipa-dump-times "versioned function" 2 "cp" } } */
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node" 2 "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param c with const 3" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-7.c b/gcc/testsuite/gcc.dg/ipa/ipa-7.c
index 6dcc914c103..c8b510046a1 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-7.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-7.c
@@ -26,8 +26,8 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-times "replacing param a with const 7" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
+/* { dg-final { scan-ipa-dump-times "replacing param . with const 7" 1 "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-8.c b/gcc/testsuite/gcc.dg/ipa/ipa-8.c
index edea7f900b4..dcbed13a0ed 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-8.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-8.c
@@ -22,8 +22,9 @@ int main ()
}
-/* { dg-final { scan-ipa-dump-times "versioned function" 2 "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
+/* { dg-final { scan-ipa-dump "Creating a specialized node of g" "cp" } } */
/* { dg-final { scan-ipa-dump "replacing param b with const 7" "cp" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipacost-1.c b/gcc/testsuite/gcc.dg/ipa/ipacost-1.c
index d91546899ea..4fce41e8235 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipacost-1.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipacost-1.c
@@ -51,10 +51,10 @@ main()
i_can_not_be_propagated_fully2 (array);
}
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_be_propagated_fully2" 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_be_propagated_fully " 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-not "versioned function i_can_not_be_propagated_fully2" "cp" } } */
-/* { dg-final { scan-ipa-dump-not "versioned function i_can_not_be_propagated_fully " "cp" } } */
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node of i_can_be_propagated_fully2" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node of i_can_be_propagated_fully/" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-not "Creating a specialized node of i_can_not_be_propagated_fully2" "cp" } } */
+/* { dg-final { scan-ipa-dump-not "Creating a specialized node of i_can_not_be_propagated_fully/" "cp" } } */
/* { dg-final { scan-tree-dump-not "i_can_be_propagated_fully " "optimized" } } */
/* { dg-final { scan-tree-dump-not "i_can_be_propagated_fully2 " "optimized" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipacost-2.c b/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
index 6ebd6d37481..ceb524e00ae 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipacost-2.c
@@ -40,8 +40,23 @@ i_can_not_be_propagated_fully (int *a)
int
i_can_not_be_propagated_fully2 (int *a)
{
+ int i;
i_can_not_be_propagated_fully (a);
+ for (i=0;i<50;i++)
+ {
+ t(a[i] + 1);
+ t(a[i+1] + 1);
+ t(a[i+2] + 1);
+ t(a[i+3] + 1);
+ }
i_can_not_be_propagated_fully (a);
+ for (i=0;i<50;i++)
+ {
+ t(a[i] + 2);
+ t(a[i+1] + 2);
+ t(a[i+2] + 2);
+ t(a[i+3] + 2);
+ }
i_can_not_be_propagated_fully (a);
}
main()
@@ -50,15 +65,15 @@ main()
i_can_be_propagated_fully2 (array);
i_can_be_propagated_fully2 (array);
- for (i = 0; i < 100; i++)
+ for (i = 0; i < 7; i++)
i_can_not_be_propagated_fully2 (array);
i_can_not_be_propagated_fully2 (array);
}
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_be_propagated_fully2" 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_be_propagated_fully " 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_not_be_propagated_fully2" 1 "cp" } } */
-/* { dg-final { scan-ipa-dump-times "versioned function i_can_not_be_propagated_fully " 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node of i_can_be_propagated_fully2" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node of i_can_be_propagated_fully/" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-not "Creating a specialized node of i_can_not_be_propagated_fully2" "cp" } } */
+/* { dg-final { scan-ipa-dump-not "Creating a specialized node of i_can_not_be_propagated_fully/" "cp" } } */
/* { dg-final { scan-tree-dump-not "i_can_be_propagated_fully \\(" "optimized" } } */
/* { dg-final { scan-tree-dump-not "i_can_be_propagated_fully2 \\(" "optimized" } } */
/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-1.c b/gcc/testsuite/gcc.dg/ipa/ipcp-1.c
new file mode 100644
index 00000000000..0f50ff9276a
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-1.c
@@ -0,0 +1,52 @@
+/* Test that IPA-CP is able to figure out that poth parameters a are constant 7
+ even though f and h recursively call each other and specialize them
+ accordinly. */
+
+/* { dg-do compile } */
+/* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining" } */
+/* { dg-add-options bind_pic_locally } */
+
+extern void use_stuff (int);
+
+static
+int g (int b, int c)
+{
+ int i;
+
+ for (i = 0; i < b; i++)
+ use_stuff (c);
+}
+
+static void f (int a, int x, int z);
+
+static void h (int z, int a)
+{
+ use_stuff (z);
+ f (a, 9, 10);
+
+}
+
+static void
+f (int a, int x, int z)
+{
+ if (z > 1)
+ g (a, x);
+ else
+ h (5, a);
+}
+
+int
+main (int argc, char *argv[])
+{
+ int i;
+ for (i = 0; i < 100; i++)
+ f (7, 8, argc);
+ return 0;
+}
+
+
+/* { dg-final { scan-ipa-dump "Creating a specialized node of f.*for all known contexts" "cp" } } */
+/* { dg-final { scan-ipa-dump "replacing param a with const 7" "cp" } } */
+/* { dg-final { cleanup-ipa-dump "cp" } } */
+
+
diff --git a/gcc/testsuite/gcc.dg/ipa/ipcp-2.c b/gcc/testsuite/gcc.dg/ipa/ipcp-2.c
new file mode 100644
index 00000000000..c6dcdf0af52
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/ipa/ipcp-2.c
@@ -0,0 +1,99 @@
+/* { dg-do compile } */
+/* { dg-options "-O3 -fipa-cp -fipa-cp-clone -fdump-ipa-cp -fno-early-inlining" } */
+/* { dg-add-options bind_pic_locally } */
+
+extern int get_stuff (int);
+extern void do_stuff (int);
+extern void do_stuff2 (int);
+extern void do_other_stuff (void);
+extern int get_element (int, int, int);
+extern int adjust (int, int, int, int);
+
+extern int count;
+
+int
+foo (int s, int p)
+{
+ int c, r = 0;
+
+ for (c = 0 ; c < count; c++)
+ {
+ r += get_stuff (s);
+ /* The following is just something big that can go away. */
+ if (p != 0)
+ {
+ int a[64][64];
+ int i, j, k;
+
+ for (i = 0; i < 64; i++)
+ for (j = 0; j < 64; j++)
+ a[i][j] = get_element (p + c, i, j);
+
+ for (k = 0; k < 4; k++)
+ {
+ r = r / 2;
+
+ for (i = 1; i < 63; i++)
+ for (j = 62; j > 0; j--)
+ a[i][j] += adjust (a[i-1][j], a[i][j-1],
+ a[i+1][j], a[i][j+1]);
+
+ for (i = 4; i < 64; i += 4)
+ for (j = 4; j < 64; j += 4)
+ r += a[i][j] / 4;
+ }
+ }
+ }
+ return r;
+}
+
+int
+bar (int p, int q)
+{
+ if (q > 0)
+ do_stuff (q);
+ else
+ do_stuff (-q);
+
+ if (q % 2)
+ do_stuff2 (2 * q);
+ else
+ do_stuff2 (2 * (q + 1));
+
+ return foo (4, p);
+}
+
+int
+bah (int p, int q)
+{
+ int i, j;
+
+ while (q < -20)
+ q += get_stuff (-q);
+
+ for (i = 0; i < 36; i++)
+ for (j = 0; j < 36; j++)
+ do_stuff (get_stuff (q * i + 2));
+
+ bar (p, q);
+}
+
+int
+top1 (int q)
+{
+ do_other_stuff ();
+ return bah (0, q);
+}
+
+int
+top2 (int q)
+{
+ do_stuff (200);
+ do_other_stuff ();
+ return bah (16, q);
+}
+
+/* { dg-final { scan-ipa-dump-times "Creating a specialized node of foo" 1 "cp" } } */
+/* { dg-final { scan-ipa-dump-times "replacing param p with const 0" 3 "cp" } } */
+/* { dg-final { scan-ipa-dump "replacing param s with const 4" "cp" } } */
+/* { dg-final { cleanup-ipa-dump "cp" } } */
diff --git a/gcc/testsuite/gcc.dg/pr32912-2.c b/gcc/testsuite/gcc.dg/pr32912-2.c
index f3c754cc346..f29e63e7058 100644
--- a/gcc/testsuite/gcc.dg/pr32912-2.c
+++ b/gcc/testsuite/gcc.dg/pr32912-2.c
@@ -1,5 +1,6 @@
/* { dg-do run } */
/* { dg-options "-O2 -w" } */
+/* { dg-skip-if "TImode not supported" { "avr-*-*" } { "*" } { "" } } */
extern void abort (void);
diff --git a/gcc/testsuite/gcc.dg/pr44674.c b/gcc/testsuite/gcc.dg/pr44674.c
index c3f16ff20ee..c71b49ea5f6 100644
--- a/gcc/testsuite/gcc.dg/pr44674.c
+++ b/gcc/testsuite/gcc.dg/pr44674.c
@@ -1,5 +1,6 @@
/* { dg-do compile } */
/* { dg-options "-O -fprofile-generate" } */
+/* { dg-require-profiling "-fprofile-generate" } */
void
jumpfunc (void *p)
diff --git a/gcc/testsuite/gcc.dg/torture/20110718-1.c b/gcc/testsuite/gcc.dg/torture/20110718-1.c
new file mode 100644
index 00000000000..ccabbd91421
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/torture/20110718-1.c
@@ -0,0 +1,23 @@
+/* { dg-do run } */
+
+extern void abort (void);
+struct X {
+#if (__SIZEOF_LONG__ != __SIZEOF_INT__) && (__SIZEOF_LONG__ == 8)
+ unsigned long i : 33;
+#else
+ unsigned long i;
+#endif
+};
+unsigned long __attribute__((noinline))
+foo (struct X *p)
+{
+ return ~p->i;
+}
+int main()
+{
+ struct X x;
+ x.i = -1;
+ if (foo (&x) != 0)
+ abort ();
+ return 0;
+}
diff --git a/gcc/testsuite/gcc.dg/torture/20110719-1.c b/gcc/testsuite/gcc.dg/torture/20110719-1.c
new file mode 100644
index 00000000000..7797e08ad2b
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/torture/20110719-1.c
@@ -0,0 +1,10 @@
+extern void abort (void);
+int i;
+int main()
+{
+ int b = i != 0;
+ int c = ~b;
+ if (c != -1)
+ abort ();
+ return 0;
+}
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/bitwise-sink.c b/gcc/testsuite/gcc.dg/tree-ssa/bitwise-sink.c
index f44529995b7..1de04bc8431 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/bitwise-sink.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/bitwise-sink.c
@@ -7,5 +7,5 @@ foo (_Bool x)
return (x ^ 1);
}
-/* { dg-final { scan-tree-dump-times "x\[^ \]* \\^ 1" 1 "optimized" } } */
+/* { dg-final { scan-tree-dump-times "~x" 1 "optimized" } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/bool-10.c b/gcc/testsuite/gcc.dg/tree-ssa/bool-10.c
index d7bf20da81b..58d064539a7 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/bool-10.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/bool-10.c
@@ -9,6 +9,6 @@ int f(_Bool x)
/* There should be no != 1 which is produced by the front-end as
bool_var != 1 is the same as !bool_var. */
/* { dg-final { scan-tree-dump-times "!= 1" 0 "optimized"} } */
-/* { dg-final { scan-tree-dump-times "!x" 1 "optimized"} } */
+/* { dg-final { scan-tree-dump-times "~x" 1 "optimized"} } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/bool-11.c b/gcc/testsuite/gcc.dg/tree-ssa/bool-11.c
index 8d88b7e87d5..ee266c79cb9 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/bool-11.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/bool-11.c
@@ -9,6 +9,6 @@ int f(_Bool x)
/* There should be no == 0 which is produced by the front-end as
bool_var == 0 is the same as !bool_var. */
/* { dg-final { scan-tree-dump-times "== 0" 0 "optimized"} } */
-/* { dg-final { scan-tree-dump-times "!x" 1 "optimized"} } */
+/* { dg-final { scan-tree-dump-times "~x" 1 "optimized"} } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c b/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
index 7918eb7562d..26b433823ac 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/ipa-cp-1.c
@@ -5,9 +5,13 @@
int
very_long_function(int a)
{
- return very_long_function (a)/4;
+ if (a > 0)
+ return 2 * a + very_long_function (a)/4;
+ else
+ return 2 * -a + very_long_function (a)/4;
}
-main()
+
+blah ()
{
very_long_function (1);
}
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/pr18908.c b/gcc/testsuite/gcc.dg/tree-ssa/pr18908.c
new file mode 100644
index 00000000000..cfc92fec9c4
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/tree-ssa/pr18908.c
@@ -0,0 +1,9 @@
+/* { dg-do compile } */
+/* { dg-options "-O -fdump-tree-forwprop1" } */
+
+_Bool f3(_Bool *p) { *p ^= 1; }
+
+/* We should be able to canonicalize the above to use bitwise not. */
+/* { dg-final { scan-tree-dump "~D" "forwprop1" } } */
+/* { dg-final { scan-tree-dump-not "\\\^ 1" "forwprop1" } } */
+/* { dg-final { cleanup-tree-dump "forwprop1" } } */
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/pr30978.c b/gcc/testsuite/gcc.dg/tree-ssa/pr30978.c
index 3329383cbe8..ee45e5b4fe8 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/pr30978.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/pr30978.c
@@ -10,5 +10,8 @@ int foo(int a)
return e;
}
-/* { dg-final { scan-tree-dump "e_. = a_..D. > 0;" "optimized" } } */
+/* { dg-final { scan-tree-dump-times " = " 2 "optimized" } } */
+/* One comparison and one extension to int. */
+/* { dg-final { scan-tree-dump " = a_..D. > 0;" "optimized" } } */
+/* { dg-final { scan-tree-dump "e_. = \\\(int\\\)" "optimized" } } */
/* { dg-final { cleanup-tree-dump "optimized" } } */
diff --git a/gcc/testsuite/gcc.dg/tree-ssa/ssa-fre-6.c b/gcc/testsuite/gcc.dg/tree-ssa/ssa-fre-6.c
index 65883cd14bd..18a9d9b895a 100644
--- a/gcc/testsuite/gcc.dg/tree-ssa/ssa-fre-6.c
+++ b/gcc/testsuite/gcc.dg/tree-ssa/ssa-fre-6.c
@@ -2,5 +2,5 @@
/* { dg-options "-O -fdump-tree-fre1-details" } */
int i; int foo(void) { i = 2; int j = i * 2; int k = i + 2; return j == k; }
-/* { dg-final { scan-tree-dump-times "Replaced " 5 "fre1" } } */
+/* { dg-final { scan-tree-dump-times "Replaced " 6 "fre1" } } */
/* { dg-final { cleanup-tree-dump "fre1" } } */
diff --git a/gcc/testsuite/gcc.dg/vect/pr49038.c b/gcc/testsuite/gcc.dg/vect/pr49038.c
index 91c214ffd4c..681e5d50a83 100644
--- a/gcc/testsuite/gcc.dg/vect/pr49038.c
+++ b/gcc/testsuite/gcc.dg/vect/pr49038.c
@@ -1,3 +1,5 @@
+/* { dg-do run { target i?86-*-linux* x86_64-*-linux* ia64-*-linux* alpha*-*-linux* powerpc*-*-linux* s390*-*-linux* sparc*-*-linux* *-*-darwin* } } */
+
#include <sys/mman.h>
#include <stdio.h>
diff --git a/gcc/testsuite/gcc.dg/vect/pr49771.c b/gcc/testsuite/gcc.dg/vect/pr49771.c
new file mode 100644
index 00000000000..777f615365c
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/vect/pr49771.c
@@ -0,0 +1,26 @@
+#include <stdlib.h>
+#include <stdarg.h>
+
+static int a[1000];
+
+int
+foo (void)
+{
+ int j;
+ int i;
+ for (i = 0; i < 1000; i++)
+ for (j = 0; j < 1000; j++)
+ a[j] = a[i] + 1;
+ return a[0];
+}
+
+int
+main (void)
+{
+ int res = foo ();
+ if (res != 1999)
+ abort ();
+ return 0;
+}
+
+/* { dg-final { cleanup-tree-dump "vect" } } */