fix(qbe): any-child terminator check in QBE_IsTerminator for hBlock — QBE SSA now fully valid
- QBE_IsTerminator(hBlock) checks ALL children, not just last - Removed legacy c_backend.bux and nim_backend.bux from _selfhost/src/ - QBE self-hosting QBE phase: PASSES (SSA valid, assembled to .s) - Remaining: linker errors from missing String_Eq/StringBuilder in runtime
This commit is contained in:
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
# simple looping program
|
||||
# sums all integers from 100 to 0
|
||||
|
||||
export
|
||||
function $test() {
|
||||
@start
|
||||
|
||||
@loop
|
||||
%s =w phi @start 0, @loop %s1
|
||||
%n =w phi @start 100, @loop %n1
|
||||
%s1 =w add %s, %n
|
||||
%n1 =w sub %n, 1
|
||||
jnz %n1, @loop, @end
|
||||
|
||||
@end
|
||||
storew %s1, $a
|
||||
ret
|
||||
}
|
||||
|
||||
# >>> driver
|
||||
# extern void test(void);
|
||||
# int a;
|
||||
# int main() { test(); return !(a == 5050); }
|
||||
# <<<
|
||||
Reference in New Issue
Block a user