[fpc-devel] threadvar implementation
Michael Schnell
mschnell at lumino.de
Thu Aug 5 12:01:54 CEST 2010
On 08/05/2010 11:09 AM, Hans-Peter Diettrich wrote:
>
> I had thought that this has been fixed on newer architectures, that
> use the flat model only.
This can't easily be "fixed" by hardware, how to express that LEA should
convert e.g. a DS-based offset into a FS based one or the other way
round, or even a GS based address into an FS based one ?
All other instructions work with at most a single "Logical Address" so a
single prefix instruction (or set of flags denoting DS:, SS:, CS:, FS:
or GS: ) is enough to denote how the 32 bit Offset is to be extended to
the 48 Bit Linear Address.
LEA - if working on Logical addresses - in fact would need two sets of
segment prefix flags. These are not provided by the basic paradigm of
the instruction set and thus LEA works on 32 Offsets rather than on 48
Bit Linear Addresses.
-Michael
More information about the fpc-devel
mailing list