[llvm] [X86] Improve FREEZE node elimination for SETCC operations (PR #192362)
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 17 07:26:31 PDT 2026
RKSimon wrote:
> > For the generic ISD::SETCC comparisons, we have to be more careful with fp comparisons as certain combos can create poison - are there any nodes that feed into X86ISD::SETCC/CARRY that can still create poison/undef?
>
> By poison, do you mean when `fast fcmp` have INF/NAN in inputs? But I think it's poisonous only in IR semantics. For a `X86ISD::SETCC`, we should have a determined output no matter what inputs it has?
Yes, afaict all the X86ISD::(U)COMI/(U)COMX are OK? I was just wanting to ensure all other nodes that feed X86ISD::SETCC/CARRY are as well. Whether we want to blindly assume never poison or whether we need to opt-in specific X86ISD node types.
We need to ensure we don't end up with a stuck freeze in a X86setcc(freeze(op)) chain that breaks the isel patterns
https://github.com/llvm/llvm-project/pull/192362
More information about the llvm-commits
mailing list