Commit 787ddf9
committed
[AMDGPU] Enable unaligned scratch accesses (llvm#110219)
This allows us to emit wide generic and scratch memory accesses when we
do not have alignment information. In cases where accesses happen to be
properly aligned or where generic accesses do not go to scratch memory,
this improves performance of the generated code by a factor of up to 16x
and reduces code size, especially when lowering memcpy and memmove
intrinsics.
Also: Make the use of the FeatureUnalignedScratchAccess feature more
consistent: FeatureUnalignedScratchAccess and EnableFlatScratch are now
orthogonal, whereas, before, code assumed that the latter implies the
former at some places.
Part of SWDEV-455845.
(cherry picked from commit 173c682,
resolved merge conflicts in AMDGPU.td, flat-scratch.ll,
memcpy-libcall.ll)
Change-Id: I90383aa32ea4587b9dedd48fc6fa297f4263e8a81 parent a3c72d5 commit 787ddf9
File tree
15 files changed
+6082
-17788
lines changed- llvm
- lib/Target/AMDGPU
- test/CodeGen/AMDGPU
- GlobalISel
15 files changed
+6082
-17788
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1170 | 1170 | | |
1171 | 1171 | | |
1172 | 1172 | | |
1173 | | - | |
1174 | | - | |
| 1173 | + | |
| 1174 | + | |
| 1175 | + | |
1175 | 1176 | | |
1176 | 1177 | | |
1177 | 1178 | | |
| |||
1190 | 1191 | | |
1191 | 1192 | | |
1192 | 1193 | | |
1193 | | - | |
1194 | | - | |
1195 | | - | |
| 1194 | + | |
| 1195 | + | |
| 1196 | + | |
1196 | 1197 | | |
1197 | 1198 | | |
1198 | 1199 | | |
| |||
1213 | 1214 | | |
1214 | 1215 | | |
1215 | 1216 | | |
1216 | | - | |
1217 | | - | |
1218 | | - | |
| 1217 | + | |
| 1218 | + | |
| 1219 | + | |
1219 | 1220 | | |
1220 | 1221 | | |
1221 | 1222 | | |
| |||
1235 | 1236 | | |
1236 | 1237 | | |
1237 | 1238 | | |
1238 | | - | |
1239 | | - | |
1240 | | - | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
1241 | 1242 | | |
1242 | 1243 | | |
1243 | 1244 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
387 | 387 | | |
388 | 388 | | |
389 | 389 | | |
390 | | - | |
391 | | - | |
| 390 | + | |
| 391 | + | |
392 | 392 | | |
393 | 393 | | |
394 | 394 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
590 | 590 | | |
591 | 591 | | |
592 | 592 | | |
| 593 | + | |
| 594 | + | |
| 595 | + | |
| 596 | + | |
593 | 597 | | |
594 | 598 | | |
595 | 599 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1826 | 1826 | | |
1827 | 1827 | | |
1828 | 1828 | | |
1829 | | - | |
1830 | | - | |
1831 | | - | |
1832 | | - | |
1833 | | - | |
1834 | | - | |
1835 | | - | |
1836 | | - | |
1837 | | - | |
1838 | | - | |
1839 | 1829 | | |
1840 | 1830 | | |
1841 | 1831 | | |
1842 | | - | |
1843 | | - | |
| 1832 | + | |
| 1833 | + | |
1844 | 1834 | | |
1845 | 1835 | | |
1846 | 1836 | | |
1847 | 1837 | | |
1848 | | - | |
| 1838 | + | |
1849 | 1839 | | |
1850 | 1840 | | |
1851 | 1841 | | |
| |||
0 commit comments