From 8e79a39877f2127481a0c31b8c310353330daeae Mon Sep 17 00:00:00 2001 From: Dan Gohman Date: Fri, 14 Feb 2014 11:37:06 -0800 Subject: Don't try to nativize aggregate allocas. --- lib/Target/JSBackend/JSBackend.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'lib') diff --git a/lib/Target/JSBackend/JSBackend.cpp b/lib/Target/JSBackend/JSBackend.cpp index ea642163e3..b204026ff0 100644 --- a/lib/Target/JSBackend/JSBackend.cpp +++ b/lib/Target/JSBackend/JSBackend.cpp @@ -2083,6 +2083,7 @@ void JSWriter::calculateNativizedVars(const Function *F) { const Instruction *I = &*II; if (const AllocaInst *AI = dyn_cast(I)) { if (AI->getAllocatedType()->isVectorTy()) continue; // we do not nativize vectors, we rely on the LLVM optimizer to avoid load/stores on them + if (AI->getAllocatedType()->isAggregateType()) continue; // we do not nativize aggregates either // this is on the stack. if its address is never used nor escaped, we can nativize it bool Fail = false; for (Instruction::const_use_iterator UI = I->use_begin(), UE = I->use_end(); UI != UE && !Fail; ++UI) { -- cgit v1.2.3-18-g5258