diff options
| author | 2025-12-20 09:25:49 +0100 | |
|---|---|---|
| committer | 2025-12-20 10:31:38 +0100 | |
| commit | 436547eac72675c86d35c6d97e83c798578d0712 (patch) | |
| tree | a17aa007d04aa1924fb260985ee70b9a3756cd21 | |
| parent | a50b09474d0e561637a5be22db12a10a8b3c9ca8 (diff) | |
emit: fix errata in flagslivep()
This little typo inhibited a small optimization. Oops
| -rw-r--r-- | x86_64/emit.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/x86_64/emit.c b/x86_64/emit.c index 77f421e..3fc93b0 100644 --- a/x86_64/emit.c +++ b/x86_64/emit.c @@ -817,7 +817,7 @@ flagslivep(struct block *blk, int curi) if (blk->jmp.t != Jb || !blk->jmp.arg[0].bits) return 0; assert(blk->jmp.arg[0].t == RTMP); - cmpi = blk->jmp.arg[1].i; + cmpi = blk->jmp.arg[0].i; for (int i = blk->ins.n - 1; i > curi; --i) { if (blk->ins.p[i] == cmpi) /* flags defined after given instruction, dead here */ |