This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
IA64 HP-UX patch (symbol reference)
- From: Steve Ellcey <sje at cup dot hp dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Tue, 24 Sep 2002 08:34:51 -0700 (PDT)
- Subject: IA64 HP-UX patch (symbol reference)
- Reply-to: sje at cup dot hp dot com
This is a patch to make sure that ia64_expand_load_address returns an
address in the correct mode. In ILP32 mode this may be 32 or 64 bit
mode depending on the caller.
Steve Ellcey
sje@cup.hp.com
Steve Ellcey <sje@cup.hp.com>
* config/ia64/ia64.c (ia64_expand_load_address): Ensure correct mode
for symbol address.
*** gcc.orig/gcc/config/ia64/ia64.c Tue Sep 24 08:29:26 2002
--- gcc/gcc/config/ia64/ia64.c Tue Sep 24 08:29:46 2002
*************** ia64_expand_load_address (dest, src, scr
*** 1041,1046 ****
--- 1041,1050 ----
scratch = no_new_pseudos ? temp : gen_reg_rtx (DImode);
insn = emit_insn (gen_load_symptr (temp, src, scratch));
+ #ifdef POINTERS_EXTEND_UNSIGNED
+ if ((GET_MODE(temp) == Pmode) && (GET_MODE(src) != Pmode))
+ src = convert_memory_address(Pmode, src);
+ #endif
REG_NOTES (insn) = gen_rtx_EXPR_LIST (REG_EQUAL, src, REG_NOTES (insn));
}