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]

[PATCH 02/10] addr32: Only handle zero-extended DImode addresses


Hi,

We only need to handle zero-extended addresses in DImode.
OK for trunk?

BTW, all my 10 addr32 patches are tested on Linux/x86-64.

Thanks.


H.J.
---
2012-03-02  H.J. Lu  <hongjiu.lu@intel.com>

	* config/i386/i386.c (ix86_print_operand_address): Only handle
	zero-extended DImode addresses.

diff --git a/gcc/config/i386/i386.c b/gcc/config/i386/i386.c
index 2cbfb64..7cb8fda 100644
--- a/gcc/config/i386/i386.c
+++ b/gcc/config/i386/i386.c
@@ -14511,7 +14511,7 @@ ix86_print_operand_address (FILE *file, rtx addr)
 
       /* Print SImode registers for zero-extended addresses to force
 	 addr32 prefix.  Otherwise print DImode registers to avoid it.  */
-      if (TARGET_64BIT)
+      if (TARGET_64BIT && GET_MODE (addr) == DImode)
 	code = ((GET_CODE (addr) == ZERO_EXTEND
 		 || GET_CODE (addr) == AND)
 		? 'l'
-- 
1.7.6.5


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