diff options
author | Andrew Pinski <pinskia@physics.uc.edu> | 2004-11-08 04:42:36 +0000 |
---|---|---|
committer | Andrew Pinski <pinskia@gcc.gnu.org> | 2004-11-07 20:42:36 -0800 |
commit | b8a55285ffabec4803d92012cc42a3e1729b802f (patch) | |
tree | 6c021f55a1153c8f7ced79bcd0b7d343f6b17bba /gcc/config/darwin.c | |
parent | 79fd859270b76814800f67c8aea0345356efd8d8 (diff) | |
download | gcc-b8a55285ffabec4803d92012cc42a3e1729b802f.zip gcc-b8a55285ffabec4803d92012cc42a3e1729b802f.tar.gz gcc-b8a55285ffabec4803d92012cc42a3e1729b802f.tar.bz2 |
re PR target/18269 (-m64 -fPIC does not work on ppc-darwin)
2004-11-07 Andrew Pinski <pinskia@physics.uc.edu>
PR target/18269
* config/darwin.c (machopic_indirect_data_reference):
Call gen_macho_high and gen_macho_low instead of
checking the mode and calling gen_macho_high_di directly.
* config/rs6000/rs6000.c (rs6000_emit_move): Likewise.
* config/rs6000/rs6000.md: Move most of TARGET_MACHO expand/insns
to darwin.md.
(movdf_low, movsf_low, movsf_low_st, movsi_low, macho_correct_pic,
load_macho_picbase, macho_low, macho_high): Removed.
(builtin_setjmp_receiver): Call gen_macho_high and
gen_macho_low instead of checking the mode and calling
gen_macho_high_di directly.
* config/rs6000/darwin.md (load_macho_picbase_di): Use the MD constant.
(movdf_low_si, movsf_low_si, movsf_low_st_si, movsi_low_st):
Moved from rs6000.md.
(macho_high): New expander.
(macho_high_si): Renamed version of macho_high from rs6000.md.
(macho_low): New expander.
(macho_low_si): Renamed version of macho_low from rs6000.md.
(load_macho_picbase): New expander.
(load_macho_picbase_si): Renamed version of load_macho_picbase
from rs6000.md.
(macho_correct_pic): New expander.
(macho_correct_pic_si): Renamed version of macho_correct_pic
from rs6000.md.
From-SVN: r90257
Diffstat (limited to 'gcc/config/darwin.c')
-rw-r--r-- | gcc/config/darwin.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/gcc/config/darwin.c b/gcc/config/darwin.c index 73581f7..e01b383 100644 --- a/gcc/config/darwin.c +++ b/gcc/config/darwin.c @@ -412,12 +412,8 @@ machopic_indirect_data_reference (rtx orig, rtx reg) if (defined && MACHO_DYNAMIC_NO_PIC_P) { #if defined (TARGET_TOC) - emit_insn (GET_MODE (orig) == DImode - ? gen_macho_high_di (reg, orig) - : gen_macho_high (reg, orig)); - emit_insn (GET_MODE (orig) == DImode - ? gen_macho_low_di (reg, reg, orig) - : gen_macho_low (reg, reg, orig)); + emit_insn (gen_macho_high (reg, orig)); + emit_insn (gen_macho_low (reg, reg, orig)); #else /* some other cpu -- writeme! */ abort (); @@ -613,9 +609,7 @@ machopic_legitimize_pic_address (rtx orig, enum machine_mode mode, rtx reg) rtx asym = XEXP (orig, 0); rtx mem; - emit_insn (mode == DImode - ? gen_macho_high_di (temp_reg, asym) - : gen_macho_high (temp_reg, asym)); + emit_insn (gen_macho_high (temp_reg, asym)); mem = gen_const_mem (GET_MODE (orig), gen_rtx_LO_SUM (Pmode, temp_reg, asym)); emit_insn (gen_rtx_SET (VOIDmode, reg, mem)); |