Hojun-Cho
c83a3403a4
cgen: store all eightbytes when an in-cap aggregate call returns into an array element (#31-G)
...
`arr[i] = mk()` where mk returns an in-cap (<=24B) struct/tuple/array
left the result in the #4 cgreturn registers (AX/DX/CX), but the
N_ASSIGN-into-N_INDEX path had no arm for an N_CALL rhs, so it fell to
the scalar store tail: only member 0 was written and the index scale
clobbered CX. Both stages emitted byte-identical wrong code (the
documented-but-silent #31-G gap), so the byte-id gate was blind to it.
Add an in-cap N_CALL-rhs arm: materialise the return into a frame scratch
first (keeping the CALL at the frame's natural 16B alignment), resolve
&arr[i], then word-copy the full eightbyte count + sub-8 tail -- mirroring
the #4 receive shape and the #270-1b copy. The eightbyte count derives
from the element size in the type table. Over-cap returns (#234 ),
non-call rhs (#270-1b) and tuple literals (#121 ) are unaffected; the
sibling field/deref shapes stay loud (#24 ).
Surfaced by the codegen miscompile hunt (finding C2c). Pinned by
test/lang/idx_aggret_recv_test.ww (10 value-asserting rows: 2/3-eightbyte
structs+tuples, array elem, sub-8 tail, const/runtime index, all four
base shapes; reddens on revert).
2026-06-27 13:28:37 +09:00
..
2026-06-22 13:52:41 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-22 13:34:28 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-22 17:10:22 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 02:45:09 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 03:25:47 +09:00
2026-06-25 01:32:32 +09:00
2026-06-25 01:32:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-22 02:53:16 +09:00
2026-06-22 13:52:41 +09:00
2026-06-22 02:04:56 +09:00
2026-06-22 11:52:41 +09:00
2026-06-25 01:32:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-22 13:34:28 +09:00
2026-06-25 01:32:32 +09:00
2026-06-22 12:04:03 +09:00
2026-06-22 12:04:03 +09:00
2026-06-22 12:04:03 +09:00
2026-06-27 11:47:54 +09:00
2026-06-22 13:34:28 +09:00
2026-06-22 09:02:40 +09:00
2026-06-22 18:06:05 +09:00
2026-06-22 18:06:05 +09:00
2026-06-22 13:34:28 +09:00
2026-06-22 12:31:23 +09:00
2026-06-22 16:34:33 +09:00
2026-06-22 09:02:40 +09:00
2026-06-24 03:25:47 +09:00
2026-06-27 12:34:58 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 22:59:32 +09:00
2026-06-22 14:56:11 +09:00
2026-06-22 11:52:41 +09:00
2026-06-22 11:52:41 +09:00
2026-06-22 12:31:23 +09:00
2026-06-22 11:52:41 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-22 02:04:56 +09:00
2026-06-27 13:28:37 +09:00
2026-06-22 16:02:01 +09:00
2026-06-24 20:42:08 +09:00
2026-06-22 02:04:56 +09:00
2026-06-22 16:34:33 +09:00
2026-06-25 01:32:32 +09:00
2026-06-24 20:42:08 +09:00
2026-06-22 11:52:41 +09:00
2026-06-22 16:53:49 +09:00
2026-06-22 18:30:04 +09:00
2026-06-22 11:52:41 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 20:42:08 +09:00
2026-06-25 01:32:32 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 22:59:32 +09:00
2026-06-24 22:59:32 +09:00
2026-06-22 13:52:41 +09:00
2026-06-24 01:00:47 +09:00
2026-06-24 01:00:47 +09:00
2026-06-24 01:44:13 +09:00
2026-06-22 13:34:28 +09:00
2026-06-24 01:44:13 +09:00
2026-06-22 02:53:16 +09:00
2026-06-25 01:32:32 +09:00
2026-06-22 03:01:09 +09:00
2026-06-22 11:52:41 +09:00
2026-06-26 23:16:19 +09:00
2026-06-22 09:02:40 +09:00
2026-06-22 13:52:41 +09:00
2026-06-22 13:52:41 +09:00
2026-06-22 09:02:40 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:01:09 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:54:54 +09:00
2026-06-22 03:54:54 +09:00
2026-06-25 01:32:32 +09:00
2026-06-22 18:28:41 +09:00
2026-06-25 01:32:32 +09:00
2026-06-22 12:11:46 +09:00
2026-06-25 01:32:32 +09:00
2026-06-22 09:02:40 +09:00
2026-06-22 09:02:40 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 01:44:13 +09:00
2026-06-22 11:52:41 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 01:44:13 +09:00
2026-06-22 11:52:41 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 01:44:13 +09:00
2026-06-22 13:52:41 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 03:25:47 +09:00
2026-06-24 01:44:13 +09:00
2026-06-24 22:59:32 +09:00
2026-06-22 01:48:38 +09:00
2026-06-25 01:32:32 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-24 20:42:08 +09:00
2026-06-22 02:53:16 +09:00