aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorCraig Topper <craig.topper@sifive.com>2025-06-27 08:58:06 -0700
committerGitHub <noreply@github.com>2025-06-27 08:58:06 -0700
commit9df1c81fee5b304ca412f45eb922d8069b0aa996 (patch)
tree102d977b1cbd687659a5dcca96a8a3a4746e14c0 /clang/lib/Frontend/CompilerInvocation.cpp
parent375af75efb2ed24f17c1d261bc3c094cac644509 (diff)
downloadllvm-9df1c81fee5b304ca412f45eb922d8069b0aa996.zip
llvm-9df1c81fee5b304ca412f45eb922d8069b0aa996.tar.gz
llvm-9df1c81fee5b304ca412f45eb922d8069b0aa996.tar.bz2
[SelectionDAG] Combine range metadata when loads are CSEd. (#146026)
When CSEing a load with an existing load with different range metadata, clear the range metadata on the existing load. This is conservative, alternatively we could calculate new range metadata using MDNode::getMostGenericRange. Without a test case I wasn't sure it was worth it. MDnode::getMostGenericRange takes a non-const MDNode*, but all of SelectionDAG uses const MDNode*. A const_cast will need to be used somewhere or we need to make the codebase consistent about whether MDNode pointers should be const or not. I'm sure this isn't the only place that needs to be updated to handle the CSE. Fixes #145363.
Diffstat (limited to 'clang/lib/Frontend/CompilerInvocation.cpp')
0 files changed, 0 insertions, 0 deletions