https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71921

Richard Biener <rguenth at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |crazylht at gmail dot com

--- Comment #24 from Richard Biener <rguenth at gcc dot gnu.org> ---
The testcase in the description works with GCC 15, the testcase in comment 16
does not.  Neither works with GCC 16 for me.

The x86 backend has ix86_expand_fp_movcc for scalar operations to detect
min/max, for vector it relies on combine IIRC.

We are not exposing the mask generation upon RTL expansion,
expand_vec_cond_mask_optab_fn does not try to TER here and
ix86_expand_sse_movcc
does

  else if (op_false == CONST0_RTX (mode))
    {
      x = expand_simple_binop (mode, AND, cmp, op_true,
                               dest, 1, OPTAB_DIRECT);
      if (x != dest)
        emit_move_insn (dest, x);

hereby confusing the existing combiner patterns (in general if this does not
match to min/max that's of course a good optimization).

Reply via email to