Don't call destructors on MachineInstr and MachineOperand.
authorJakob Stoklund Olesen <stoklund@2pi.dk>
Sat, 5 Jan 2013 05:05:51 +0000 (05:05 +0000)
committerJakob Stoklund Olesen <stoklund@2pi.dk>
Sat, 5 Jan 2013 05:05:51 +0000 (05:05 +0000)
The series of patches leading up to this one makes llc -O0 run 8% faster.

When deallocating a MachineFunction, there is no need to visit all
MachineInstr and MachineOperand objects to deallocate them. All their
memory come from a BumpPtrAllocator that is about to be purged, and they
have empty destructors anyway.

This only applies when deallocating the MachineFunction.
DeleteMachineInstr() should still be used to recycle MI memory during
the codegen passes.

Remove the LeakDetector support for MachineInstr. I've never seen it
used before, and now it definitely doesn't work. With this patch, leaked
MachineInstrs would be much less of a problem since all of their memory
will be reclaimed by ~MachineFunction().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171599 91177308-0d34-0410-b5e6-96231b3b80d8


No differences found