aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/ProfileData/Coverage/CoverageMapping.cpp
diff options
context:
space:
mode:
authorPhilip Reames <preames@rivosinc.com>2023-09-18 09:33:37 -0700
committerPhilip Reames <listmail@philipreames.com>2023-09-18 09:41:34 -0700
commit07228002891c5b970b8f5a0040adf3176b168171 (patch)
tree6e8801f595e66420e8307a984d10b15ab95fb2d9 /llvm/lib/ProfileData/Coverage/CoverageMapping.cpp
parentfa44ec72d6d15cb42dd457b95d5456ef43bfe834 (diff)
downloadllvm-07228002891c5b970b8f5a0040adf3176b168171.zip
llvm-07228002891c5b970b8f5a0040adf3176b168171.tar.gz
llvm-07228002891c5b970b8f5a0040adf3176b168171.tar.bz2
[RISCV] Match constant indices of non-index type when forming strided ops (#65777)
When checking to see if our index expressions can be converted into strided operations, we previously gave up if the index type wasn't an exact match for the intptrty for the address. Per gep semantics, this mismatch implies a sext or trunc cast to the respective index type. For constants, go ahead and evaluate that cast instead of giving up. Note that the motivation of this is mostly test cleanup. We canonicalize at IR such that the gep index will match the intptrty. This is mostly useful so that we can write both RV32 and RV64 tests from the same source. Its also helpful in preventing confusion - I've stumbled across this at least four times now and wasted time each one. Note: The test change for scatters unit stride cases contains a minor regression for rv32 and 64 bit indices. This is an artifact of order in which changes are landing. This will be addressed in a near future change for all configurations.
Diffstat (limited to 'llvm/lib/ProfileData/Coverage/CoverageMapping.cpp')
0 files changed, 0 insertions, 0 deletions