[PATCH 5/6] AVX512FP16: Initial support for AVX512FP16 feature and scalar _Float16 instructions.

2021-08-01 Thread liuhongt via Gcc-patches
From: "Guo, Xuepeng" gcc/ChangeLog: * common/config/i386/cpuinfo.h (get_available_features): Detect FEATURE_AVX512FP16. * common/config/i386/i386-common.c (OPTION_MASK_ISA_AVX512FP16_SET, OPTION_MASK_ISA_AVX512FP16_UNSET, OPTION_MASK_ISA2_AVX512FP1

Re: [PATCH][gcc/doc] Improve nonnull attribute documentation

2021-08-01 Thread Richard Biener
On Fri, 30 Jul 2021, Tom de Vries wrote: > On 7/30/21 6:17 PM, Martin Sebor wrote: > > On 7/28/21 9:20 AM, Tom de Vries wrote: > >> Hi, > >> > >> Improve nonnull attribute documentation in a number of ways: > >> > >> Reorganize discussion of effects into: > >> - effects for calls to functions with

Re: [PATCH][gcc/doc] Improve nonnull attribute documentation

2021-08-01 Thread Richard Biener
On Fri, 30 Jul 2021, Martin Sebor wrote: > On 7/30/21 2:21 PM, Tom de Vries wrote: > > On 7/30/21 6:17 PM, Martin Sebor wrote: > >> On 7/28/21 9:20 AM, Tom de Vries wrote: > >>> Hi, > >>> > >>> Improve nonnull attribute documentation in a number of ways: > >>> > >>> Reorganize discussion of effect

[PATCH 6/6] AVX512FP16: Support vector init/broadcast/set/extract for FP16.

2021-08-01 Thread liuhongt via Gcc-patches
gcc/ChangeLog: * config/i386/avx512fp16intrin.h (_mm_set_ph): New intrinsic. (_mm256_set_ph): Likewise. (_mm512_set_ph): Likewise. (_mm_setr_ph): Likewise. (_mm256_setr_ph): Likewise. (_mm512_setr_ph): Likewise. (_mm_set1_ph): Likewise.

[PATCH 3/6] [i386] libgcc: Enable hfmode soft-sf/df/xf/tf extensions and truncations.

2021-08-01 Thread liuhongt via Gcc-patches
libgcc/ChangeLog: * config/i386/32/sfp-machine.h (_FP_NANFRAC_H): New macro. * config/i386/64/sfp-machine.h (_FP_NANFRAC_H): Ditto. * config/i386/sfp-machine.h (_FP_NANSIGN_H): Ditto. * config/i386/t-softfp: Add hf soft-fp. * config.host: Add i386/64/t-softf

[PATCH 1/6] Update hf soft-fp from glibc.

2021-08-01 Thread liuhongt via Gcc-patches
libgcc/ChangeLog * soft-fp/eqhf2.c: New file. * soft-fp/extendhfdf2.c: New file. * soft-fp/extendhfsf2.c: New file. * soft-fp/extendhfxf2.c: New file. * soft-fp/half.h (FP_CMP_EQ_H): New marco. * soft-fp/truncdfhf2.c: New file * soft-fp/trunc

[PATCH 4/6] Support -fexcess-precision=16 which will enable FLT_EVAL_METHOD_PROMOTE_TO_FLOAT16 when backend supports _Float16.

2021-08-01 Thread liuhongt via Gcc-patches
gcc/ada/ChangeLog: * gcc-interface/misc.c (gnat_post_options): Issue an error for -fexcess-precision=16. gcc/c-family/ChangeLog: * c-common.c (excess_precision_mode_join): Update below comments. (c_ts18661_flt_eval_method): Set excess_precision_type to EXC

[PATCH V3 0/6] Initial support for AVX512FP16

2021-08-01 Thread liuhongt via Gcc-patches
Update from v2: 1. Support -fexcess-precision=16 which will enable FLT_EVAL_METHOD_PROMOTE_TO_FLOAT16 when backend supports _Float16. 2. Update ix86_get_excess_precision, so -fexcess-precision=standard should not do anything different from -fexcess-precision=fast regarding _Float16. 3. Avoiding

[PATCH 2/6] [i386] Enable _Float16 type for TARGET_SSE2 and above.

2021-08-01 Thread liuhongt via Gcc-patches
gcc/ChangeLog: * config/i386/i386-modes.def (FLOAT_MODE): Define ieee HFmode. * config/i386/i386.c (enum x86_64_reg_class): Add X86_64_SSEHF_CLASS. (merge_classes): Handle X86_64_SSEHF_CLASS. (examine_argument): Ditto. (construct_container): Ditto.

Re: [PATCH] Add emulated gather capability to the vectorizer

2021-08-01 Thread Kewen.Lin via Gcc-patches
on 2021/7/30 下午10:04, Kewen.Lin via Gcc-patches wrote: > Hi Richi, > > on 2021/7/30 下午7:34, Richard Biener wrote: >> This adds a gather vectorization capability to the vectorizer >> without target support by decomposing the offset vector, doing >> sclar loads and then building a vector from the re

Re: [PATCH 02/10] [i386] Enable _Float16 type for TARGET_SSE2 and above.

2021-08-01 Thread Hongtao Liu via Gcc-patches
On Fri, Jul 30, 2021 at 5:30 AM Joseph Myers wrote: > > On Thu, 29 Jul 2021, Hongtao Liu via Gcc-patches wrote: > > > > Rather than using FLT_EVAL_METHOD_PROMOTE_TO_FLOAT16 whenever TARGET_SSE2 > > > (i.e. whenever the type is available), it might make more sense to follow > > > AArch64 and use it

[RFC] Don't move cold code out of loop by checking bb count

2021-08-01 Thread Xiong Hu Luo via Gcc-patches
There was a patch trying to avoid move cold block out of loop: https://gcc.gnu.org/pipermail/gcc/2014-November/215551.html Richard suggested to "never hoist anything from a bb with lower execution frequency to a bb with higher one in LIM invariantness_dom_walker before_dom_children". This patch

Re: [PATCH 03/10] [i386] libgcc: Enable hfmode soft-sf/df/xf/tf extensions and truncations.

2021-08-01 Thread Hongtao Liu via Gcc-patches
On Fri, Jul 30, 2021 at 4:58 AM Joseph Myers wrote: > > On Tue, 27 Jul 2021, Hongtao Liu via Gcc-patches wrote: > > > modified gcc/emit-rtl.c > > @@ -928,6 +928,10 @@ validate_subreg (machine_mode omode, machine_mode > > imode, > > fix them all. */ > >if (omode == word_mode) > >

[PATCH] Support cond_add/sub/mul/div for vector float/double.

2021-08-01 Thread liuhongt via Gcc-patches
Hi: This patch supports cond_add/sub/mul/div expanders for vector float/double. There're still cond_fma/fms/fnms/fma/max/min/xor/ior/and left which I failed to figure out a testcase to validate them. Also cond_add/sub/mul for vector integer. Bootstrap is ok, survive the regression test on

Re: [PATCH] i386: Improve SImode constant - __builtin_clzll for -mno-lzcnt

2021-08-01 Thread Uros Bizjak via Gcc-patches
On Sun, Aug 1, 2021 at 7:12 PM H.J. Lu wrote: > > On Sat, Jul 31, 2021 at 12:53:44PM -0700, H.J. Lu wrote: > > On Fri, Jul 30, 2021 at 6:27 AM Jakub Jelinek via Gcc-patches > > wrote: > > > > > > On Fri, Jul 30, 2021 at 12:27:39PM +0200, Uros Bizjak wrote: > > > > Please put some space here, e.g.

[PATCH] Fix ICE when mixing VLAs and statement expressions [PR91038]

2021-08-01 Thread Uecker, Martin
Here is an attempt to fix some old and annoying bugs related to VLAs and statement expressions. In particulary, this seems to fix the issues with variably-modified types which are returned from statement expressions (which works on clang), but there are still bugs remaining related to structs wit

[PATCH] i386: Improve SImode constant - __builtin_clzll for -mno-lzcnt

2021-08-01 Thread H.J. Lu via Gcc-patches
On Sat, Jul 31, 2021 at 12:53:44PM -0700, H.J. Lu wrote: > On Fri, Jul 30, 2021 at 6:27 AM Jakub Jelinek via Gcc-patches > wrote: > > > > On Fri, Jul 30, 2021 at 12:27:39PM +0200, Uros Bizjak wrote: > > > Please put some space here, e.g.: > > ... > > > Can you just name the relevant insn pattern a

PING^2 [C PATCH] qualifiers of pointers to arrays in C2X [PR 98397]

2021-08-01 Thread Uecker, Martin
Am Freitag, den 11.06.2021, 21:25 +0200 schrieb Martin Uecker: > (PING. In case you missed this. Sorry, forgot to CC you.) > > Am Montag, den 24.05.2021, 08:05 +0200 schrieb Martin Uecker: > > Hi Joseph, > > > > I found some time to update this patch. The only real change > > of the patch is the