Skip to content

Commit 3a32201

Browse files
committed
Cleanup stale TODO comments
Phi instructions in SSA unit is previously allocated via builtin malloc, and wasn't freeing after SSA unit completed. Later, we replaced allocator with arena allocator, which guaranteed its lifetime is within the compilation, thus the TODO comment is removed as resolved. Close #275.
1 parent e95fccc commit 3a32201

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/ssa.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -903,8 +903,6 @@ void bb_unwind_phi(func_t *func, basic_block_t *bb)
903903
for (phi_operand_t *operand = insn->phi_ops; operand;
904904
operand = operand->next)
905905
append_unwound_phi_insn(operand->from, insn->rd, operand->var);
906-
/* TODO: Release memory allocated for phi instruction to prevent leaks
907-
*/
908906
}
909907

910908
bb->insn_list.head = insn;

0 commit comments

Comments
 (0)