mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-18 17:49:07 +02:00
* accelerated/fixed TLS access on win32 by Pierre Muller
git-svn-id: trunk@13571 -
This commit is contained in:
parent
d11764fe8c
commit
d3d3596cd6
@ -105,13 +105,20 @@ CONST
|
|||||||
dataindex : pointer;
|
dataindex : pointer;
|
||||||
errorsave : dword;
|
errorsave : dword;
|
||||||
begin
|
begin
|
||||||
{$ifdef dummy}
|
{$ifdef win32}
|
||||||
{ I've no clue why this doesn't read dataindex, imo it should (FK) }
|
|
||||||
asm
|
asm
|
||||||
movl TLSKey,%edx
|
movl TLSKey,%edx
|
||||||
movl $0x2c,%eax
|
movl $0x2c,%eax
|
||||||
movl %fs:(%eax),%eax
|
movl %fs:(%eax),%eax
|
||||||
|
orl %eax,%eax
|
||||||
|
jnz .LAddressInEAX
|
||||||
|
movl $0x18,%eax
|
||||||
|
movl %fs:(%eax),%eax
|
||||||
|
movl 0xe10(%eax,%edx,4),%eax
|
||||||
|
jmp .LToDataIndex
|
||||||
|
.LAddressInEAX:
|
||||||
movl (%eax,%edx,4),%eax
|
movl (%eax,%edx,4),%eax
|
||||||
|
.LToDataIndex:
|
||||||
movl %eax,dataindex
|
movl %eax,dataindex
|
||||||
end;
|
end;
|
||||||
if DataIndex=nil then
|
if DataIndex=nil then
|
||||||
|
Loading…
Reference in New Issue
Block a user