[backend]修复了一个栈管理问题

This commit is contained in:
Lixuanwang
2025-07-30 20:40:56 +08:00
parent 8e94f89931
commit 03b62b138f
4 changed files with 66 additions and 90 deletions

View File

@@ -279,7 +279,8 @@ struct StackFrameInfo {
std::map<unsigned, int> alloca_offsets; // <AllocaInst的vreg, 栈偏移>
std::map<unsigned, int> spill_offsets; // <溢出vreg, 栈偏移>
std::set<PhysicalReg> used_callee_saved_regs; // 使用的保存寄存器
std::map<unsigned, PhysicalReg> vreg_to_preg_map;
std::map<unsigned, PhysicalReg> vreg_to_preg_map;
std::vector<PhysicalReg> callee_saved_regs; // 用于存储需要保存的被调用者保存寄存器列表
};
// 机器函数