forked from OSchip/llvm-project
When emitting an aggregate into a temporary, make sure we set the alignment
on the alloca. The fact that codegen makes this class of bug so wonderfully easy to make is embarrassing. llvm-svn: 96204
This commit is contained in:
parent
4d8feb11dd
commit
7538eec67b
|
@ -95,7 +95,7 @@ RValue CodeGenFunction::EmitAnyExprToTemp(const Expr *E,
|
|||
|
||||
if (hasAggregateLLVMType(E->getType()) &&
|
||||
!E->getType()->isAnyComplexType())
|
||||
AggLoc = CreateTempAlloca(ConvertTypeForMem(E->getType()), "agg.tmp");
|
||||
AggLoc = CreateMemTemp(E->getType(), "agg.tmp");
|
||||
return EmitAnyExpr(E, AggLoc, IsAggLocVolatile, /*IgnoreResult=*/false,
|
||||
IsInitializer);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue