Browse Source

+ safecall support for x86_64

git-svn-id: trunk@3425 -
florian 19 years ago
parent
commit
da02375f57
1 changed files with 3 additions and 1 deletions
  1. 3 1
      compiler/ncgcal.pas

+ 3 - 1
compiler/ncgcal.pas

@@ -1039,7 +1039,9 @@ implementation
 {$if defined(x86) or defined(arm)}
          if procdefinition.proccalloption=pocall_safecall then
            begin
-
+{$ifdef x86_64}
+             cg.a_load_reg_reg(current_asmdata.CurrAsmList,OS_ADDR,OS_ADDR,NR_RAX,NR_RCX);
+{$endif x86_64}
              cg.allocallcpuregisters(current_asmdata.CurrAsmList);
              cg.a_call_name(current_asmdata.CurrAsmList,'FPC_SAFECALLCHECK');
              cg.deallocallcpuregisters(current_asmdata.CurrAsmList);