diff options
author | Chris Lattner <sabre@nondot.org> | 2007-04-17 04:04:14 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2007-04-17 04:04:14 +0000 |
commit | f8dfef74376dd85f37601855f7519d8256700dab (patch) | |
tree | 426e7bcdcbcd9beb1c684ced7f62ba3c3b1cbf2b /lib/VMCore/BasicBlock.cpp | |
parent | 17fcdd5e1b78b829068ca657c97357a39d6e768b (diff) |
The (negative) offset from a SymbolTableListTraits-using ilist to its container
object is always constant. As such, evaluate it at compile time instead of storing
it as an ivar in SymbolTableListTraits. This shrinks every SymbolTableListTraits
ilist by a word, shrinking BasicBlock from 44->40 bytes, Function from 96->88 bytes,
and Module from 60->52 bytes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36189 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/VMCore/BasicBlock.cpp')
-rw-r--r-- | lib/VMCore/BasicBlock.cpp | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/lib/VMCore/BasicBlock.cpp b/lib/VMCore/BasicBlock.cpp index e10948e2ad..431bb5090a 100644 --- a/lib/VMCore/BasicBlock.cpp +++ b/lib/VMCore/BasicBlock.cpp @@ -72,8 +72,6 @@ template class SymbolTableListTraits<Instruction, BasicBlock>; BasicBlock::BasicBlock(const std::string &Name, Function *NewParent, BasicBlock *InsertBefore) : Value(Type::LabelTy, Value::BasicBlockVal), Parent(0) { - // Initialize the instlist. - InstList.setItemParent(this); // Make sure that we get added to a function LeakDetector::addGarbageObject(this); |