diff options
author | J"orn Rennecke <joern.rennecke@superh.com> | 2002-04-24 21:47:44 +0000 |
---|---|---|
committer | Joern Rennecke <amylaar@gcc.gnu.org> | 2002-04-24 22:47:44 +0100 |
commit | 309d8365e52baa9efd7ec572127c9db57c03570b (patch) | |
tree | 31bc2b389ed1d4cb05ebdc87d60b88dba8451bdc | |
parent | 51214775d039b7818a3a60222ed6dfcc37539b17 (diff) | |
download | gcc-309d8365e52baa9efd7ec572127c9db57c03570b.zip gcc-309d8365e52baa9efd7ec572127c9db57c03570b.tar.gz gcc-309d8365e52baa9efd7ec572127c9db57c03570b.tar.bz2 |
sh.h (PIC_OFFSET_TABLE_REGNUM): Conditionalize on flag_pic.
* sh.h (PIC_OFFSET_TABLE_REGNUM): Conditionalize on flag_pic.
testsuite:
* gcc.dg/20020312-2.c: Add SH target.
From-SVN: r52733
-rw-r--r-- | gcc/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/config/sh/sh.h | 2 | ||||
-rw-r--r-- | gcc/testsuite/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/20020312-2.c | 2 |
4 files changed, 10 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 7ad7742..a4933fe 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,4 +1,6 @@ -Wed Apr 24 21:25:59 2002 J"orn Rennecke <joern.rennecke@superh.com> +Wed Apr 24 21:35:11 2002 J"orn Rennecke <joern.rennecke@superh.com> + + * sh.h (PIC_OFFSET_TABLE_REGNUM): Conditionalize on flag_pic. * sh.md (divsi3_i4_media): Use match_operand for input values rather than hard registers. diff --git a/gcc/config/sh/sh.h b/gcc/config/sh/sh.h index d234045..6694270 100644 --- a/gcc/config/sh/sh.h +++ b/gcc/config/sh/sh.h @@ -898,7 +898,7 @@ extern char sh_additional_register_names[ADDREGNAMES_SIZE] \ /* Register to hold the addressing base for position independent code access to data items. */ -#define PIC_OFFSET_TABLE_REGNUM PIC_REG +#define PIC_OFFSET_TABLE_REGNUM (flag_pic ? PIC_REG : INVALID_REGNUM) #define GOT_SYMBOL_NAME "*_GLOBAL_OFFSET_TABLE_" diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 0591fec..9589e8a 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +Wed Apr 24 21:38:36 2002 J"orn Rennecke <joern.rennecke@superh.com> + + * gcc.dg/20020312-2.c: Add SH target. + 2002-04-24 Kaveh R. Ghazi <ghazi@caip.rutgers.edu> * gcc.c-torture/compile/labels-3.x: New file, don't assemble the diff --git a/gcc/testsuite/gcc.dg/20020312-2.c b/gcc/testsuite/gcc.dg/20020312-2.c index 5ca35c8..0ceffc7 100644 --- a/gcc/testsuite/gcc.dg/20020312-2.c +++ b/gcc/testsuite/gcc.dg/20020312-2.c @@ -94,6 +94,8 @@ /* No pic register. */ #elif defined(__XTENSA__) /* No pic register. */ +#elif defined(__sh__) +# define PIC_REG "r12" #else # error "Modify the test for your target." #endif |