diff --git a/lang/src/son/hbvm/regalloc.rs b/lang/src/son/hbvm/regalloc.rs index c5fcebc..20828d7 100644 --- a/lang/src/son/hbvm/regalloc.rs +++ b/lang/src/son/hbvm/regalloc.rs @@ -301,10 +301,10 @@ impl HbvmBackend { let bundle_count = self.ralloc.bundles.len() + (reg_offset as usize); ( if tail { - bundle_count.saturating_sub(reg::RET_ADDR as _) - } else { assert!(bundle_count < reg::STACK_PTR as usize, "TODO: spill memory"); self.ralloc.bundles.len() + } else { + bundle_count.saturating_sub(reg::RET_ADDR as _) }, tail, )