diff options
| author | Chris Lattner <sabre@nondot.org> | 2006-12-12 04:24:41 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2006-12-12 04:24:41 +0000 |
| commit | 6e5fe376ec898e651526107485d2a0f6e4000789 (patch) | |
| tree | 03949c8ded4c6cee8562fc03d67337298d56f14e /llvm/lib/Transforms | |
| parent | f65ce046db71daf4a4be78dbb7993296510e064c (diff) | |
| download | bcm5719-llvm-6e5fe376ec898e651526107485d2a0f6e4000789.tar.gz bcm5719-llvm-6e5fe376ec898e651526107485d2a0f6e4000789.zip | |
Patch for PR1045 and Transforms/ScalarRepl/2006-12-11-SROA-Crash.ll
llvm-svn: 32468
Diffstat (limited to 'llvm/lib/Transforms')
| -rw-r--r-- | llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp index 764cda69e36..080d8115ff9 100644 --- a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp +++ b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp @@ -433,6 +433,8 @@ static bool MergeInType(const Type *In, const Type *&Accum, const PackedType *PTy; if (Accum == Type::VoidTy || In == Accum) { Accum = In; + } else if (In == Type::VoidTy) { + // Noop. } else if (In->isIntegral() && Accum->isIntegral()) { // integer union. // Otherwise pick whichever type is larger. if (In->getTypeID() > Accum->getTypeID()) |

