aboutsummaryrefslogtreecommitdiffstats
path: root/x86/CBuiltins.ml
diff options
context:
space:
mode:
authorXavier Leroy <xavier.leroy@college-de-france.fr>2020-10-05 15:52:58 +0200
committerXavier Leroy <xavier.leroy@college-de-france.fr>2020-10-05 15:52:58 +0200
commit26ddb90280b45e92d90eead89edb237f2922824a (patch)
treeff18b31abdbb97133f9708ca085467f25758e507 /x86/CBuiltins.ml
parente9c738e3bd156f68905968e25c70ec796d3119c4 (diff)
downloadcompcert-kvx-26ddb90280b45e92d90eead89edb237f2922824a.tar.gz
compcert-kvx-26ddb90280b45e92d90eead89edb237f2922824a.zip
Support Cygwin 64 bits
- Add support for the Win64 ABI to the x86_64 port - Update vararg support to handle Win64 conventions - Configure support for x86_64-cygwin64
Diffstat (limited to 'x86/CBuiltins.ml')
-rw-r--r--x86/CBuiltins.ml8
1 files changed, 6 insertions, 2 deletions
diff --git a/x86/CBuiltins.ml b/x86/CBuiltins.ml
index 6820c089..a16f3ef7 100644
--- a/x86/CBuiltins.ml
+++ b/x86/CBuiltins.ml
@@ -19,8 +19,12 @@ open C
let (va_list_type, va_list_scalar, size_va_list) =
if Archi.ptr64 then
- (* Actually a struct passed by reference; equivalent to 3 64-bit words *)
- (TArray(TInt(IULong, []), Some 3L, []), false, 3*8)
+ if Archi.win64 then
+ (* Just a pointer *)
+ (TPtr(TVoid [], []), true, 8)
+ else
+ (* Actually a struct passed by reference; equivalent to 3 64-bit words *)
+ (TArray(TInt(IULong, []), Some 3L, []), false, 3*8)
else
(* Just a pointer *)
(TPtr(TVoid [], []), true, 4)