浏览代码

* x86_64-linux uses now pascal init code

git-svn-id: trunk@38409 -
florian 7 年之前
父节点
当前提交
b24eb3cce7
共有 3 个文件被更改,包括 2 次插入4 次删除
  1. 1 1
      compiler/systems.pas
  2. 1 2
      rtl/linux/x86_64/si_c.inc
  3. 0 1
      rtl/linux/x86_64/si_g.inc

+ 1 - 1
compiler/systems.pas

@@ -336,7 +336,7 @@ interface
        systems_weak_linking = systems_darwin + systems_solaris + systems_linux + systems_android;
 
        systems_internal_sysinit = [system_i386_win32,system_x86_64_win64,
-                                   system_i386_linux,system_powerpc64_linux,system_sparc64_linux,
+                                   system_i386_linux,system_powerpc64_linux,system_sparc64_linux,system_x86_64_linux,
                                    system_m68k_atari,system_m68k_palmos
                                   ]+systems_darwin+systems_amigalike;
 

+ 1 - 2
rtl/linux/x86_64/si_c.inc

@@ -71,7 +71,7 @@ procedure main_stub; assembler; nostackframe;
 
     { store stack length }
     movq StackLength@GOTPCREL(%rip),%rax
-    movq %rax,TEntryInformation.OS.stklen(%rcx)
+    movq %rax,TEntryInformation.OS.stklen(%rdi)
 
     { store pointer to haltproc }
     movq    _FPC_libc_haltproc@GOTPCREL(%rip),%rax
@@ -131,7 +131,6 @@ procedure _FPC_libc_start; assembler; nostackframe; public name '_start';
     { argc is longint in EntryInformation, thus use %edi register }
     movl %esi,TEntryInformation.OS.argc(%rcx)
     movq %rsp,TEntryInformation.OS.argv(%rcx)
-    movq %rsp,(%rax)
     leaq 8(,%rsi,8),%rax
     addq %rsp,%rax
     movq %rax,TEntryInformation.OS.envp(%rcx)

+ 0 - 1
rtl/linux/x86_64/si_g.inc

@@ -145,7 +145,6 @@ procedure ini_dummy;
     { argc is longint in EntryInformation, thus use %edi register }
     movl %esi,TEntryInformation.OS.argc(%rcx)
     movq %rsp,TEntryInformation.OS.argv(%rcx)
-    movq %rsp,(%rax)
     leaq 8(,%rsi,8),%rax
     addq %rsp,%rax
     movq %rax,TEntryInformation.OS.envp(%rcx)