winch(x64): Improve ABI support in trampolines (#6204)
This commit improves ABI support in Winch's trampolines mainly by: * Adding support for the `fastcall` calling convention. * By storing/restoring callee-saved registers. One of the explicit goals of this change is to make tests available in the x86_64 target as a whole and remove the need exclude the windows target. This commit also introduces a `CallingConvention` enum, to better reflect the subset of calling conventions that are supported by Winch.
This commit is contained in:
@@ -3,7 +3,7 @@ use crate::{
|
||||
abi::ABI,
|
||||
codegen::{CodeGen, CodeGenContext},
|
||||
frame::{DefinedLocals, Frame},
|
||||
isa::{Builder, TargetIsa},
|
||||
isa::{Builder, CallingConvention, TargetIsa},
|
||||
masm::MacroAssembler,
|
||||
regalloc::RegAlloc,
|
||||
regset::RegSet,
|
||||
@@ -92,7 +92,7 @@ impl TargetIsa for Aarch64 {
|
||||
let mut masm = Aarch64Masm::new(self.shared_flags.clone());
|
||||
let stack = Stack::new();
|
||||
let abi = abi::Aarch64ABI::default();
|
||||
let abi_sig = abi.sig(sig);
|
||||
let abi_sig = abi.sig(sig, &CallingConvention::Default);
|
||||
|
||||
let defined_locals = DefinedLocals::new(&mut body, validator)?;
|
||||
let frame = Frame::new(&abi_sig, &defined_locals, &abi)?;
|
||||
|
||||
Reference in New Issue
Block a user