[llvm] Add Dead Block Elimination to NVVMReflect (PR #144171)
Artem Belevich via llvm-commits
llvm-commits at lists.llvm.org
Fri Jun 13 16:11:02 PDT 2025
Artem-B wrote:
I'm not quite sure what is the problem the patch is intended to solve.
> It's better to just have this pass handle deleting the dead blocks right away.
How is that better than the optimization passes we already have would not do?
NVVMReflect is normally added very early in the pipeline, and subsequent passes do a pretty good job eliminating the dead code after the call is replaced with a constant.
https://github.com/llvm/llvm-project/blob/d7e64d9594d241d6a9186fadad2b0d40a8fba8a7/llvm/lib/Target/NVPTX/NVPTXTargetMachine.cpp#L245-L250
https://github.com/llvm/llvm-project/pull/144171
More information about the llvm-commits
mailing list