mirror of git://gcc.gnu.org/git/gcc.git
ptx testsuite fixes for issues like indirect jumps and jump labels.
* lib/target-supports.exp (check_effective_target_indirect_jumps): New function. (check_effective_target_nonlocal_goto): New function. (check_effective_target_label_values): New function. * gcc.c-torture/execute/20071220-2.c: Require label_values. * gcc.c-torture/compile/labels-2.c: Likewise. * gcc.c-torture/compile/20000518-1.c: Likewise. * gcc.c-torture/compile/20021108-1.c: Likewise. * gcc.c-torture/compile/981006-1.c: Likewise. * gcc.c-torture/execute/20040302-1.c: Likewise. * gcc.dg/torture/pr33848.c: Likewise. * gcc.c-torture/compile/pr46107.c: Require indirect jumps and label values. * gcc.c-torture/compile/pr32919.c: Likewise. * gcc.c-torture/compile/pr17913.c: Likewise. * gcc.c-torture/compile/pr51495.c: Likewise. * gcc.c-torture/compile/pr25224.c: Likewise. * gcc.c-torture/compile/labels-3.c: Likewise. * gcc.c-torture/compile/pr27863.c: Likewise. * gcc.c-torture/compile/20050510-1.c: Likewise. * gcc.c-torture/compile/pr28489.c: Likewise. * gcc.c-torture/compile/pr29128.c: Likewise. * gcc.c-torture/compile/pr21356: Likewise. * gcc.c-torture/execute/20071210-1.c: Likewise. * gcc.c-torture/execute/200701220-1.c: Likewise. * gcc.c-torture/execute/pr51447.c: Likewise. * gcc.c-torture/execute/comp-goto-1.c: Likewise. * gcc.c-torture/execute/comp-goto-2.c: Likewise. * gcc.dg/20021029-1.c: Likewise. * gcc.dg/pr43379.c: Likewise. * gcc.dg/pr45259.c: Likewise. * gcc.dg/torture/pr53695.c: Likewise. * gcc.dg/torture/pr57584.c: Likewise. * gcc.c-torture/execute/980526-1.c: Skip if -O0 and neither label_values or indirect_jumps are available. * gcc.c-torture/compile/920415-1.c: Likewise. Remove NO_LABEL_VALUES test. * gcc.c-torture/compile/920428-3.c: Likewise. * gcc.c-torture/compile/950613-1.c: Likewise. * gcc.c-torture/compile/pr30984.c: Require indirect jumps. * gcc.c-torture/compile/991213-3.c: Likewise. * gcc.c-torture/compile/920825-1.c: Likewise. * gcc.c-torture/compile/20011029-1.c: Likewise. * gcc.c-torture/compile/complex-6.c: Likewise. * gcc.c-torture/compile/pr27127.c: Likewise. * gcc.c-torture/compile/pr58164.c: Likewise. * gcc.c-torture/compile/20041214-1.c: Likewise. * gcc.c-torture/execute/built-in-setjmp.c: Likewise. * gcc.c-torture/execute/pr56982.c: Likewise. * gcc.c-torture/execute/pr60003.c: Likewise. * gcc.c-torture/execute/pr26983.c: Likewise. * gcc.dg/pr57287-2.c: Likewise. * gcc.dg/pr59920-1.c: Likewise. * gcc.dg/pr59920-2.c: Likewise. * gcc.dg/pr59920-3.c: Likewise. * gcc.dg/setjmp-3.c: Likewise. * gcc.dg/setjmp-4.c: Likewise. * gcc.dg/setjmp-5.c: Likewise. * gcc.dg/torture/pr48542.c: Likewise. * gcc.dg/torture/pr57147-2.c: Likewise. * gcc.dg/torture/pr59993.c: Likewise. * gcc.dg/torture/stackalign/non-local-goto-1.c: Require nonlocal_goto. * gcc.dg/torture/stackalign/non-local-goto-2.c: Likewise. * gcc.dg/torture/stackalign/non-local-goto-3.c: Likewise. * gcc.dg/torture/stackalign/non-local-goto-4.c: Likewise. * gcc.dg/torture/stackalign/non-local-goto-5.c: Likewise. * gcc.dg/torture/stackalign/setjmp-1.c: Likewise. * gcc.dg/torture/stackalign/setjmp-3.c: Likewise. * gcc.dg/torture/stackalign/setjmp-4.c: Likewise. * gcc.dg/non-local-goto-1.c: Likewise. * gcc.dg/non-local-goto-2.c: Likewise. * gcc.dg/pr49994-1.c: Likewise. * gcc.dg/torture/pr57036-2.c: Likewise. * gcc.c-torture/compile/20040614-1.c: Require label_values. Remove NO_LABEL_VALUES test. * gcc.c-torture/compile/920831-1.c: Likewise. * gcc.c-torture/compile/920502-1.c: Likewise. * gcc.c-torture/compile/920501-7.c: Likewise. * gcc.dg/pr52139.c: Likewise. From-SVN: r217299
This commit is contained in:
parent
fb61af8ba8
commit
631da28efe
|
|
@ -1,5 +1,90 @@
|
||||||
2014-11-10 Bernd Schmidt <bernds@codesourcery.com>
|
2014-11-10 Bernd Schmidt <bernds@codesourcery.com>
|
||||||
|
|
||||||
|
* lib/target-supports.exp (check_effective_target_indirect_jumps):
|
||||||
|
New function.
|
||||||
|
(check_effective_target_nonlocal_goto): New function.
|
||||||
|
(check_effective_target_label_values): New function.
|
||||||
|
* gcc.c-torture/execute/20071220-2.c: Require label_values.
|
||||||
|
* gcc.c-torture/compile/labels-2.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/20000518-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/20021108-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/981006-1.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/20040302-1.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr33848.c: Likewise.
|
||||||
|
|
||||||
|
* gcc.c-torture/compile/pr46107.c: Require indirect jumps and
|
||||||
|
label values.
|
||||||
|
* gcc.c-torture/compile/pr32919.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr17913.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr51495.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr25224.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/labels-3.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr27863.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/20050510-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr28489.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr29128.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr21356: Likewise.
|
||||||
|
* gcc.c-torture/execute/20071210-1.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/200701220-1.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/pr51447.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/comp-goto-1.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/comp-goto-2.c: Likewise.
|
||||||
|
* gcc.dg/20021029-1.c: Likewise.
|
||||||
|
* gcc.dg/pr43379.c: Likewise.
|
||||||
|
* gcc.dg/pr45259.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr53695.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr57584.c: Likewise.
|
||||||
|
|
||||||
|
* gcc.c-torture/execute/980526-1.c: Skip if -O0 and neither label_values
|
||||||
|
or indirect_jumps are available.
|
||||||
|
* gcc.c-torture/compile/920415-1.c: Likewise. Remove NO_LABEL_VALUES
|
||||||
|
test.
|
||||||
|
* gcc.c-torture/compile/920428-3.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/950613-1.c: Likewise.
|
||||||
|
|
||||||
|
* gcc.c-torture/compile/pr30984.c: Require indirect jumps.
|
||||||
|
* gcc.c-torture/compile/991213-3.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/920825-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/20011029-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/complex-6.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr27127.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/pr58164.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/20041214-1.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/built-in-setjmp.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/pr56982.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/pr60003.c: Likewise.
|
||||||
|
* gcc.c-torture/execute/pr26983.c: Likewise.
|
||||||
|
* gcc.dg/pr57287-2.c: Likewise.
|
||||||
|
* gcc.dg/pr59920-1.c: Likewise.
|
||||||
|
* gcc.dg/pr59920-2.c: Likewise.
|
||||||
|
* gcc.dg/pr59920-3.c: Likewise.
|
||||||
|
* gcc.dg/setjmp-3.c: Likewise.
|
||||||
|
* gcc.dg/setjmp-4.c: Likewise.
|
||||||
|
* gcc.dg/setjmp-5.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr48542.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr57147-2.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr59993.c: Likewise.
|
||||||
|
|
||||||
|
* gcc.dg/torture/stackalign/non-local-goto-1.c: Require nonlocal_goto.
|
||||||
|
* gcc.dg/torture/stackalign/non-local-goto-2.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/non-local-goto-3.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/non-local-goto-4.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/non-local-goto-5.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/setjmp-1.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/setjmp-3.c: Likewise.
|
||||||
|
* gcc.dg/torture/stackalign/setjmp-4.c: Likewise.
|
||||||
|
* gcc.dg/non-local-goto-1.c: Likewise.
|
||||||
|
* gcc.dg/non-local-goto-2.c: Likewise.
|
||||||
|
* gcc.dg/pr49994-1.c: Likewise.
|
||||||
|
* gcc.dg/torture/pr57036-2.c: Likewise.
|
||||||
|
|
||||||
|
* gcc.c-torture/compile/20040614-1.c: Require label_values. Remove
|
||||||
|
NO_LABEL_VALUES test.
|
||||||
|
* gcc.c-torture/compile/920831-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/920502-1.c: Likewise.
|
||||||
|
* gcc.c-torture/compile/920501-7.c: Likewise.
|
||||||
|
* gcc.dg/pr52139.c: Likewise.
|
||||||
|
|
||||||
* lib/target-supports.exp (check_effective_target_trampolines,
|
* lib/target-supports.exp (check_effective_target_trampolines,
|
||||||
check_profiling_available, check_effective_target_lto,
|
check_profiling_available, check_effective_target_lto,
|
||||||
check_effective_target_vect_natural): False for nvptx-*-*.
|
check_effective_target_vect_natural): False for nvptx-*-*.
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void callit1(void*);
|
void callit1(void*);
|
||||||
|
|
||||||
extern __inline__ void test()
|
extern __inline__ void test()
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
void foo (void *) __attribute__ ((noreturn));
|
void foo (void *) __attribute__ ((noreturn));
|
||||||
|
|
||||||
void
|
void
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
int
|
int
|
||||||
main()
|
main()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
#ifndef NO_LABEL_VALUES
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void f(int r1, int *fp)
|
void f(int r1, int *fp)
|
||||||
{
|
{
|
||||||
void *hlbl_tbl[] = { &&label1 };
|
void *hlbl_tbl[] = { &&label1 };
|
||||||
|
|
@ -15,6 +16,5 @@ void f(int r1, int *fp)
|
||||||
label2:
|
label2:
|
||||||
;
|
;
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
int x;
|
int x;
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void bar (int k)
|
void bar (int k)
|
||||||
{
|
{
|
||||||
void *label = (k) ? &&x : &&y;
|
void *label = (k) ? &&x : &&y;
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,9 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
extern void exit (int);
|
extern void exit (int);
|
||||||
|
|
||||||
#ifndef NO_LABEL_VALUES
|
|
||||||
f ()
|
f ()
|
||||||
{
|
{
|
||||||
__label__ l;
|
__label__ l;
|
||||||
|
|
@ -15,6 +17,3 @@ f ()
|
||||||
l:
|
l:
|
||||||
exit (0);
|
exit (0);
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
int x;
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,4 @@
|
||||||
#ifndef NO_LABEL_VALUES
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
x(a){static void*j[]={&&l1,&&l2};goto*j[a];l1:return 0;l2:return 1;}
|
x(a){static void*j[]={&&l1,&&l2};goto*j[a];l1:return 0;l2:return 1;}
|
||||||
#else
|
|
||||||
main(){ exit (0); }
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,3 @@
|
||||||
#ifndef NO_LABEL_VALUES
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
x(){if(&&e-&&b<0)x();b:goto*&&b;e:;}
|
x(){if(&&e-&&b<0)x();b:goto*&&b;e:;}
|
||||||
#else
|
|
||||||
int x;
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern void*t[];x(i){goto*t[i];}
|
extern void*t[];x(i){goto*t[i];}
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
f(int*x){goto*(char)*x;}
|
f(int*x){goto*(char)*x;}
|
||||||
|
|
|
||||||
|
|
@ -1 +1,3 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
f(x){goto*(char)x;}
|
f(x){goto*(char)x;}
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
#ifndef NO_LABEL_VALUES
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
f ()
|
f ()
|
||||||
{
|
{
|
||||||
long *sp;
|
long *sp;
|
||||||
|
|
@ -26,6 +28,3 @@ f ()
|
||||||
goto *pc++;
|
goto *pc++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#else
|
|
||||||
int x;
|
|
||||||
#endif
|
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@
|
||||||
/* For MIPS at least, pic is needed to trigger the problem. */
|
/* For MIPS at least, pic is needed to trigger the problem. */
|
||||||
/* { dg-options "-w -Wuninitialized -Werror -fpic" } */
|
/* { dg-options "-w -Wuninitialized -Werror -fpic" } */
|
||||||
/* { dg-options "-w -Wuninitialized -Werror" { target { { rs6000-*-aix* powerpc*-*-aix* arm*-*-* fr30-*-* sh-*-hms h8300*-*-* cris-*-elf* mmix-*-* } || { ! fpic } } } } */
|
/* { dg-options "-w -Wuninitialized -Werror" { target { { rs6000-*-aix* powerpc*-*-aix* arm*-*-* fr30-*-* sh-*-hms h8300*-*-* cris-*-elf* mmix-*-* } || { ! fpic } } } } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
int foo (int a, int b)
|
int foo (int a, int b)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,2 +1,4 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
int jump () { goto * (int (*) ()) 0xbabebec0; }
|
int jump () { goto * (int (*) ()) 0xbabebec0; }
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* PR tree-opt/35737 */
|
/* PR tree-opt/35737 */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
long buf[10];
|
long buf[10];
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
struct bp { void *v, *b, *e; };
|
struct bp { void *v, *b, *e; };
|
||||||
f ()
|
f ()
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* Verify that we can narrow the storage associated with label diffs. */
|
/* Verify that we can narrow the storage associated with label diffs. */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
int foo (int a)
|
int foo (int a)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,7 @@
|
||||||
/* Test for computed jump into cond_expr: bug 17913. */
|
/* Test for computed jump into cond_expr: bug 17913. */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void f (void)
|
void f (void)
|
||||||
{
|
{
|
||||||
void *p = &&a;
|
void *p = &&a;
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
int a;
|
int a;
|
||||||
void* p;
|
void* p;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
int main (void)
|
int main (void)
|
||||||
{
|
{
|
||||||
__label__ l1;
|
__label__ l1;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,7 @@
|
||||||
/* { dg-options "-funswitch-loops" } */
|
/* { dg-options "-funswitch-loops" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
static float rgam;
|
static float rgam;
|
||||||
extern void *jmp(void *);
|
extern void *jmp(void *);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,7 @@
|
||||||
/* This test used to ICE on IA64. */
|
/* This test used to ICE on IA64. */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
long stack[100];
|
long stack[100];
|
||||||
int main(int argc,char**argv,char **envp)
|
int main(int argc,char**argv,char **envp)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
typedef int c_int;
|
typedef int c_int;
|
||||||
union c_insn
|
union c_insn
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
typedef unsigned long Eterm;
|
typedef unsigned long Eterm;
|
||||||
process_main (void)
|
process_main (void)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
int fs_exec(int ino)
|
int fs_exec(int ino)
|
||||||
{
|
{
|
||||||
void *src = 0;
|
void *src = 0;
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,6 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void _IO_vfprintf_internal ( char *f )
|
void _IO_vfprintf_internal ( char *f )
|
||||||
{
|
{
|
||||||
static const void *const step0_jumps[] = { &&do_form_unknown, &&do_flag_plus, &&do_form_float };
|
static const void *const step0_jumps[] = { &&do_form_unknown, &&do_flag_plus, &&do_form_float };
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void jumpfunc(int copy, void *p)
|
void jumpfunc(int copy, void *p)
|
||||||
{
|
{
|
||||||
void *l = &&jumplabel;
|
void *l = &&jumplabel;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* PR tree-optimization/46107 */
|
/* PR tree-optimization/46107 */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
int foo (void) __attribute__ ((noreturn));
|
int foo (void) __attribute__ ((noreturn));
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* PR rtl-optimization/51495 */
|
/* PR rtl-optimization/51495 */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void bar (void);
|
void bar (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* PR tree-optimization/58164 */
|
/* PR tree-optimization/58164 */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
int
|
int
|
||||||
foo (void)
|
foo (void)
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
int code[]={0,0,0,0,1};
|
int code[]={0,0,0,0,1};
|
||||||
|
|
||||||
void foo(int x) {
|
void foo(int x) {
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
typedef long unsigned int size_t;
|
typedef long unsigned int size_t;
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
extern char *strcpy (char *, const char *);
|
extern char *strcpy (char *, const char *);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* PR rtl-optimization/34302 */
|
/* PR rtl-optimization/34302 */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* PR tree-optimization/29484 */
|
/* PR tree-optimization/29484 */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* PR tree-optimization/29484 */
|
/* PR tree-optimization/29484 */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,5 @@
|
||||||
|
/* { dg-skip-if "requires indirect jumps" { ! indirect_jumps } { "-O0" } { "" } } */
|
||||||
|
/* { dg-skip-if "requires label values" { ! label_values } { "-O0" } { "" } } */
|
||||||
int expect_do1 = 1, expect_do2 = 2;
|
int expect_do1 = 1, expect_do2 = 2;
|
||||||
|
|
||||||
static int doit(int x){
|
static int doit(int x){
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
/* { dg-require-effective-target alloca } */
|
/* { dg-require-effective-target alloca } */
|
||||||
|
|
||||||
extern int strcmp(const char *, const char *);
|
extern int strcmp(const char *, const char *);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* PR rtl-optimization/51447 */
|
/* PR rtl-optimization/51447 */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* PR tree-optimization/60003 */
|
/* PR tree-optimization/60003 */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,8 @@
|
||||||
/* { dg-options "-O2 -fpic" } */
|
/* { dg-options "-O2 -fpic" } */
|
||||||
/* { dg-options "-O2 -fpic -mpt-fixed" { target sh64*-*-* } } */
|
/* { dg-options "-O2 -fpic -mpt-fixed" { target sh64*-*-* } } */
|
||||||
/* { dg-final { scan-assembler-not ".data.rel.ro.local" } } */
|
/* { dg-final { scan-assembler-not ".data.rel.ro.local" } } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
int foo (int a)
|
int foo (int a)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,8 @@
|
||||||
/* Origin: Joseph Myers <joseph@codesourcery.com> */
|
/* Origin: Joseph Myers <joseph@codesourcery.com> */
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "" } */
|
/* { dg-options "" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void
|
void
|
||||||
f (void)
|
f (void)
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,8 @@
|
||||||
/* Origin: Joseph Myers <joseph@codesourcery.com> */
|
/* Origin: Joseph Myers <joseph@codesourcery.com> */
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-pedantic" } */
|
/* { dg-options "-pedantic" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void
|
void
|
||||||
f (void)
|
f (void)
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
/* { dg-options "-O2" } */
|
/* { dg-options "-O2" } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
/* { dg-options "-O2" } */
|
/* { dg-options "-O2" } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do link } */
|
/* { dg-do link } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
/* This used to cause a linker failure because GCC would output
|
/* This used to cause a linker failure because GCC would output
|
||||||
assembler code referencing labels that it had not output. */
|
assembler code referencing labels that it had not output. */
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O2 -ftracer -w" } */
|
/* { dg-options "-O2 -ftracer -w" } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
void *foo(int i, int *p)
|
void *foo(int i, int *p)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,8 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-g -O2 -w -fpic" { target fpic } } */
|
/* { dg-options "-g -O2 -w -fpic" { target fpic } } */
|
||||||
/* { dg-options "-g -O2 -w" { target { ! fpic } } } */
|
/* { dg-options "-g -O2 -w" { target { ! fpic } } } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
struct S { void (*bar) (long); };
|
struct S { void (*bar) (long); };
|
||||||
struct T { struct S *t; };
|
struct T { struct S *t; };
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-Os -fsched2-use-superblocks -g" } */
|
/* { dg-options "-Os -fsched2-use-superblocks -g" } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
void x (int a)
|
void x (int a)
|
||||||
{
|
{
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O -fno-tree-dominator-opts -fno-tree-fre" } */
|
/* { dg-options "-O -fno-tree-dominator-opts -fno-tree-fre" } */
|
||||||
/* { dg-additional-options "-fpic" { target fpic } } */
|
/* { dg-additional-options "-fpic" { target fpic } } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void *p;
|
void *p;
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O2 -Wall" } */
|
/* { dg-options "-O2 -Wall" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O2 -Wall" } */
|
/* { dg-options "-O2 -Wall" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
/* PR tree-optimization/59920 */
|
/* PR tree-optimization/59920 */
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O0" } */
|
/* { dg-options "-O0" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,8 @@
|
||||||
/* PR tree-optimization/59920 */
|
/* PR tree-optimization/59920 */
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O0" } */
|
/* { dg-options "-O0" } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
void *bar (void **);
|
void *bar (void **);
|
||||||
void *baz (int, void **);
|
void *baz (int, void **);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
/* PR tree-optimization/59920 */
|
/* PR tree-optimization/59920 */
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O0" } */
|
/* { dg-options "-O0" } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
void *bar (void **);
|
void *bar (void **);
|
||||||
void *baz (int, void **);
|
void *baz (int, void **);
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
/* { dg-options "-O" } */
|
/* { dg-options "-O" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
/* { dg-options "-O" } */
|
/* { dg-options "-O" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,6 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-O2 -Wall" } */
|
/* { dg-options "-O2 -Wall" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,4 @@
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
/* &&foo should be hoisted, but on most targets, excess register pressure
|
/* &&foo should be hoisted, but on most targets, excess register pressure
|
||||||
forces it to be rematerialized before "data != &&foo". On targets that
|
forces it to be rematerialized before "data != &&foo". On targets that
|
||||||
have a "branch if registers are equal" instruction, this leads to the
|
have a "branch if registers are equal" instruction, this leads to the
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,6 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
/* The return-address was clobbered. */
|
/* The return-address was clobbered. */
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-ftracer" } */
|
/* { dg-options "-ftracer" } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
|
||||||
void
|
void
|
||||||
foo (const void **p)
|
foo (const void **p)
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
int j_;
|
int j_;
|
||||||
void g (void);
|
void g (void);
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-options "-fdump-tree-optimized" } */
|
/* { dg-options "-fdump-tree-optimized" } */
|
||||||
/* { dg-skip-if "" { *-*-* } { "-fno-fat-lto-objects" } { "" } } */
|
/* { dg-skip-if "" { *-*-* } { "-fno-fat-lto-objects" } { "" } } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
struct __jmp_buf_tag {};
|
struct __jmp_buf_tag {};
|
||||||
typedef struct __jmp_buf_tag jmp_buf[1];
|
typedef struct __jmp_buf_tag jmp_buf[1];
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,7 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
/* { dg-require-effective-target int32plus } */
|
/* { dg-require-effective-target int32plus } */
|
||||||
|
/* { dg-require-effective-target label_values } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
typedef int int32_t;
|
typedef int int32_t;
|
||||||
typedef unsigned char uint8_t;
|
typedef unsigned char uint8_t;
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do compile } */
|
/* { dg-do compile } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
#ifndef NO_TRAMPOLINES
|
#ifndef NO_TRAMPOLINES
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void abort (void);
|
extern void abort (void);
|
||||||
extern void exit (int);
|
extern void exit (int);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target nonlocal_goto } */
|
||||||
|
|
||||||
extern void exit (int);
|
extern void exit (int);
|
||||||
#if !defined (NO_LABEL_VALUES) && !defined (NO_TRAMPOLINES)
|
#if !defined (NO_LABEL_VALUES) && !defined (NO_TRAMPOLINES)
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
extern int strcmp(const char *, const char *);
|
extern int strcmp(const char *, const char *);
|
||||||
extern char *strcpy(char *, const char *);
|
extern char *strcpy(char *, const char *);
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,5 @@
|
||||||
/* { dg-do run } */
|
/* { dg-do run } */
|
||||||
|
/* { dg-require-effective-target indirect_jumps } */
|
||||||
|
|
||||||
#include <setjmp.h>
|
#include <setjmp.h>
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -601,6 +601,37 @@ proc add_options_for_tls { flags } {
|
||||||
return $flags
|
return $flags
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# Return 1 if indirect jumps are supported, 0 otherwise.
|
||||||
|
|
||||||
|
proc check_effective_target_indirect_jumps {} {
|
||||||
|
if { [istarget nvptx-*-*] } {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Return 1 if nonlocal goto is supported, 0 otherwise.
|
||||||
|
|
||||||
|
proc check_effective_target_nonlocal_goto {} {
|
||||||
|
if { [istarget nvptx-*-*] } {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
return 1
|
||||||
|
}
|
||||||
|
|
||||||
|
# Return 1 if taking label values is supported, 0 otherwise.
|
||||||
|
|
||||||
|
proc check_effective_target_label_values {} {
|
||||||
|
if { [istarget nvptx-*-*] } {
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
return [check_no_compiler_messages label_values assembly {
|
||||||
|
#ifdef NO_LABEL_VALUES
|
||||||
|
#error NO
|
||||||
|
#endif
|
||||||
|
}]
|
||||||
|
}
|
||||||
|
|
||||||
# Return 1 if the assembler does not verify function types against
|
# Return 1 if the assembler does not verify function types against
|
||||||
# calls, 0 otherwise. Such verification will typically show up problems
|
# calls, 0 otherwise. Such verification will typically show up problems
|
||||||
# with K&R C function declarations.
|
# with K&R C function declarations.
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue