[llvm-commits] [llvm] r145970 - /llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp

Jakob Stoklund Olesen stoklund at 2pi.dk
Tue Dec 6 13:55:35 PST 2011


Author: stoklund
Date: Tue Dec  6 15:55:35 2011
New Revision: 145970

URL: http://llvm.org/viewvc/llvm-project?rev=145970&view=rev
Log:
Remove alignment from deserted constant islands.

ARMConstantIslandPass may sometimes leave empty constant islands behind
(it really shouldn't). Remove the alignment from the empty islands so
the size calculations are still correct.

This should fix the many Thumb1 assembler errors in the nightly test
suite.

The reduced test case for this problem is way too big. That is to be
expected for ARMConstantIslandPass bugs.

<rdar://problem/10534709>

Modified:
    llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp

Modified: llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp?rev=145970&r1=145969&r2=145970&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMConstantIslandPass.cpp Tue Dec  6 15:55:35 2011
@@ -1355,6 +1355,9 @@
       Size += BBSizes[CPEBB->getNumber()];
       BBSizes[CPEBB->getNumber()] = 0;
     }
+
+    // This block no longer needs to be aligned. <rdar://problem/10534709>.
+    CPEBB->setAlignment(0);
   }
   AdjustBBOffsetsAfter(CPEBB, -Size);
   // An island has only one predecessor BB and one successor BB. Check if





More information about the llvm-commits mailing list