diff options
author | Alkis Evlogimenos <alkis@evlogimenos.com> | 2004-05-29 19:03:29 +0000 |
---|---|---|
committer | Alkis Evlogimenos <alkis@evlogimenos.com> | 2004-05-29 19:03:29 +0000 |
commit | f174cc303ba0f37ceaed75c3ea751ebd0fb3a4cd (patch) | |
tree | 48233150efc79161749e7d4a8125a046dca15142 /lib/CodeGen/VirtRegMap.h | |
parent | f717a0569886be297903078bcd779e84254d0010 (diff) | |
download | external_llvm-f174cc303ba0f37ceaed75c3ea751ebd0fb3a4cd.zip external_llvm-f174cc303ba0f37ceaed75c3ea751ebd0fb3a4cd.tar.gz external_llvm-f174cc303ba0f37ceaed75c3ea751ebd0fb3a4cd.tar.bz2 |
Add grow() member that grows the maps when the number of virtual
registers in the function has changed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13893 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/VirtRegMap.h')
-rw-r--r-- | lib/CodeGen/VirtRegMap.h | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/CodeGen/VirtRegMap.h b/lib/CodeGen/VirtRegMap.h index 3c2f8ee..c4188bc 100644 --- a/lib/CodeGen/VirtRegMap.h +++ b/lib/CodeGen/VirtRegMap.h @@ -54,8 +54,12 @@ namespace llvm { : mf_(&mf), v2pMap_(NO_PHYS_REG), v2ssMap_(NO_STACK_SLOT) { - v2pMap_.grow(mf.getSSARegMap()->getLastVirtReg()); - v2ssMap_.grow(mf.getSSARegMap()->getLastVirtReg()); + grow(); + } + + void grow() { + v2pMap_.grow(mf_->getSSARegMap()->getLastVirtReg()); + v2ssMap_.grow(mf_->getSSARegMap()->getLastVirtReg()); } bool hasPhys(unsigned virtReg) const { |