From f0ccbc87f2e21c522b82d4c1df8398b31d4bf331 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?K=C3=A1roly=20Balogh?= Date: Sun, 28 Jun 2015 23:04:51 +0000 Subject: [PATCH] AROS/x86_64: enable syscalls code in the parser, fix EAX->RAX reference base while calculating syscall offset git-svn-id: trunk@31172 - --- compiler/parser.pas | 12 +++++------- compiler/x86_64/nx64cal.pas | 2 +- 2 files changed, 6 insertions(+), 8 deletions(-) diff --git a/compiler/parser.pas b/compiler/parser.pas index ffad2f1291..6da19217c7 100644 --- a/compiler/parser.pas +++ b/compiler/parser.pas @@ -116,13 +116,11 @@ implementation { target specific stuff } case target_info.system of - system_powerpc_amiga: - include(supported_calling_conventions,pocall_syscall); - system_powerpc_morphos: - include(supported_calling_conventions,pocall_syscall); - system_m68k_amiga: - include(supported_calling_conventions,pocall_syscall); - system_i386_aros: + system_powerpc_amiga, + system_powerpc_morphos, + system_m68k_amiga, + system_i386_aros, + system_x86_64_aros: include(supported_calling_conventions,pocall_syscall); {$ifdef i8086} system_i8086_msdos: diff --git a/compiler/x86_64/nx64cal.pas b/compiler/x86_64/nx64cal.pas index c5cd1eb998..edd0d6ab02 100644 --- a/compiler/x86_64/nx64cal.pas +++ b/compiler/x86_64/nx64cal.pas @@ -73,7 +73,7 @@ implementation tmpref.symbol:=current_asmdata.RefAsmSymbol(tstaticvarsym(tcpuprocdef(procdefinition).libsym).mangledname); cg.getcpuregister(current_asmdata.CurrAsmList,NR_RAX); cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_ADDR,OS_ADDR,tmpref,NR_RAX); - reference_reset_base(tmpref,NR_EAX,-tprocdef(procdefinition).extnumber,sizeof(pint)); + reference_reset_base(tmpref,NR_RAX,-tprocdef(procdefinition).extnumber,sizeof(pint)); cg.a_load_ref_reg(current_asmdata.CurrAsmList,OS_ADDR,OS_ADDR,tmpref,NR_RAX); cg.a_call_reg(current_asmdata.CurrAsmList,NR_RAX); cg.ungetcpuregister(current_asmdata.CurrAsmList,NR_RAX);