Skip to content

Commit

Permalink
remove some useless codes
Browse files Browse the repository at this point in the history
  • Loading branch information
WindowsXp-Beta committed Dec 29, 2021
1 parent d26f57b commit 53eb0c0
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 13 deletions.
5 changes: 0 additions & 5 deletions src/tiger/frame/frame.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,11 +70,6 @@ class RegManager {
[[nodiscard]] virtual temp::Temp *ReturnValue() = 0;

temp::Map *temp_map_;
std::deque<std::string> colors = {
"%rax", "%rbx", "%rcx", "%rdx", "%rsi",
"%rdi", "%rbp", "%r8", "%r9", "%r10",
"%r11", "%r12", "%r13", "%r14", "%r15"
};

protected:
std::vector<temp::Temp *> regs_;
Expand Down
8 changes: 0 additions & 8 deletions src/tiger/frame/temp.h
Original file line number Diff line number Diff line change
Expand Up @@ -74,14 +74,6 @@ class TempList {
return false;
}

void Replace(Temp *old_, Temp *new_) {
for (auto itr = temp_list_.begin(); itr != temp_list_.end(); itr++){
if ((*itr) == old_){
(*itr) = new_;
}
}
}

[[nodiscard]] Temp *NthTemp(int i) const;
[[nodiscard]] const std::list<Temp *> &GetList() const { return temp_list_; }

Expand Down

0 comments on commit 53eb0c0

Please sign in to comment.