This is the mail archive of the gas2@sourceware.cygnus.com mailing list for the gas2 project.


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

Re: [masaki@eie.monolta.co.jp: GAS bug and etc]


> 
> > Your patch jusr reversed what I did. Could you please tell
> > me why I was wrong and you were right? I thought I checked
> > the Intel x86 manual when I fixed that bug.
> 
> I didn't try to validate the patch; it was more of an FYI, which is
> why I included the header info.  If it's wrong, or you need more info,
> the original sender is the one to talk with (cc'd in both mails).
> Sorry if my intention wasn't clear.

I just hate that, especially when people say my patch is wrong without
doing their homework first :-).

> 
> Original sender:
> > From: masaki@eie.monolta.co.jp (Kenji  Masaki)
> 
> Note that the "jcxz" opcode in the gas that djgpp's libc was built
> with doesn't work as expected - jecxz does.  This might have confused
> people into thinking that there was a bug, or maybe there really is
> one.  jcxz is the 16-bit version (or pretends to be).
> 

jcxz and jecxz are totally different. One checks cx, the other
checks ecx. You have to decide what you want to use.

> Since jcxz uses both a register (opsize?) and an address (addrsize?),
> there may be a need for both prefixes.

I think gas will add a right address prefix automatically when it sees
a large offset. Ken?


-- 
H.J. Lu
NYNEX Science and Technology, Inc.			hjl@nynexst.com