w6a: drop chained-ptr-write workaround (c5f30f2 unblocked it)
This commit is contained in:
@@ -354,13 +354,7 @@ fn addprog(a: *asm_, opc: i32, lbl: str) *aprog = {
|
||||
pr.from = amalloc(a.a, 48u64): *aoperand;
|
||||
pr.to = amalloc(a.a, 48u64): *aoperand;
|
||||
if (a.head == nil) { a.head = pr; }
|
||||
else {
|
||||
// `a.tail.link = pr` would be a chained-dot write through a
|
||||
// pointer field, which the C cgen we bootstrap on doesn't
|
||||
// support (silently drops the store). Bind a local first.
|
||||
let tail: *aprog = a.tail;
|
||||
tail.link = pr;
|
||||
};
|
||||
else { a.tail.link = pr; };
|
||||
a.tail = pr;
|
||||
return pr;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user