Allow specification of the system V AMD64 ABI constraint.
This can be specified using `extern sysV64 fn` on all platforms
This commit is contained in:
parent
71ee82a8aa
commit
516519ee9a
4 changed files with 5 additions and 0 deletions
|
@ -539,6 +539,7 @@ This is currently hidden behind the `abi_vectorcall` gate and is subject to chan
|
||||||
* `system`
|
* `system`
|
||||||
* `C`
|
* `C`
|
||||||
* `win64`
|
* `win64`
|
||||||
|
* `sysV64`
|
||||||
|
|
||||||
Most of the abis in this list are self-explanatory, but the `system` abi may
|
Most of the abis in this list are self-explanatory, but the `system` abi may
|
||||||
seem a little odd. This constraint selects whatever the appropriate ABI is for
|
seem a little odd. This constraint selects whatever the appropriate ABI is for
|
||||||
|
|
|
@ -42,6 +42,7 @@ pub enum CallConv {
|
||||||
ColdCallConv = 9,
|
ColdCallConv = 9,
|
||||||
X86StdcallCallConv = 64,
|
X86StdcallCallConv = 64,
|
||||||
X86FastcallCallConv = 65,
|
X86FastcallCallConv = 65,
|
||||||
|
X86_64_SysV = 78,
|
||||||
X86_64_Win64 = 79,
|
X86_64_Win64 = 79,
|
||||||
X86_VectorCall = 80
|
X86_VectorCall = 80
|
||||||
}
|
}
|
||||||
|
|
|
@ -269,6 +269,7 @@ impl FnType {
|
||||||
Vectorcall => llvm::X86_VectorCall,
|
Vectorcall => llvm::X86_VectorCall,
|
||||||
C => llvm::CCallConv,
|
C => llvm::CCallConv,
|
||||||
Win64 => llvm::X86_64_Win64,
|
Win64 => llvm::X86_64_Win64,
|
||||||
|
SysV64 => llvm::X86_64_SysV,
|
||||||
|
|
||||||
// These API constants ought to be more specific...
|
// These API constants ought to be more specific...
|
||||||
Cdecl => llvm::CCallConv,
|
Cdecl => llvm::CCallConv,
|
||||||
|
|
|
@ -39,6 +39,7 @@ pub enum Abi {
|
||||||
Vectorcall,
|
Vectorcall,
|
||||||
Aapcs,
|
Aapcs,
|
||||||
Win64,
|
Win64,
|
||||||
|
SysV64,
|
||||||
|
|
||||||
// Multiplatform ABIs second
|
// Multiplatform ABIs second
|
||||||
Rust,
|
Rust,
|
||||||
|
@ -86,6 +87,7 @@ const AbiDatas: &'static [AbiData] = &[
|
||||||
AbiData {abi: Abi::Vectorcall, name: "vectorcall"},
|
AbiData {abi: Abi::Vectorcall, name: "vectorcall"},
|
||||||
AbiData {abi: Abi::Aapcs, name: "aapcs" },
|
AbiData {abi: Abi::Aapcs, name: "aapcs" },
|
||||||
AbiData {abi: Abi::Win64, name: "win64" },
|
AbiData {abi: Abi::Win64, name: "win64" },
|
||||||
|
AbiData {abi: Abi::SysV64, name: "sysV64" },
|
||||||
|
|
||||||
// Cross-platform ABIs
|
// Cross-platform ABIs
|
||||||
//
|
//
|
||||||
|
|
Loading…
Add table
Reference in a new issue