From: Uros Bizjak <ubizjak@gmail.com>
To: Richard Biener <richard.guenther@gmail.com>
Cc: liuhongt <hongtao.liu@intel.com>,
gcc-patches@gcc.gnu.org, crazylht@gmail.com,
hjl.tools@gmail.com
Subject: Re: [PATCH] [vect]Use intermiediate integer type for float_expr/fix_trunc_expr when direct optab is not existed.
Date: Wed, 21 Jun 2023 16:37:09 +0200 [thread overview]
Message-ID: <CAFULd4Y10VyddaQiD8yEmoPAQy7AjMcvpW8sh2JfOajKZr-+ZA@mail.gmail.com> (raw)
In-Reply-To: <CAFiYyc0kHHUzi9n+=f8R-GZ-P3KuaFTZUpZBBx_o333nOcMemw@mail.gmail.com>
On Wed, Jun 21, 2023 at 10:22 AM Richard Biener
<richard.guenther@gmail.com> wrote:
> > > + /* For conversions between float and smaller integer types try whether we
> > > + can use intermediate signed integer types to support the
> > > + conversion. */
> >
> > I'm trying to enhance testcase coverage with explicit signed/unsigned
> > types (patch attached), and I have noticed that zero-extension is used
> > for unsigned types. So, the above comment that mentions only signed
> > integer types is not entirely correct.
>
> The comment says the intermediate sized vector types are always
> signed (because float conversions to/from unsigned are always somewhat
> awkward), but yes, if the original type was unsigned zero-extension is
> used and if it was signed sign-extension.
>
> The testcase adjustments / additions look good to me btw.
Thanks, pushed with the following ChangeLog:
vect: Add testcases for unsigned conversions [PR110018]
Also test conversions with unsigned types.
PR target/110018
gcc/testsuite/ChangeLog:
* gcc.target/i386/pr110018-1.c: Use explicit signed types.
* gcc.target/i386/pr110018-2.c: New test.
Tested on x86_64-linux-gnu {,-m32}.
Uros.
next prev parent reply other threads:[~2023-06-21 14:37 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-06-02 1:00 liuhongt
2023-06-20 8:38 ` Richard Biener
2023-06-20 9:09 ` Hongtao Liu
2023-06-20 9:22 ` Richard Biener
2023-06-20 16:11 ` liuhongt
2023-06-21 7:49 ` Uros Bizjak
2023-06-21 8:19 ` Richard Biener
2023-06-21 14:37 ` Uros Bizjak [this message]
2023-06-22 20:36 ` Thiago Jung Bauermann
2023-06-21 9:10 ` Richard Sandiford
2023-06-21 9:32 ` Richard Sandiford
2023-06-21 11:04 ` Richard Biener
2023-06-21 11:20 ` Richard Sandiford
2023-06-21 20:39 ` Joseph Myers
2023-06-22 7:32 ` Richard Biener
2023-07-12 9:19 ` Robin Dapp
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=CAFULd4Y10VyddaQiD8yEmoPAQy7AjMcvpW8sh2JfOajKZr-+ZA@mail.gmail.com \
--to=ubizjak@gmail.com \
--cc=crazylht@gmail.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=hjl.tools@gmail.com \
--cc=hongtao.liu@intel.com \
--cc=richard.guenther@gmail.com \
/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).