In SIInstrInfo::areMemAccessesTriviallyDisjoint, the current implementation ignored the offset when creates MemoryLocation
for alias analysis, and thus may report wrong result when offset is not zero. This patch fixes the issue.
Details
Diff Detail
- Repository
- rL LLVM
Event Timeline
lib/Target/AMDGPU/SIInstrInfo.cpp | ||
---|---|---|
2218–2232 ↗ | (On Diff #187050) | Why can't you use MI.mayAlias and delete this? |
lib/Target/AMDGPU/SIInstrInfo.cpp | ||
---|---|---|
2218–2232 ↗ | (On Diff #187050) | This intends to fix a bug in an application. We can use MI.mayAlias and delete areMemAccessesTriviallyDisjoint. |
Use MachineInstr::mayAlias to replace areMemAccessesTriviallyDisjoint in LoadStoreOptimizer pass.
LGTM
test/CodeGen/AMDGPU/ds-combine-with-dependence.ll | ||
---|---|---|
69 ↗ | (On Diff #187272) | Typo oroginal |
lib/Target/AMDGPU/SILoadStoreOptimizer.cpp | ||
---|---|---|
264–265 ↗ | (On Diff #187273) | This merged part of the other patch |
lib/Target/AMDGPU/SILoadStoreOptimizer.cpp | ||
---|---|---|
264–265 ↗ | (On Diff #187273) | What do you mean here? I think this is the staring point of the current patch. We are going to replace |