summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/ARM
diff options
context:
space:
mode:
authorDiana Picus <diana.picus@linaro.org>2019-04-30 09:05:25 +0000
committerDiana Picus <diana.picus@linaro.org>2019-04-30 09:05:25 +0000
commit1e88ac213b638ee44a766361851671e892c0f390 (patch)
tree1ea6ea44eaa77fe979626a5960ac94c11695d06b /llvm/lib/Target/ARM
parentc21ec00d2852fdbae9cf803602276e4f26ce76c1 (diff)
downloadbcm5719-llvm-1e88ac213b638ee44a766361851671e892c0f390.tar.gz
bcm5719-llvm-1e88ac213b638ee44a766361851671e892c0f390.zip
[ARM GlobalISel] Be more careful about bailing out
Bail out on function arguments/returns with types aggregating an unsupported type. This fixes cases where we would happily and incorrectly lower functions taking e.g. [1 x i64] parameters, when we don't even support plain i64 yet. llvm-svn: 359540
Diffstat (limited to 'llvm/lib/Target/ARM')
-rw-r--r--llvm/lib/Target/ARM/ARMCallLowering.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/ARM/ARMCallLowering.cpp b/llvm/lib/Target/ARM/ARMCallLowering.cpp
index b70d55f73ba..5229064032a 100644
--- a/llvm/lib/Target/ARM/ARMCallLowering.cpp
+++ b/llvm/lib/Target/ARM/ARMCallLowering.cpp
@@ -55,7 +55,7 @@ ARMCallLowering::ARMCallLowering(const ARMTargetLowering &TLI)
static bool isSupportedType(const DataLayout &DL, const ARMTargetLowering &TLI,
Type *T) {
if (T->isArrayTy())
- return true;
+ return isSupportedType(DL, TLI, T->getArrayElementType());
if (T->isStructTy()) {
// For now we only allow homogeneous structs that we can manipulate with
@@ -64,7 +64,7 @@ static bool isSupportedType(const DataLayout &DL, const ARMTargetLowering &TLI,
for (unsigned i = 1, e = StructT->getNumElements(); i != e; ++i)
if (StructT->getElementType(i) != StructT->getElementType(0))
return false;
- return true;
+ return isSupportedType(DL, TLI, StructT->getElementType(0));
}
EVT VT = TLI.getValueType(DL, T, true);
OpenPOWER on IntegriCloud