aboutsummaryrefslogtreecommitdiffhomepage
path: root/amd64/sysv.c
diff options
context:
space:
mode:
authorlemon <lsof@mailbox.org>2025-11-22 13:25:07 +0100
committerlemon <lsof@mailbox.org>2025-11-22 13:25:07 +0100
commit6256bc1d0485a74e7d6728c95603a54a4149cb64 (patch)
treedc1bc3676acc6e844a577d571416e2bdba145cae /amd64/sysv.c
parent1e3bac30ff78db862fc5102ae4c2c90db021f6bb (diff)
sysv: nested scalar classification of struct shouldn't return KPTR, used to indicate aggregate in the stack
Diffstat (limited to 'amd64/sysv.c')
-rw-r--r--amd64/sysv.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/amd64/sysv.c b/amd64/sysv.c
index 7410499..9d97b86 100644
--- a/amd64/sysv.c
+++ b/amd64/sysv.c
@@ -13,7 +13,7 @@ clsscalar(uchar cls[2], uint off, union type ty)
} else { /* INTEGER */
assert(isint(ty) || ty.t == TYPTR);
if (cls2siz[*fcls] < cls2siz[k])
- *fcls = k;
+ *fcls = k == KPTR ? KI64 : k;
}
if (off % 8 >= 4 && cls2siz[*fcls] < 8)
*fcls = kisint(*fcls) ? KI64 : KF64;