]> gcc.gnu.org Git - gcc.git/commit
AVX-512: Pacify -Wshift-overflow=2. [PR115409]
authorCollin Funk <collin.funk1@gmail.com>
Mon, 10 Jun 2024 06:36:47 +0000 (06:36 +0000)
committerliuhongt <hongtao.liu@intel.com>
Sun, 23 Jun 2024 06:48:41 +0000 (14:48 +0800)
commit4c957d7ba84d8bbce6e778048f38e92ef71806c8
tree5891c1201225b0994fbcf9fcd486ffb6e3ae7a8f
parent77f3b3419d476e90a2b82dff2204466aba3b9c2c
AVX-512: Pacify -Wshift-overflow=2. [PR115409]

A shift of 31 on a signed int is undefined behavior.  Since unsigned
int is 32-bits wide this change fixes it and silences the warning.

gcc/ChangeLog:

PR target/115409
* config/i386/avx512fp16intrin.h (_mm512_conj_pch): Make the
constant unsigned before shifting.
* config/i386/avx512fp16vlintrin.h (_mm256_conj_pch): Likewise.
(_mm_conj_pch): Likewise.

Signed-off-by: Collin Funk <collin.funk1@gmail.com>
gcc/config/i386/avx512fp16intrin.h
gcc/config/i386/avx512fp16vlintrin.h
This page took 0.06158 seconds and 6 git commands to generate.