authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-08-26 20:54:12-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2026-08-27 04:44:37-07:00
log521cc292e6ff43cffc0f54d9b1a5243ba0a766e6
treedb59e0c1e5141d80795f91eb63f0e72a7298bcb1
parentcc8f27d2db253cf75b7a62228f998b02b8a3c527

std.Target: update spork8 C ABI information

in accordance with the specification

1 files changed, 10 insertions(+), 0 deletions(-)

lib/std/Target.zig+10
...@@ -3108,6 +3108,8 @@ pub fn stackAlignment(target: *const Target) u16 {...@@ -3108,6 +3108,8 @@ pub fn stackAlignment(target: *const Target) u16 {
31083108
3109 .kvx => return 32,3109 .kvx => return 32,
31103110
3111 .spork8 => return 256,
3112
3111 else => {},3113 else => {},
3112 }3114 }
31133115
...@@ -3127,6 +3129,7 @@ pub fn stackGrowth(target: *const Target) StackGrowth {...@@ -3127,6 +3129,7 @@ pub fn stackGrowth(target: *const Target) StackGrowth {
3127 return switch (target.cpu.arch) {3129 return switch (target.cpu.arch) {
3128 .hppa,3130 .hppa,
3129 .hppa64,3131 .hppa64,
3132 .spork8,
3130 => .up,3133 => .up,
3131 else => .down,3134 else => .down,
3132 };3135 };
...@@ -3233,6 +3236,13 @@ pub fn cTypeBitSize(target: *const Target, c_type: CType) ?u16 {...@@ -3233,6 +3236,13 @@ pub fn cTypeBitSize(target: *const Target, c_type: CType) ?u16 {
3233 .long, .ulong, .float, .double, .longdouble => 32,3236 .long, .ulong, .float, .double, .longdouble => 32,
3234 .longlong, .ulonglong => 64,3237 .longlong, .ulonglong => 64,
3235 },3238 },
3239 // https://github.com/benanderman/spork-8/blob/main/Programming.md
3240 .spork8 => switch (c_type) {
3241 .char => 8,
3242 .short, .ushort, .int, .uint => 16,
3243 .long, .ulong, .float => 32,
3244 .double, .longdouble, .longlong, .ulonglong => 64,
3245 },
3236 .mips64,3246 .mips64,
3237 .mips64el,3247 .mips64el,
3238 => switch (c_type) {3248 => switch (c_type) {