After updating cost model in AMDGPU target (47a5c36b37f0) the pass started to
ignore some BBs since they got all instructions estimated as free.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
- Build Status
Buildable 46907 Build 49592: arc lint + arc unit
Event Timeline
llvm/test/CodeGen/AMDGPU/speculative-execution-freecasts.ll | ||
---|---|---|
13 | Would probably be better to have real values, since someday something might conclude any undef operation is free or something |
Is it expected for binary size increases to result from this? Between the commit for this patch and the commit before it, I'm seeing an increase in some fuchsia ZBIs by about 13 kB.
I think this pass is also running for non-GPU targets. I'm seeing this pass run on x86_64, aarch64, and riscv64 when building a toolchain for those targets.
https://github.com/llvm/llvm-project/blob/a4cde9ad7b6f1a4cfef228f6cf2fc4911bf24c77/llvm/lib/Passes/PassBuilder.cpp#L436 seems to add it to the new PM default function pipeline that I think runs as long as optimizations are available.
That doesn't match what the comment says, or the old PM does (which does createSpeculativeExecutionIfHasBranchDivergencePassz)
@chandlerc It seems like you added the pass to the new PM pipelne in https://reviews.llvm.org/rGe3f5064b7235 with the main difference being OnlyIfDivergentTarget false whereas OnlyIfDivergentTarget is true in the old PM with createSpeculativeExecutionIfHasBranchDivergencePass. Is this intentional?
Hi!
I just wrote a PR about a debug-info fault that starts occuring with this patch:
https://bugs.llvm.org/show_bug.cgi?id=46267
Would probably be better to have real values, since someday something might conclude any undef operation is free or something