This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

IA64 HP-UX patch (symbol reference)


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));
      }
  


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]