public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "ibuclaw at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug d/110193] d_signed_or_unsigned_type is invoked for vector types
Date: Sat, 10 Jun 2023 18:25:57 +0000	[thread overview]
Message-ID: <bug-110193-4-ina2W27iZt@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-110193-4@http.gcc.gnu.org/bugzilla/>

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

ibuclaw at gcc dot gnu.org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ibuclaw at gcc dot gnu.org

--- Comment #2 from ibuclaw at gcc dot gnu.org ---
Just having a cursory look, the only references to d_signed_or_unsigned_type is
via d_unsigned_type and d_signed_type.

The former is only called by d_gimplify_unsigned_rshift_expr.

So I guess you must mean you've noticed this with something like.

    __vector(int[4]) unsigned_rshift(__vector(int[4]) v)
    {
        return v >>> 2;
    }

It turns out that this accident doesn't affect the intent on x86.

https://d.godbolt.org/z/99fK7fWaW

Gimple dump:
---
    __vector(int[4]) rshift (__vector(int[4]) v)
    {
      __vector(int[4]) D.1795;

      _1 = VIEW_CONVERT_EXPR<vector(4) unsigned int>(v);
      _2 = _1 >> 2;
      D.1795 = VIEW_CONVERT_EXPR<__vector(int[4])>(_2);
      return D.1795;
    }

  parent reply	other threads:[~2023-06-10 18:25 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-09 13:06 [Bug d/110193] New: " rguenth at gcc dot gnu.org
2023-06-09 14:59 ` [Bug d/110193] " pinskia at gcc dot gnu.org
2023-06-10 18:25 ` ibuclaw at gcc dot gnu.org [this message]
2023-06-10 18:40 ` ibuclaw at gcc dot gnu.org
2023-06-10 18:42 ` ibuclaw at gcc dot gnu.org
2023-06-12  7:58 ` rguenth at gcc dot gnu.org
2023-06-28 15:53 ` cvs-commit at gcc dot gnu.org
2023-06-28 16:28 ` ibuclaw at gcc dot gnu.org
2023-06-29  8:16 ` rguenth 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-110193-4-ina2W27iZt@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).