mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-02-02 09:33:59 +00:00
An array of chars of length 8 will also cause the stack protector to be inserted
into the function. Reflect that here so that the array will be placed next to the SP. <rdar://problem/10128329> git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143590 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
1a1d1fcc0b
commit
9c674bb012
@ -92,7 +92,7 @@ void FunctionLoweringInfo::set(const Function &fn, MachineFunction &mf) {
|
||||
// candidate. I.e., it would trigger the creation of a stack protector.
|
||||
bool MayNeedSP =
|
||||
(AI->isArrayAllocation() ||
|
||||
(TySize > 8 && isa<ArrayType>(Ty) &&
|
||||
(TySize >= 8 && isa<ArrayType>(Ty) &&
|
||||
cast<ArrayType>(Ty)->getElementType()->isIntegerTy(8)));
|
||||
StaticAllocaMap[AI] =
|
||||
MF->getFrameInfo()->CreateStackObject(TySize, Align, false, MayNeedSP);
|
||||
|
Loading…
x
Reference in New Issue
Block a user