From: Marek Polacek Date: Thu, 2 Oct 2014 18:17:04 +0000 (+0000) Subject: 20091013.c: Fix defaulting to int. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=091b2ce040ca00e4d98551ea1e30c55f0b8d9b45;p=gcc.git 20091013.c: Fix defaulting to int. * gcc.dg/tm/20091013.c: Fix defaulting to int. * gcc.dg/tm/20091221.c: Likewise. * gcc.dg/tm/debug-1.c: Likewise. * gcc.dg/tm/irrevocable-1.c: Likewise. * gcc.dg/tm/irrevocable-2.c: Likewise. * gcc.dg/tm/irrevocable-3.c: Likewise. * gcc.dg/tm/irrevocable-4.c: Likewise. * gcc.dg/tm/memopt-1.c: Likewise. * gcc.dg/tm/pr52173-1.c: Likewise. * gcc.dg/tm/props-1.c: Likewise. * gcc.dg/tm/props-2.c: Likewise. * gcc.dg/tm/props-3.c: Likewise. * gcc.dg/tm/20100125.c: Fix implicit declarations. * gcc.dg/tm/memopt-11.c: Likewise. * gcc.dg/tm/memopt-12.c: Likewise. * gcc.dg/tm/memopt-16.c: Likewise. * gcc.dg/tm/memopt-3.c: Likewise. * gcc.dg/tm/memopt-4.c: Likewise. * gcc.dg/tm/memopt-5.c: Likewise. * gcc.dg/tm/memopt-6.c: Likewise. * gcc.dg/tm/wrap-4.c: Likewise. From-SVN: r215815 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 3359108de30..6e2b6376e6e 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,27 @@ +2014-10-02 Marek Polacek + + * gcc.dg/tm/20091013.c: Fix defaulting to int. + * gcc.dg/tm/20091221.c: Likewise. + * gcc.dg/tm/debug-1.c: Likewise. + * gcc.dg/tm/irrevocable-1.c: Likewise. + * gcc.dg/tm/irrevocable-2.c: Likewise. + * gcc.dg/tm/irrevocable-3.c: Likewise. + * gcc.dg/tm/irrevocable-4.c: Likewise. + * gcc.dg/tm/memopt-1.c: Likewise. + * gcc.dg/tm/pr52173-1.c: Likewise. + * gcc.dg/tm/props-1.c: Likewise. + * gcc.dg/tm/props-2.c: Likewise. + * gcc.dg/tm/props-3.c: Likewise. + * gcc.dg/tm/20100125.c: Fix implicit declarations. + * gcc.dg/tm/memopt-11.c: Likewise. + * gcc.dg/tm/memopt-12.c: Likewise. + * gcc.dg/tm/memopt-16.c: Likewise. + * gcc.dg/tm/memopt-3.c: Likewise. + * gcc.dg/tm/memopt-4.c: Likewise. + * gcc.dg/tm/memopt-5.c: Likewise. + * gcc.dg/tm/memopt-6.c: Likewise. + * gcc.dg/tm/wrap-4.c: Likewise. + 2014-10-02 Marek Polacek * gcc.dg/vect/pr24049.c: Fix implicit declarations. diff --git a/gcc/testsuite/gcc.dg/tm/20091013.c b/gcc/testsuite/gcc.dg/tm/20091013.c index d9b3b0ed3bc..3c67a82e70f 100644 --- a/gcc/testsuite/gcc.dg/tm/20091013.c +++ b/gcc/testsuite/gcc.dg/tm/20091013.c @@ -4,6 +4,7 @@ extern long ringo(long int); int g,i; +void f() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/20091221.c b/gcc/testsuite/gcc.dg/tm/20091221.c index 1d75d153a2c..4751f2bb781 100644 --- a/gcc/testsuite/gcc.dg/tm/20091221.c +++ b/gcc/testsuite/gcc.dg/tm/20091221.c @@ -4,6 +4,7 @@ int i; extern void virgin () __attribute__((transaction_pure)); +void foo() { __transaction_atomic { diff --git a/gcc/testsuite/gcc.dg/tm/20100125.c b/gcc/testsuite/gcc.dg/tm/20100125.c index 3f1dd10fea2..3b3d2b9f52b 100644 --- a/gcc/testsuite/gcc.dg/tm/20100125.c +++ b/gcc/testsuite/gcc.dg/tm/20100125.c @@ -3,6 +3,7 @@ /* Test that the call to george() doesn't end up inside the transaction. */ +void george (void); int trxn; void set_remove(int * val) diff --git a/gcc/testsuite/gcc.dg/tm/debug-1.c b/gcc/testsuite/gcc.dg/tm/debug-1.c index 01acfae4d03..bccc0b31646 100644 --- a/gcc/testsuite/gcc.dg/tm/debug-1.c +++ b/gcc/testsuite/gcc.dg/tm/debug-1.c @@ -5,11 +5,11 @@ int a,b, c, z; -testing(){ +void testing(){ c=9; } -main() { +int main() { b = 9898; __transaction_relaxed { z = c; diff --git a/gcc/testsuite/gcc.dg/tm/irrevocable-1.c b/gcc/testsuite/gcc.dg/tm/irrevocable-1.c index 60f629133ee..9f9fe3ad41d 100644 --- a/gcc/testsuite/gcc.dg/tm/irrevocable-1.c +++ b/gcc/testsuite/gcc.dg/tm/irrevocable-1.c @@ -4,8 +4,9 @@ int global; int george; -extern crap() __attribute__((transaction_unsafe)); +extern void crap() __attribute__((transaction_unsafe)); +void foo() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/irrevocable-2.c b/gcc/testsuite/gcc.dg/tm/irrevocable-2.c index 17ac8a5f0c0..9b1127f2f4d 100644 --- a/gcc/testsuite/gcc.dg/tm/irrevocable-2.c +++ b/gcc/testsuite/gcc.dg/tm/irrevocable-2.c @@ -7,6 +7,7 @@ int global; int george; +void foo() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/irrevocable-3.c b/gcc/testsuite/gcc.dg/tm/irrevocable-3.c index fdf3e52e2e4..9a9903c1ee3 100644 --- a/gcc/testsuite/gcc.dg/tm/irrevocable-3.c +++ b/gcc/testsuite/gcc.dg/tm/irrevocable-3.c @@ -3,6 +3,7 @@ extern void bar(void) __attribute__((transaction_callable)); +void foo() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/irrevocable-4.c b/gcc/testsuite/gcc.dg/tm/irrevocable-4.c index 72075df36c0..ee48f82f17e 100644 --- a/gcc/testsuite/gcc.dg/tm/irrevocable-4.c +++ b/gcc/testsuite/gcc.dg/tm/irrevocable-4.c @@ -4,7 +4,7 @@ void orig(void); void xyz(void) __attribute__((transaction_wrap (orig))); - +void foo() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/memopt-1.c b/gcc/testsuite/gcc.dg/tm/memopt-1.c index c5ac5ced56c..ac88ebd1e43 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-1.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-1.c @@ -2,10 +2,11 @@ /* { dg-options "-fgnu-tm -O -fdump-tree-tmmemopt" } */ long g, xxx, yyy; -extern george() __attribute__((transaction_safe)); -extern ringo(long int) __attribute__((transaction_safe)); +extern void george() __attribute__((transaction_safe)); +extern void ringo(long int) __attribute__((transaction_safe)); int i; +void f() { __transaction_relaxed { diff --git a/gcc/testsuite/gcc.dg/tm/memopt-11.c b/gcc/testsuite/gcc.dg/tm/memopt-11.c index 36aa66412b9..0c96f0efa8f 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-11.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-11.c @@ -3,6 +3,7 @@ extern int something(void) __attribute__((transaction_safe)); extern void *malloc (__SIZE_TYPE__) __attribute__((malloc,transaction_safe)); +extern void foo (int); int f() { diff --git a/gcc/testsuite/gcc.dg/tm/memopt-12.c b/gcc/testsuite/gcc.dg/tm/memopt-12.c index 5520ecef27a..42788167394 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-12.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-12.c @@ -2,6 +2,7 @@ /* { dg-options "-fgnu-tm -O -fdump-tree-tmmark" } */ extern int test(void) __attribute__((transaction_safe)); +extern int something (void); extern void *malloc (__SIZE_TYPE__) __attribute__((malloc,transaction_safe)); struct large { int foo[500]; }; diff --git a/gcc/testsuite/gcc.dg/tm/memopt-16.c b/gcc/testsuite/gcc.dg/tm/memopt-16.c index c230240de57..44ae3d40b30 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-16.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-16.c @@ -4,6 +4,7 @@ it to be converted into a COND_EXPR. */ extern int test(void) __attribute__((transaction_safe)); +extern int something(void); extern void *malloc (__SIZE_TYPE__) __attribute__((malloc,transaction_safe)); struct large { int foo[500]; }; diff --git a/gcc/testsuite/gcc.dg/tm/memopt-3.c b/gcc/testsuite/gcc.dg/tm/memopt-3.c index 1220ffc4a0b..d44bd7f74b4 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-3.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-3.c @@ -2,6 +2,7 @@ /* { dg-options "-fgnu-tm -O -fdump-tree-tmmark" } */ struct large { int x[100]; }; +extern int readint (void); extern int test(void) __attribute__((transaction_safe)); int f() diff --git a/gcc/testsuite/gcc.dg/tm/memopt-4.c b/gcc/testsuite/gcc.dg/tm/memopt-4.c index 58f8fd042d6..67135f3b92d 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-4.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-4.c @@ -6,6 +6,7 @@ struct large { int x[100]; }; struct large bark(); extern int test (void) __attribute__((transaction_safe)); +extern int readint (void); int f() { diff --git a/gcc/testsuite/gcc.dg/tm/memopt-5.c b/gcc/testsuite/gcc.dg/tm/memopt-5.c index 53f7f12083c..414de819565 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-5.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-5.c @@ -6,6 +6,7 @@ struct large { int x[100]; }; struct large bark(); extern int test (void) __attribute__((transaction_safe)); +extern int readint (void); int f() { diff --git a/gcc/testsuite/gcc.dg/tm/memopt-6.c b/gcc/testsuite/gcc.dg/tm/memopt-6.c index 810a5595db1..91524f900b4 100644 --- a/gcc/testsuite/gcc.dg/tm/memopt-6.c +++ b/gcc/testsuite/gcc.dg/tm/memopt-6.c @@ -4,6 +4,7 @@ struct large { int x[100]; }; struct large bark(); extern int test (void) __attribute__((transaction_safe)); +extern int readint (void); struct large lacopy; int f() diff --git a/gcc/testsuite/gcc.dg/tm/pr52173-1.c b/gcc/testsuite/gcc.dg/tm/pr52173-1.c index 9ffa4d618a7..2bda9f52cc9 100644 --- a/gcc/testsuite/gcc.dg/tm/pr52173-1.c +++ b/gcc/testsuite/gcc.dg/tm/pr52173-1.c @@ -11,6 +11,7 @@ void func() } } +int main() { int i; diff --git a/gcc/testsuite/gcc.dg/tm/props-1.c b/gcc/testsuite/gcc.dg/tm/props-1.c index 89690240486..344e6df21a9 100644 --- a/gcc/testsuite/gcc.dg/tm/props-1.c +++ b/gcc/testsuite/gcc.dg/tm/props-1.c @@ -3,6 +3,7 @@ int global; +void foo(int local) { __transaction_atomic { diff --git a/gcc/testsuite/gcc.dg/tm/props-2.c b/gcc/testsuite/gcc.dg/tm/props-2.c index 56a3ffa1367..2d2bdb8c263 100644 --- a/gcc/testsuite/gcc.dg/tm/props-2.c +++ b/gcc/testsuite/gcc.dg/tm/props-2.c @@ -6,8 +6,9 @@ int global; int george; -extern crap() __attribute__((transaction_unsafe)); +extern void crap() __attribute__((transaction_unsafe)); +void foo(){ __transaction_relaxed { global++; diff --git a/gcc/testsuite/gcc.dg/tm/props-3.c b/gcc/testsuite/gcc.dg/tm/props-3.c index 48f2230cdd2..606b9a34fd6 100644 --- a/gcc/testsuite/gcc.dg/tm/props-3.c +++ b/gcc/testsuite/gcc.dg/tm/props-3.c @@ -5,6 +5,7 @@ void (*indirect)(void); +void foo(){ __transaction_relaxed { (*indirect)(); diff --git a/gcc/testsuite/gcc.dg/tm/wrap-4.c b/gcc/testsuite/gcc.dg/tm/wrap-4.c index 9a4ec061f89..d3a6a48f8e0 100644 --- a/gcc/testsuite/gcc.dg/tm/wrap-4.c +++ b/gcc/testsuite/gcc.dg/tm/wrap-4.c @@ -1,6 +1,8 @@ /* { dg-do compile } */ /* { dg-options "-fgnu-tm -fdump-tree-optimized -O2" } */ +void bark (void); +void candycane (void); static void candy() { candycane(); } static void tootsie_roll () __attribute__((transaction_wrap (candy)));