diff options
author | Matt Arsenault <Matthew.Arsenault@amd.com> | 2019-01-31 01:38:47 +0000 |
---|---|---|
committer | Matt Arsenault <Matthew.Arsenault@amd.com> | 2019-01-31 01:38:47 +0000 |
commit | 2a64598ef2ec4841dd48483dc368da034d80d933 (patch) | |
tree | 158052ad93e61e7d7e8879f984057f9074e63fad /llvm/lib/Target/ARM/ARMCallLowering.cpp | |
parent | 15df273eb45dc53669739bb33388a12c1dfce962 (diff) | |
download | bcm5719-llvm-2a64598ef2ec4841dd48483dc368da034d80d933.tar.gz bcm5719-llvm-2a64598ef2ec4841dd48483dc368da034d80d933.zip |
GlobalISel: Fix creating MMOs with align 0
llvm-svn: 352712
Diffstat (limited to 'llvm/lib/Target/ARM/ARMCallLowering.cpp')
-rw-r--r-- | llvm/lib/Target/ARM/ARMCallLowering.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/llvm/lib/Target/ARM/ARMCallLowering.cpp b/llvm/lib/Target/ARM/ARMCallLowering.cpp index ccb35961a51..def7c5ccb2e 100644 --- a/llvm/lib/Target/ARM/ARMCallLowering.cpp +++ b/llvm/lib/Target/ARM/ARMCallLowering.cpp @@ -131,7 +131,7 @@ struct OutgoingValueHandler : public CallLowering::ValueHandler { unsigned ExtReg = extendRegister(ValVReg, VA); auto MMO = MIRBuilder.getMF().getMachineMemOperand( MPO, MachineMemOperand::MOStore, VA.getLocVT().getStoreSize(), - /* Alignment */ 0); + /* Alignment */ 1); MIRBuilder.buildStore(ExtReg, Addr, *MMO); } @@ -331,11 +331,11 @@ struct IncomingValueHandler : public CallLowering::ValueHandler { assert(MRI.getType(ValVReg).isScalar() && "Only scalars supported atm"); auto LoadVReg = MRI.createGenericVirtualRegister(LLT::scalar(32)); - buildLoad(LoadVReg, Addr, Size, /* Alignment */ 0, MPO); + buildLoad(LoadVReg, Addr, Size, /* Alignment */ 1, MPO); MIRBuilder.buildTrunc(ValVReg, LoadVReg); } else { // If the value is not extended, a simple load will suffice. - buildLoad(ValVReg, Addr, Size, /* Alignment */ 0, MPO); + buildLoad(ValVReg, Addr, Size, /* Alignment */ 1, MPO); } } |