Don't add live ranges for aliases of physregs that are live in to the
authorLang Hames <lhames@gmail.com>
Wed, 25 Jan 2012 22:11:06 +0000 (22:11 +0000)
committerLang Hames <lhames@gmail.com>
Wed, 25 Jan 2012 22:11:06 +0000 (22:11 +0000)
function. They don't appear to be used, and are inconsistent with handling of
other physreg intervals (i.e. intervals that are not live-in) where ranges are
not inserted for aliases.

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

lib/CodeGen/LiveIntervalAnalysis.cpp

index 0e621ebc68cfb6a9c1e0701ad5f46284fc95ab38..b8e60bd1ec3264596c454c3dcf7d9d36b65417a9 100644 (file)
@@ -582,11 +582,6 @@ void LiveIntervals::computeIntervals() {
     for (MachineBasicBlock::livein_iterator LI = MBB->livein_begin(),
            LE = MBB->livein_end(); LI != LE; ++LI) {
       handleLiveInRegister(MBB, MIIndex, getOrCreateInterval(*LI));
-      // Multiple live-ins can alias the same register.
-      for (const unsigned* AS = tri_->getSubRegisters(*LI); *AS; ++AS)
-        if (!hasInterval(*AS))
-          handleLiveInRegister(MBB, MIIndex, getOrCreateInterval(*AS),
-                               true);
     }
 
     // Skip over empty initial indices.