summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGStmt.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2010-02-05 21:10:36 +0000
committerDouglas Gregor <dgregor@apple.com>2010-02-05 21:10:36 +0000
commita64378048341b174d40552b7b0b3e79daf72cdad (patch)
tree54918ccb6071930d2cb4d9e87abf5abbb5c7e5c2 /clang/lib/CodeGen/CGStmt.cpp
parentc90dedbda003d0616cbcb996f0e0f55f3317f792 (diff)
downloadbcm5719-llvm-a64378048341b174d40552b7b0b3e79daf72cdad.tar.gz
bcm5719-llvm-a64378048341b174d40552b7b0b3e79daf72cdad.zip
Revert r95393, which broke Clang's self-host.
llvm-svn: 95430
Diffstat (limited to 'clang/lib/CodeGen/CGStmt.cpp')
-rw-r--r--clang/lib/CodeGen/CGStmt.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGStmt.cpp b/clang/lib/CodeGen/CGStmt.cpp
index 008a480b9c1..7ea8b08c238 100644
--- a/clang/lib/CodeGen/CGStmt.cpp
+++ b/clang/lib/CodeGen/CGStmt.cpp
@@ -861,13 +861,14 @@ llvm::Value* CodeGenFunction::EmitAsmInput(const AsmStmt &S,
std::string &ConstraintStr) {
llvm::Value *Arg;
if (Info.allowsRegister() || !Info.allowsMemory()) {
- if (!CodeGenFunction::hasAggregateLLVMType(InputExpr->getType())) {
+ const llvm::Type *Ty = ConvertType(InputExpr->getType());
+
+ if (Ty->isSingleValueType()) {
Arg = EmitScalarExpr(InputExpr);
} else {
InputExpr = InputExpr->IgnoreParenNoopCasts(getContext());
LValue Dest = EmitLValue(InputExpr);
- const llvm::Type *Ty = ConvertType(InputExpr->getType());
uint64_t Size = CGM.getTargetData().getTypeSizeInBits(Ty);
if (Size <= 64 && llvm::isPowerOf2_64(Size)) {
Ty = llvm::IntegerType::get(VMContext, Size);
OpenPOWER on IntegriCloud