[llvm-commits] [llvm] r106940 - /llvm/trunk/lib/Target/ARM/ARMISelLowering.cpp

Eli Friedman eli.friedman at gmail.com
Fri Jun 25 21:36:50 PDT 2010


Author: efriedma
Date: Fri Jun 25 23:36:50 2010
New Revision: 106940

URL: http://llvm.org/viewvc/llvm-project?rev=106940&view=rev
Log:
Followup to r106770: actually generate SXTB and SXTH for sign-extensions.


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

Modified: llvm/trunk/lib/Target/ARM/ARMISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/ARM/ARMISelLowering.cpp?rev=106940&r1=106939&r2=106940&view=diff
==============================================================================
--- llvm/trunk/lib/Target/ARM/ARMISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/ARM/ARMISelLowering.cpp Fri Jun 25 23:36:50 2010
@@ -459,11 +459,8 @@
   setOperationAction(ISD::ATOMIC_LOAD_XOR,  MVT::i64, Expand);
   setOperationAction(ISD::ATOMIC_LOAD_NAND, MVT::i64, Expand);
 
-  // If the subtarget does not have extract instructions, sign_extend_inreg
-  // needs to be expanded. Extract is available in ARM mode on v6 and up,
-  // and on most Thumb2 implementations.
-  if (!Subtarget->hasV6Ops()
-      || (Subtarget->isThumb2() && !Subtarget->hasT2ExtractPack())) {
+  // Requires SXTB/SXTH, available on v6 and up in both ARM and Thumb modes.
+  if (!Subtarget->hasV6Ops()) {
     setOperationAction(ISD::SIGN_EXTEND_INREG, MVT::i16, Expand);
     setOperationAction(ISD::SIGN_EXTEND_INREG, MVT::i8,  Expand);
   }





More information about the llvm-commits mailing list