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]

RE: Handle Solaris 8/9 x86 as rep syntax


Is it really so bad so just always output the ";"?
?(if dialect == att)

Just that line won't get gas'es checking for rep without string, right?

Not the entire file?

And gcc doesn't really need the checking here, right?
Only hand coded asm would.
? (If the checking was disabled for entire file, I realize, gcc's "disabling" the check
?? would affect hand coded asm.)

Better to reduce the branching introduced by autoconfigure than to add to it?
? If I'm cross building a native compiler I have to manually tell autoconfigure what to do
? with an environment variable.

Just use a syntax that always works?

The direction is to change #if to if, also, right?
?(So that eventually compile-time options become run-time options?)
I'm using "if (ASSEMBLER_DIALECT == ASM_ATT)".

?- Jay

----------------------------------------------------------------------


--Forwarded Message Attachment--
From: ro
To: ubizjak
CC: gcc-patches; bonzini
Subject: Re: Handle Solaris 8/9 x86 as rep syntax
Date: Mon, 17 May 2010 19:59:26 +0200


Uros Bizjak  writes:

>> %; support is available all right: support is in i386.c (print_operand),
>> but I hadn't only looked in i386.md for actual uses.  In fact, the
>> current use in sync.md is too complicated: lock{%;| } can be replaced by
>> just lock%; since %; already emits the whitespace.
>
> Please, change this globally to i.e.:
>
> "lock{%;} add{}\t{%1, %0|%0, %1}"
>
> and conditinaly emit only ";" from print_operand ().

2010-05-08  Rainer Orth  

        PR target/44074
        * configure.ac (HAVE_AS_IX86_REP_LOCK_PREFIX): New test.
        
--- a/gcc/config/i386/i386.c    Wed May 12 23:00:23 2010 +0200
+++ b/gcc/config/i386/i386.c    Wed May 12 23:30:10 2010 +0200
@@ -11951,10 +11951,8 @@
          return;

        case ';':
-#if TARGET_MACHO
-         fputs (" ; ", file);
-#else
-         putc (' ', file);
+#if TARGET_MACHO || !HAVE_AS_IX86_REP_LOCK_PREFIX
+         fputs (";", file);
 #endif
          return;

 		 	   		  


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