diff options
author | Alan Modra <amodra@gmail.com> | 2010-11-04 00:22:32 +1030 |
---|---|---|
committer | Alan Modra <amodra@gcc.gnu.org> | 2010-11-04 00:22:32 +1030 |
commit | 3df5c6f745eafcd3e39db11c4550dff434939441 (patch) | |
tree | 920c359e2b5bfc62fd6358d156406a39a10abc3f /gcc | |
parent | 22d8d6160281e66502cc39f5496119250f2b929c (diff) | |
download | gcc-3df5c6f745eafcd3e39db11c4550dff434939441.zip gcc-3df5c6f745eafcd3e39db11c4550dff434939441.tar.gz gcc-3df5c6f745eafcd3e39db11c4550dff434939441.tar.bz2 |
rs6000.c (rs6000_pic_labelno): Make static.
* config/rs6000/rs6000.c (rs6000_pic_labelno): Make static.
(rs6000_emit_load_toc_table): Don't use rs6000_pic_labelno when
TARGET_SECURE_PLT.
* config/rs6000/sysv4.h (rs6000_pic_labelno): Don't declare.
* config/rs6000/rs6000.md (load_toc_v4_PIC_3b): Use "b" constraint
on input, "r" on output.
From-SVN: r166247
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 9 | ||||
-rw-r--r-- | gcc/config/rs6000/rs6000.c | 11 | ||||
-rw-r--r-- | gcc/config/rs6000/rs6000.md | 4 | ||||
-rw-r--r-- | gcc/config/rs6000/sysv4.h | 2 |
4 files changed, 16 insertions, 10 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 2408777..49e208e 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,12 @@ +2010-11-04 Alan Modra <amodra@gmail.com> + + * config/rs6000/rs6000.c (rs6000_pic_labelno): Make static. + (rs6000_emit_load_toc_table): Don't use rs6000_pic_labelno when + TARGET_SECURE_PLT. + * config/rs6000/sysv4.h (rs6000_pic_labelno): Don't declare. + * config/rs6000/rs6000.md (load_toc_v4_PIC_3b): Use "b" constraint + on input, "r" on output. + 2010-11-03 Nicola Pero <nicola.pero@meta-innovation.com> Implemented -fobjc-std=objc1 flag. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 78f0a14..d7d94ef 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -193,7 +193,7 @@ static GTY(()) int common_mode_defined; /* Label number of label created for -mrelocatable, to call to so we can get the address of the GOT section */ -int rs6000_pic_labelno; +static int rs6000_pic_labelno; #ifdef USING_ELFOS_H /* Which abi to adhere to */ @@ -18898,7 +18898,8 @@ rs6000_emit_load_toc_table (int fromprolog) char buf[30]; rtx lab, tmp1, tmp2, got; - ASM_GENERATE_INTERNAL_LABEL (buf, "LCF", rs6000_pic_labelno); + lab = gen_label_rtx (); + ASM_GENERATE_INTERNAL_LABEL (buf, "L", CODE_LABEL_NUMBER (lab)); lab = gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (buf)); if (flag_pic == 2) got = gen_rtx_SYMBOL_REF (Pmode, toc_label_name); @@ -18911,8 +18912,7 @@ rs6000_emit_load_toc_table (int fromprolog) tmp2 = gen_reg_rtx (Pmode); } emit_insn (gen_load_toc_v4_PIC_1 (lab)); - emit_move_insn (tmp1, - gen_rtx_REG (Pmode, LR_REGNO)); + emit_move_insn (tmp1, gen_rtx_REG (Pmode, LR_REGNO)); emit_insn (gen_load_toc_v4_PIC_3b (tmp2, tmp1, got, lab)); emit_insn (gen_load_toc_v4_PIC_3c (dest, tmp2, got, lab)); } @@ -18939,8 +18939,7 @@ rs6000_emit_load_toc_table (int fromprolog) symL = gen_rtx_SYMBOL_REF (Pmode, ggc_strdup (buf)); emit_insn (gen_load_toc_v4_PIC_1 (symF)); - emit_move_insn (dest, - gen_rtx_REG (Pmode, LR_REGNO)); + emit_move_insn (dest, gen_rtx_REG (Pmode, LR_REGNO)); emit_insn (gen_load_toc_v4_PIC_2 (temp0, dest, symL, symF)); } else diff --git a/gcc/config/rs6000/rs6000.md b/gcc/config/rs6000/rs6000.md index f1e63cc..1dbf52c 100644 --- a/gcc/config/rs6000/rs6000.md +++ b/gcc/config/rs6000/rs6000.md @@ -12187,8 +12187,8 @@ [(set_attr "type" "load")]) (define_insn "load_toc_v4_PIC_3b" - [(set (match_operand:SI 0 "gpc_reg_operand" "=b") - (plus:SI (match_operand:SI 1 "gpc_reg_operand" "r") + [(set (match_operand:SI 0 "gpc_reg_operand" "=r") + (plus:SI (match_operand:SI 1 "gpc_reg_operand" "b") (high:SI (minus:SI (match_operand:SI 2 "symbol_ref_operand" "s") (match_operand:SI 3 "symbol_ref_operand" "s")))))] diff --git a/gcc/config/rs6000/sysv4.h b/gcc/config/rs6000/sysv4.h index 04cc70e..de2ebd5 100644 --- a/gcc/config/rs6000/sysv4.h +++ b/gcc/config/rs6000/sysv4.h @@ -402,8 +402,6 @@ do { \ Some svr4 assemblers need to also have something extra said about the function's return value. We allow for that here. */ -extern int rs6000_pic_labelno; - /* Override elfos.h definition. */ #undef ASM_DECLARE_FUNCTION_NAME #define ASM_DECLARE_FUNCTION_NAME(FILE, NAME, DECL) \ |