* Another fix to PIC assembler: GOT slot stores the address of variable, not variable itself.

git-svn-id: trunk@24127 -
This commit is contained in:
sergei 2013-04-02 10:48:58 +00:00
parent 539e977273
commit 37a347ce7b

View File

@ -295,7 +295,8 @@ begin
movl %eax,p3-.Lpic(%ecx)
{$else darwin}
addl $_GLOBAL_OFFSET_TABLE_+1,%ecx
movl %eax,p3@GOT(%ecx)
movl p3@GOT(%ecx),%edx
movl %eax,(%edx)
{$endif darwin}
{$endif FPC_PIC}
{$endif cpui386}
@ -350,7 +351,8 @@ begin
movl %eax,p3-.Lpic(%ecx)
{$else darwin}
addl $_GLOBAL_OFFSET_TABLE_+1,%ecx
movl %eax,p3@GOT(%ecx)
movl p3@GOT(%ecx),%edx
movl %eax,(%edx)
{$endif darwin}
{$endif FPC_PIC}
{$endif}