From: Segher Boessenkool <segher@kernel.crashing.org>
To: Paul Clarke <pc@us.ibm.com>
Cc: gcc-patches@gcc.gnu.org
Subject: Re: [PATCH 1/3][rs6000] x86-compat vector intrinsics fixes for BE, 32bit
Date: Tue, 04 Dec 2018 20:16:00 -0000 [thread overview]
Message-ID: <20181204201603.GI3803@gate.crashing.org> (raw)
In-Reply-To: <fd7571d1-1ce6-be2c-b474-116485a9674c@us.ibm.com>
Hi!
On Tue, Dec 04, 2018 at 08:59:03AM -0600, Paul Clarke wrote:
> Fix general endian and 32-bit mode issues found in the
> compatibility implementations of the x86 vector intrinsics when running the
> associated test suite tests. (The tests had been inadvertently made to PASS
> without actually running the test code. A later patch fixes this issue.)
>
> In a few cases, the opportunity was taken to update the vector API used in
> the implementations to the preferred functions from the
> OpenPOWER 64-Bit ELF V2 ABI Specification.
>
> [gcc]
>
> 2018-12-03 Paul A. Clarke <pc@us.ibm.com>
>
> PR target/88316
> * config/rs6000/mmintrin.h (_mm_unpackhi_pi8): Fix for big-endian.
> (_mm_unpacklo_pi8): Likewise.
> (_mm_mulhi_pi16): Likewise.
> (_mm_packs_pi16): Fix for big-endian. Use preferred API.
> (_mm_packs_pi32): Likewise.
> (_mm_packs_pu16): Likewise.
> * config/rs6000/xmmintrin.h (_mm_cvtss_si32): Fix for big-endian.
> (_mm_cvtss_si64): Likewise.
> (_mm_cvtpi32x2_ps): Likewise.
> (_mm_shuffle_ps): Likewise.
> (_mm_movemask_pi8): Likewise.
> (_mm_mulhi_pu16): Likewise.
> (_mm_sad_pu8): Likewise.
> (_mm_sad_pu8): Likewise.
> (_mm_cvtpu16_ps): Fix for big-endian. Use preferred API.
> (_mm_cvtpu8_ps): Likewise.
> * config/rs6000/emmintrin.h (_mm_movemask_pd): Fix for big-endian.
> (_mm_mul_epu32): Likewise.
> (_mm_bsrli_si128): Likewise.
> (_mm_movemask_epi8): Likewise.
> (_mm_shufflehi_epi16): Likewise.
> (_mm_shufflelo_epi16): Likewise.
> (_mm_shuffle_epi32): Likewise.
> * config/rs6000/pmmintrin.h (_mm_hadd_ps): Fix for big-endian.
> (_mm_sub_ps): Likewise.
> * config/rs6000/mmintrin.h (_mm_cmpeq_pi8): Fix for 32-bit mode.
> @@ -1612,7 +1608,8 @@ _mm_bsrli_si128 (__m128i __A, const int __N)
> const __v16qu zeros = { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };
>
> if (__N < 16)
> - if (__builtin_constant_p(__N))
> + if (__builtin_constant_p(__N) &&
> + __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__)
Please just use __LITTLE_ENDIAN__, as the rest of these files already does.
(More times in this patch; also BIG).
Okay for trunk with that fixed. Thanks!
Do you have new testcases, too? Or is all this caught by existing
testcases?
Segher
next prev parent reply other threads:[~2018-12-04 20:16 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-04 14:59 Paul Clarke
2018-12-04 20:16 ` Segher Boessenkool [this message]
2018-12-04 20:34 ` Paul Clarke
2018-12-04 23:01 ` Segher Boessenkool
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=20181204201603.GI3803@gate.crashing.org \
--to=segher@kernel.crashing.org \
--cc=gcc-patches@gcc.gnu.org \
--cc=pc@us.ibm.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).