This is the mail archive of the binutils@sourceware.org mailing list for the binutils 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: RFC: designated initializer vs. long long for i386 assembler


On Tue, Mar 13, 2007 at 08:21:49AM +0000, Jan Beulich wrote:
> >>> "H. J. Lu" <hjl@lucon.org> 12.03.07 20:05 >>>
> >On Tue, Feb 13, 2007 at 06:01:38PM -0800, H. J. Lu wrote:
> >> On Wed, Feb 14, 2007 at 12:21:34PM +1030, Alan Modra wrote:
> >> > On Tue, Feb 13, 2007 at 04:14:12PM -0800, H. J. Lu wrote:
> >> > > I need much more than 2 bits, which won't fit in the current
> >> > > 32bit int.
> >> > 
> >> > Then I suggest adding another field.  I don't think we can force
> >> > people to use a C99 compiler to build binutils.
> >> 
> >> Adding another field will lead to massive changes to x86 assembler.
> >> I will use long long if C99 feature isn't desirable.
> >> 
> >> BTW, I compared long long vs int. There is not much slow down in
> >> assembler.
> >
> >We can use designated initializer in include/opcode/i386.h. We put a
> >generated copy of it, i386-inst.h, in gas/config, which doesn't
> >use designated initializer. tc-i386.c will include i386-inst.h
> >instead of opcode/i386.h. We will put a tool in gas to generate
> >gas/config/i386-inst.h from include/opcode/i386.h. We can require
> >that such a tool has to be compiled with a C99 compiler.
> 
> Why would the compilation of a tool needed for building be any
> different from the compilation of any final code? If a system doesn't
> have C99 support, then a tool wouldn't build as much as gas itself
> would. Am I missing something?

The generated file, i386-inst.h, should be checked into CVS. People
who change include/opcode/i386.h is responsible to regenerate
i386-inst.h with the tool compiled with a C99 compiler. They are
the only people who need a C99 compiler.


H.J.


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