1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 11:13:28 +01:00

[CGP] Remove unnecessary MaybeAlign use (NFC)

Stores now always have an alignment.
This commit is contained in:
Nikita Popov 2020-06-05 23:18:26 +02:00
parent b9b812fe58
commit b04a55842b

View File

@ -7083,13 +7083,13 @@ static bool splitMergedValStore(StoreInst &SI, const DataLayout &DL,
Value *Addr = Builder.CreateBitCast(
SI.getOperand(1),
SplitStoreType->getPointerTo(SI.getPointerAddressSpace()));
Align Alignment = SI.getAlign();
const bool IsOffsetStore = (IsLE && Upper) || (!IsLE && !Upper);
if (IsOffsetStore)
if (IsOffsetStore) {
Addr = Builder.CreateGEP(
SplitStoreType, Addr,
ConstantInt::get(Type::getInt32Ty(SI.getContext()), 1));
MaybeAlign Alignment = SI.getAlign();
if (IsOffsetStore && Alignment) {
// When splitting the store in half, naturally one half will retain the
// alignment of the original wider store, regardless of whether it was
// over-aligned or not, while the other will require adjustment.