[RFC/PATCH v3] ira: Support more matching constraint forms with param [PR100328]

2021-06-27 Thread Kewen.Lin via Gcc-patches
Hi! on 2021/6/9 下午1:18, Kewen.Lin via Gcc-patches wrote: > Hi, > > PR100328 has some details about this issue, I am trying to > brief it here. In the hottest function LBM_performStreamCollideTRT > of SPEC2017 bmk 519.lbm_r, there are many FMA style expressions > (27 FMA, 19 FMS, 11 FNMA). On rs

[PATCH v2] fixinc: don't "fix" machine names in __has_include(...) [PR91085]

2021-06-27 Thread Xi Ruoyao via Gcc-patches
v2: match for __has_include explicitly, as it may contains header name in <...> form. fixincludes/ * fixfixes.c (machine_name_fix): Don't replace header names in __has_include(...). * inclhack.def (machine_name): Adjust test. * tests/base/testing.h: Update. ---

Re: [PATCH 3/4] Try inverted comparison for match_simplify in phiopt

2021-06-27 Thread Bernhard Reutner-Fischer via Gcc-patches
On 28 June 2021 01:24:59 CEST, apinski--- via Gcc-patches wrote: >From: Andrew Pinski > >Since match and simplify does not have all of the inverted >comparison patterns, it make sense to just have >phi-opt try to do the inversion and try match and simplify again. > >OK? Bootstrapped and tested o

[PATCH][gcc] Allow functions without C-style ellipsis to use format attribute

2021-06-27 Thread Tuan Le Quang via Gcc-patches
Hi, Currently, format attribute can be used to do type-checking for arguments with respect to a format string. However, only functions with a C-style ellipsis can use it. Supporting this attribute for non-variadic functions(functions without a C-style ellipsis) gives nice convenience especially w

Re: [PATCH v5 1/2] x86: Convert CONST_WIDE_INT/CONST_VECTOR to broadcast

2021-06-27 Thread Hongtao Liu via Gcc-patches
On Sun, Jun 27, 2021 at 4:02 AM H.J. Lu wrote: > > 1. Update move expanders to convert the CONST_WIDE_INT and CONST_VECTO > operands to vector broadcast from an integer with AVX2. > 2. Add ix86_gen_scratch_sse_rtx to return a scratch SSE register which > won't increase stack alignment requirement

[PATCH 4/4] Port most of the A CMP 0 ? A : -A to match

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski To improve phiopt and be able to remove abs_replacement, this ports most of "A CMP 0 ? A : -A" from fold_cond_expr_with_comparison to match.pd. There is a few extra changes that are needed to remove the "A CMP 0 ? A : -A" part from fold_cond_expr_with_comparison: * Need to

[PATCH 3/4] Try inverted comparison for match_simplify in phiopt

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski Since match and simplify does not have all of the inverted comparison patterns, it make sense to just have phi-opt try to do the inversion and try match and simplify again. OK? Bootstrapped and tested on x86_64-linux-gnu. Thanks, Andrew Pinski gcc/ChangeLog: * tree

[PATCH 2/4] Allow match-and-simplified phiopt to run in early phiopt

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski To move a few things more to match-and-simplify from phiopt, we need to allow match_simplify_replacement to run in early phiopt. To do this we add a replacement for gimple_simplify that is explictly for phiopt. OK? Bootstrapped and tested on x86_64-linux-gnu with no regressio

[PATCH 1/4] Duplicate the range information of the phi onto the new ssa_name

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski Since match_simplify_replacement uses gimple_simplify, there is a new ssa name created sometimes and then we go and replace the phi edge with this new ssa name, the range information on the phi is lost. Placing this in replace_phi_edge_with_variable is the best option instead

[PATCH 0/4] v4 PHI-OPT move abs_replacement to match.pd

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski To able to move PHI-OPT's abs_replacement to match.pd, a bunch of support needed to be added to PHI-OPT. This is a set of 4 (unapproved) patches which allows us to remove abs_replacement and even does one set further and does a few extra transformations that abs_replacement di

[COMMITTED] Fix PR 101230: ICE in fold_cond_expr_with_comparison

2021-06-27 Thread apinski--- via Gcc-patches
From: Andrew Pinski This fixes PR 101230 where I had messed up and forgot that invert_tree_comparison can return ERROR_MARK if the comparsion is not invertable (floating point types). Committed as obvious after a bootstrap/test on x86_64-linux-gnu-gnu gcc/ChangeLog: PR middle-end/10123

Re: [PATCH 0.5/2] ipa-sra: Restructure how cloning and call redirection communicate (PR 93385)

2021-06-27 Thread Jan Hubicka
> > I was asked by Richi to split my fix for PR 93385 for easier review > into IPA-SRA materialization refactoring and the actual DCE addition. > Fortunately it was mostly natural except for a temporary weird > condition in ipa_param_body_adjustments::modify_call_stmt. > Additionally. In addition

Re: [PATCH v5 2/2] x86: Add vec_duplicate expander

2021-06-27 Thread Richard Sandiford via Gcc-patches
"H.J. Lu via Gcc-patches" writes: > On Sun, Jun 27, 2021 at 1:43 AM Richard Sandiford > wrote: >> >> "H.J. Lu" writes: >> > 1. Update vec_duplicate to allow to fail so that backend can only allow >> > broadcasting an integer constant to a vector when broadcast instruction >> > is available. Thi

[PATCH] Add AIX 7.3 Configuration

2021-06-27 Thread David Edelsohn via Gcc-patches
aix: Add AIX 7.3 configuration and SPDX License Identifiers. The anticipated release of AIX 7.3 has been announced. This patch adds the configuration bits based on AIX 7.2 configuration. gcc/ChangeLog: * config.gcc: Add SPDX License Identifier.

Re: [PATCH] tree-optimization/101186 - extend FRE with "equivalence map" for condition prediction

2021-06-27 Thread Aldy Hernandez via Gcc-patches
On 6/25/21 9:38 AM, Richard Biener wrote: On Thu, Jun 24, 2021 at 5:01 PM Andrew MacLeod wrote: On 6/24/21 9:25 AM, Andrew MacLeod wrote: On 6/24/21 8:29 AM, Richard Biener wrote: THe original function in EVRP currently looks like: === BB 2 : if (a_5(D)

Re: [PATCH v5 2/2] x86: Add vec_duplicate expander

2021-06-27 Thread H.J. Lu via Gcc-patches
On Sun, Jun 27, 2021 at 1:43 AM Richard Sandiford wrote: > > "H.J. Lu" writes: > > 1. Update vec_duplicate to allow to fail so that backend can only allow > > broadcasting an integer constant to a vector when broadcast instruction > > is available. This can be used by memset expander to avoid ve

[PATCH] opts: Do not stop when unknown -Wno-error value encountered [PR/65403]

2021-06-27 Thread Nicholas Guriev
gcc PR c/65403 * opts.c (enable_warning_as_error): Do not enable errors for negative options. Added parameter orig_text for better diagnose mistakes in options. gcc/testsuite * gcc.dg/Werror-13.c: Check a note about misspelled no-warning tag rather t

Re: [PATCH v5 2/2] x86: Add vec_duplicate expander

2021-06-27 Thread Richard Sandiford via Gcc-patches
"H.J. Lu" writes: > 1. Update vec_duplicate to allow to fail so that backend can only allow > broadcasting an integer constant to a vector when broadcast instruction > is available. This can be used by memset expander to avoid vec_duplicate > when loading from constant pool is more efficient. I