[PATCH] D113872: [CGP] Handle select instructions relying on the same condition

Sanjay Patel via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 12 09:42:46 PST 2022


spatel added a comment.

I think this was asked earlier, but I don't see an answer: could we prevent SimplifyCFG from forming these selects in the first place? Is the cost model broken in some way or just not accurate enough?

I don't object to adding/moving logic to CGP, but it's a bit strange that we are doing that while we are trying to move away from SDAG to GISel (CGP was intended to be a temporary pass to overcome the limits of one-block-at-a-time SDAG).

I sympathize with the previous comments about x86's cmov pass. AFAIK, we don't have all of the needed target/profile info in one place, so it always causes complaints.
There used to be a bunch of cmov bugs linked together in bugzilla, and I'm not sure how to find/link those again with github issues. Here's one:
https://github.com/llvm/llvm-project/issues/42246


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D113872/new/

https://reviews.llvm.org/D113872



More information about the llvm-commits mailing list