public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "rguenth at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug target/104401] [x86] Failure to recognize min/max pattern using pcmp+pblendv
Date: Mon, 07 Feb 2022 07:59:18 +0000	[thread overview]
Message-ID: <bug-104401-4-O3FjzMn9Bh@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-104401-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #5 from Richard Biener <rguenth at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #3)
> On a slightly different subject, I wish VCOND would print out the tree code
> symbolically rather than just a number. It would be easier to understand
> what the condition exec is really.

Feel free to add a // comment after it ;)

Btw, forwprop1 sees

  <bb 2> :
  _12 = VIEW_CONVERT_EXPR<vector(4) int>(value_3(D));
  _13 = VIEW_CONVERT_EXPR<vector(4) int>(input_4(D));
  _14 = _12 < _13;
  _15 = VEC_COND_EXPR <_14, { -1, -1, -1, -1 }, { 0, 0, 0, 0 }>;
  _16 = VIEW_CONVERT_EXPR<__m128i>(_15);
  _6 = VIEW_CONVERT_EXPR<vector(16) char>(_15);
  _5 = VIEW_CONVERT_EXPR<vector(16) char>(value_3(D));
  _8 = VIEW_CONVERT_EXPR<vector(16) char>(input_4(D));
  _9 = _6 < { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
  _10 = VEC_COND_EXPR <_9, _5, _8>;
  _11 = VIEW_CONVERT_EXPR<__m128i>(_10);
  return _11;

the difficulty #1 is the v16qi mode blend vs. the v4si mode compare so
we'd have to pattern match the blend to be done on v4si based on the
_15 value range.

  parent reply	other threads:[~2022-02-07  7:59 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-02-05 21:32 [Bug target/104401] New: " gabravier at gmail dot com
2022-02-05 23:25 ` [Bug target/104401] " pinskia at gcc dot gnu.org
2022-02-05 23:28 ` pinskia at gcc dot gnu.org
2022-02-07  6:51 ` crazylht at gmail dot com
2022-02-07  6:57 ` pinskia at gcc dot gnu.org
2022-02-07  7:11 ` crazylht at gmail dot com
2022-02-07  7:59 ` rguenth at gcc dot gnu.org [this message]
2023-12-18  9:27 ` liuhongt at gcc dot gnu.org
2024-01-11  1:20 ` cvs-commit at gcc dot gnu.org
2024-01-11  1:21 ` liuhongt at gcc dot gnu.org
2024-01-20 17:18 ` pinskia at gcc dot gnu.org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-104401-4-O3FjzMn9Bh@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).