[llvm-commits] [llvm] r76162 - /llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp
Eli Friedman
eli.friedman at gmail.com
Fri Jul 17 00:16:41 PDT 2009
Author: efriedma
Date: Fri Jul 17 02:16:38 2009
New Revision: 76162
URL: http://llvm.org/viewvc/llvm-project?rev=76162&view=rev
Log:
Handle void in XCoreTargetLowering::isLegalAddressingMode. Triggers in
test/CodeGen/Generic.
Modified:
llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp
Modified: llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp?rev=76162&r1=76161&r2=76162&view=diff
==============================================================================
--- llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp (original)
+++ llvm/trunk/lib/Target/XCore/XCoreISelLowering.cpp Fri Jul 17 02:16:38 2009
@@ -1125,6 +1125,11 @@
bool
XCoreTargetLowering::isLegalAddressingMode(const AddrMode &AM,
const Type *Ty) const {
+ // Be conservative with void
+ // FIXME: Can we be more aggressive?
+ if (Ty->getTypeID() == Type::VoidTyID)
+ return false;
+
const TargetData *TD = TM.getTargetData();
unsigned Size = TD->getTypeAllocSize(Ty);
if (AM.BaseGV) {
More information about the llvm-commits
mailing list