Re: [PATCH 3/4] PowerPC: Add power10 xsmaxcqp/xsmincqp support

2020-08-27 Thread Michael Meissner via Gcc-patches
On Thu, Aug 27, 2020 at 03:47:19PM -0500, will schmidt wrote: > > (Fm): New mode attribute for floating point scalars. > > Mixed feels on mixed case, but I defer. :-) It is similar to other mode attributes (Ff, Fv) used for setting constraints based on the mode. -- Michael Meissner, IBM

[PATCH] fix a typo in rtl.texi

2020-08-27 Thread Wei Wentao
Hi, This patch fix a typo in rtl.texi. Regards! Weiwt --- gcc/doc/rtl.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/doc/rtl.texi b/gcc/doc/rtl.texi index 501fa1a31da..f8e1f950823 100644 --- a/gcc/doc/rtl.texi +++ b/gcc/doc/rtl.texi @@ -3954,7 +3954,7 @@

Re: [PATCH 3/3] vec: use inexact growth where possible.

2020-08-27 Thread Richard Biener via Gcc-patches
On Wed, Aug 26, 2020 at 11:02 PM Jeff Law wrote: > > On Tue, 2020-08-11 at 13:37 +0200, Martin Liška wrote: > > From cc1d41a469d76f2f8e4f44bed788ace77a1c6d62 Mon Sep 17 00:00:00 2001 > > From: Martin Liska > > Date: Mon, 10 Aug 2020 12:09:19 +0200 > > Subject: [PATCH 3/3] vec: use inexact growth

Re: [PATCH] arm: Fix -mpure-code support/-mslow-flash-data for armv8-m.base [PR94538]

2020-08-27 Thread Ramana Radhakrishnan via Gcc-patches
On Mon, Aug 24, 2020 at 4:35 PM Christophe Lyon wrote: > > On Mon, 24 Aug 2020 at 11:09, Christophe Lyon > wrote: > > > > On Sat, 22 Aug 2020 at 00:44, Ramana Radhakrishnan > > wrote: > > > > > > On Wed, Aug 19, 2020 at 10:32 AM Christophe Lyon via Gcc-patches > > > wrote: > > > > > > > >

[PATCH] C-SKY: Add fpuv3 instructions and CK860 arch

2020-08-27 Thread gengqi via Gcc-patches
From: gengq gcc/ChangeLog: * config/csky/constraints.md (W): New constriant for mem operand with a base reg with a index register. (Q): Renamed and modified "csky_valid_fpuv2_mem_operand" to "csky_valid_mem_constraint_operand" to deal with both "Q" and "W"

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Fri, Jul 31, 2020 at 04:28:05PM -0400, Jason Merrill via Gcc-patches wrote: > On 7/31/20 6:06 AM, Jakub Jelinek wrote: > > On Fri, Jul 31, 2020 at 10:54:46AM +0100, Jonathan Wakely wrote: > > > > Does the standard require that somewhere? Because that is not what the > > > > compiler implements

Re: [PATCH] [AVX512] [PR87767] Optimize memory broadcast for constant vector under AVX512

2020-08-27 Thread Jan Hubicka
> Under what circumstances are we seeing a SEQUENCE in the x86 backend? I'm > surprised we need to handle that case. > > So your pass modifies the insn in place, which is fine. But do we actually > remove the original constant pool entry if it's no longer used? If not, does > this patch

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 27/08/20 13:17 +0200, Jakub Jelinek wrote: On Thu, Aug 27, 2020 at 12:06:59PM +0100, Jonathan Wakely wrote: On 27/08/20 12:46 +0200, Jakub Jelinek wrote: > On Thu, Aug 27, 2020 at 12:06:13PM +0200, Jakub Jelinek via Gcc-patches wrote: > > Oops, rewrote the testcase from __builtin_bit_cast to

Re: [PATCH] testsuite: add -fno-tree-fre in gcc.dg/guality

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Thu, Aug 27, 2020 at 11:13:50AM +, Hu, Jiangping wrote: > I'm not sure about if the case should fail. > So, I add Jakub who committed this testcase. > > I thought the case should success, but for changes of gcc of > years, now it failed. So I think that may be some optimization > are

Re: [PATCH] testsuite: add -fno-tree-fre in gcc.dg/guality

2020-08-27 Thread Richard Biener via Gcc-patches
On Thu, Aug 27, 2020 at 3:38 AM Hu Jiangping wrote: > > This patch add -fno-tree-fre to dg-options in gcc.dg/guality/sra-1.c, > to make the following testcases passed. > > FAIL: gcc.dg/guality/sra-1.c -Og -DPREVENT_OPTIMIZATION line 43 a.i == 4 > FAIL: gcc.dg/guality/sra-1.c -Og

Re: [PATCH] x86: Reject target("no-general-regs-only")

2020-08-27 Thread H.J. Lu via Gcc-patches
On Thu, Aug 27, 2020 at 1:47 AM Richard Biener wrote: > > On Wed, Aug 26, 2020 at 9:40 PM H.J. Lu via Gcc-patches > wrote: > > > > Reject target("no-general-regs-only") pragma and attribute. > > mgeneral-regs-only > Target Report RejectNegative Mask(GENERAL_REGS_ONLY) Var(ix86_target_flags) >

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Thu, Aug 27, 2020 at 12:06:13PM +0200, Jakub Jelinek via Gcc-patches wrote: Oops, rewrote the testcase from __builtin_bit_cast to std::bit_cast without adjusting the syntax properly. Also, let's not use bitfields in there, as clang doesn't support those. So, adjusted testcase below. clang++

Re: [PATCH] arm: Fix -mpure-code support/-mslow-flash-data for armv8-m.base [PR94538]

2020-08-27 Thread Christophe Lyon via Gcc-patches
On Thu, 27 Aug 2020 at 11:02, Ramana Radhakrishnan wrote: > > On Mon, Aug 24, 2020 at 4:35 PM Christophe Lyon > wrote: > > > > On Mon, 24 Aug 2020 at 11:09, Christophe Lyon > > wrote: > > > > > > On Sat, 22 Aug 2020 at 00:44, Ramana Radhakrishnan > > > wrote: > > > > > > > > On Wed, Aug 19,

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Richard Biener
On Thu, 27 Aug 2020, Jakub Jelinek wrote: > On Fri, Jul 31, 2020 at 04:28:05PM -0400, Jason Merrill via Gcc-patches wrote: > > On 7/31/20 6:06 AM, Jakub Jelinek wrote: > > > On Fri, Jul 31, 2020 at 10:54:46AM +0100, Jonathan Wakely wrote: > > > > > Does the standard require that somewhere?

[PATCH] ia32: Fix alignment of _Atomic fields [PR65146]

2020-08-27 Thread Jakub Jelinek via Gcc-patches
Hi! For _Atomic fields, lowering the alignment of long long or double etc. fields on ia32 is undesirable, because then one really can't perform atomic operations on those using cmpxchg8b. The following patch stops lowering the alignment in fields for _Atomic types (the x86_field_alignment

Re: [PATCH] fix testcase gcc.target/aarch64/insv_1.c

2020-08-27 Thread Iain Sandoe via Gcc-patches
Richard Sandiford wrote: "Qian, Jianhua" writes: Hi Richard I found that some instructions are using '#' before immediate value, and others are not. For example (define_insn "insv_imm" [(set (zero_extract:GPI (match_operand:GPI 0 "register_operand" "+r")

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 27/08/20 12:06 +0200, Jakub Jelinek wrote: On Fri, Jul 31, 2020 at 04:28:05PM -0400, Jason Merrill via Gcc-patches wrote: On 7/31/20 6:06 AM, Jakub Jelinek wrote: > On Fri, Jul 31, 2020 at 10:54:46AM +0100, Jonathan Wakely wrote: > > > Does the standard require that somewhere? Because that

[PATCH] streamline TARGET_MEM_REF dumping

2020-08-27 Thread Richard Biener
The following streamlines TARGET_MEM_REF dumping building on what we do for MEM_REF and thus dumping things like access type, TBAA type and base/clique. I've changed it to do semantic dumping aka base + offset + step * index rather than the odd base: A, step: way. Bootstrapped and tested on

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 27/08/20 12:46 +0200, Jakub Jelinek wrote: On Thu, Aug 27, 2020 at 12:06:13PM +0200, Jakub Jelinek via Gcc-patches wrote: Oops, rewrote the testcase from __builtin_bit_cast to std::bit_cast without adjusting the syntax properly. Also, let's not use bitfields in there, as clang doesn't

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Thu, Aug 27, 2020 at 12:06:59PM +0100, Jonathan Wakely wrote: > On 27/08/20 12:46 +0200, Jakub Jelinek wrote: > > On Thu, Aug 27, 2020 at 12:06:13PM +0200, Jakub Jelinek via Gcc-patches > > wrote: > > > > Oops, rewrote the testcase from __builtin_bit_cast to std::bit_cast without > >

Re: [PATCH] x86: Reject target("no-general-regs-only")

2020-08-27 Thread Richard Biener via Gcc-patches
On Wed, Aug 26, 2020 at 9:40 PM H.J. Lu via Gcc-patches wrote: > > Reject target("no-general-regs-only") pragma and attribute. mgeneral-regs-only Target Report RejectNegative Mask(GENERAL_REGS_ONLY) Var(ix86_target_flags) Save Generate code which uses only the general registers. it has already

Re: [PATCH] hppa: Improve expansion of ashldi3 when !TARGET_64BIT

2020-08-27 Thread Richard Biener via Gcc-patches
On Thu, Aug 27, 2020 at 9:17 AM Roger Sayle wrote: > > > >On 2020-08-26 5:23 p.m., Roger Sayle wrote: > >> These more accurate target rtx_costs are used by the > >> gimple-ssa-strength-reduction.c (via a call to mult_by_coeff_cost) to > >> decide whether applying strength reduction would be

RE: [PATCH] testsuite: add -fno-tree-fre in gcc.dg/guality

2020-08-27 Thread Hu, Jiangping
Hi, Richard, Jakub Thanks for reply. I'm not sure about if the case should fail. So, I add Jakub who committed this testcase. I thought the case should success, but for changes of gcc of years, now it failed. So I think that may be some optimization are unnecessary for this testcase, and I

Re: [PATCH] C-SKY: Add -mbacktrace option.

2020-08-27 Thread Jojo R
Hi, Ok & thanks, I will reroll this :) Jojo 在 2020年8月26日 +0800 AM4:22,Jeff Law ,写道: > On Fri, 2020-08-21 at 14:18 +0800, Jojo R wrote: > > gcc/ChangeLog: > > > > * config/csky/csky.opt (TARGET_BACKTRACE): New. > > * doc/invoke.texi (C-SKY Options): Document -mbacktrace. > ISTM you need

[PATCH] cfgloop.h: Reword comment describing is_exit flag

2020-08-27 Thread Alex Coplan
This simple patch rewords a comment in cfgloop.h to improve the grammar and readability. OK for master? Thanks, Alex --- gcc/ChangeLog: * cfgloop.h (nb_iter_bound): Reword comment describing is_exit. diff --git a/gcc/cfgloop.h b/gcc/cfgloop.h index 18b404e292f..be978288aab 100644 ---

[PATCH] arm: Fix switch tables for thumb-1 with -mpure-code [PR96768]

2020-08-27 Thread Christophe Lyon via Gcc-patches
In comment 14 from PR94538, it was suggested to switch off jump tables on thumb-1 cores when using -mpure-code, like we already do for thumb-2. This is what this patch does, and also restores the previous value of CASE_VECTOR_PC_RELATIVE since it was not the right way of handling this. It also

Re: [PATCH] [AVX512] [PR87767] Optimize memory broadcast for constant vector under AVX512

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Thu, Jul 09, 2020 at 04:33:46PM +0800, Hongtao Liu via Gcc-patches wrote: > +static void > +replace_constant_pool_with_broadcast (rtx_insn* insn) > +{ > + subrtx_ptr_iterator::array_type array; > + FOR_EACH_SUBRTX_PTR (iter, array, (insn), ALL) > +{ > + rtx *loc = *iter; > +

[PATCH] tree-optimization/96522 - transfer of flow-sensitive info in copy_ref_info

2020-08-27 Thread Richard Biener
This removes the bogus tranfer of flow-sensitive info in copy_ref_info plus fixes one oversight in FRE when flow-sensitive non-NULLness was added to points-to info. Bootstrapped / tested on x86_64-unknown-linux-gnu, pushed. 2020-08-27 Richard Biener PR tree-optimization/96522

[PATCH] rtl-optimization/96812 - remap dependence info on RTL loop unrolling

2020-08-27 Thread Richard Biener
This carries over the PR87609 fix also to RTL loop unrolling. The gcc.dg/torture/pr90328.c testcase otherwise is miscompiled with the tree-ssa-address.c hunk (or alternatively with -fno-ivopts on master). I've tried to find the correct abstraction and adjusted two other duplicate_insn_chain

Re: [PATCH] [AVX512] [PR87767] Optimize memory broadcast for constant vector under AVX512

2020-08-27 Thread Richard Biener via Gcc-patches
On Thu, Aug 27, 2020 at 2:25 PM Jakub Jelinek via Gcc-patches wrote: > > On Thu, Jul 09, 2020 at 04:33:46PM +0800, Hongtao Liu via Gcc-patches wrote: > > +static void > > +replace_constant_pool_with_broadcast (rtx_insn* insn) > > +{ > > + subrtx_ptr_iterator::array_type array; > > +

[PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Bill Schmidt via Gcc-patches
Prior to P10, ELFv2 hasn't implemented nonlocal sibcalls. Now that we do, we need to be sure that r12 is set up prior to such a call. Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no regressions. Is this okay for trunk? Thanks, Bill 2020-08-27 Bill Schmidt gcc/ PR

[PATCH] x86: Add -mbaseline-isas-only/target("baseline-isas-only")

2020-08-27 Thread H.J. Lu via Gcc-patches
On Tue, Aug 25, 2020 at 5:27 AM Uros Bizjak wrote: > > On Tue, Aug 25, 2020 at 2:13 PM H.J. Lu wrote: > > > > On Mon, Aug 24, 2020 at 12:40 PM H.J. Lu wrote: > > > > > > On Mon, Aug 24, 2020 at 12:25 PM Uros Bizjak wrote: > > > > > > > > On Mon, Aug 24, 2020 at 6:17 PM H.J. Lu wrote: > > > >

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Alan Modra via Gcc-patches
On Thu, Aug 27, 2020 at 08:21:34AM -0500, Bill Schmidt wrote: > Prior to P10, ELFv2 hasn't implemented nonlocal sibcalls. Now that we do, > we need to be sure that r12 is set up prior to such a call. > > Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no > regressions. Is this

Re: [PATCH] ia32: Fix alignment of _Atomic fields [PR65146]

2020-08-27 Thread Uros Bizjak via Gcc-patches
On Thu, Aug 27, 2020 at 10:35 AM Jakub Jelinek wrote: > > Hi! > > For _Atomic fields, lowering the alignment of long long or double etc. > fields on ia32 is undesirable, because then one really can't perform atomic > operations on those using cmpxchg8b. > > The following patch stops lowering the

Re: [PATCH v4] genemit.c (main): split insn-emit.c for compiling parallelly

2020-08-27 Thread Jojo R
Jojo 在 2020年8月2日 +0800 AM8:09,Segher Boessenkool ,写道: > On Sat, Aug 01, 2020 at 07:02:07PM +0800, Jojo R wrote: > > +insn-generated-split-num = $(shell nproc) > > nproc isn't portable, is not the same on every system, and can lead to > a number of processes quadratic in the number of processors

[PATCH v5] genemit.c (main): split insn-emit.c for compiling parallelly

2020-08-27 Thread Jojo R
gcc/ChangeLog: * genemit.c (main): Print 'split line'. * Makefile.in (insn-emit.c): Define split count and file --- gcc/Makefile.in | 15 + gcc/genemit.c | 87 - 2 files changed, 64 insertions(+), 38 deletions(-) diff

Re: [PATCH] [AVX512] [PR87767] Optimize memory broadcast for constant vector under AVX512

2020-08-27 Thread Jakub Jelinek via Gcc-patches
On Thu, Aug 27, 2020 at 03:07:59PM +0200, Richard Biener wrote: > > Also, isn't the pass also useful for TARGET_AVX and above (but in that case > > only if it is a simple memory load)? Or are avx/avx2 broadcast slower than > > full vector loads? > > > > As Jeff wrote, I wonder if when

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread David Edelsohn via Gcc-patches
On Thu, Aug 27, 2020 at 9:21 AM Bill Schmidt wrote: > > Prior to P10, ELFv2 hasn't implemented nonlocal sibcalls. Now that we do, > we need to be sure that r12 is set up prior to such a call. > > Bootstrapped and tested on powerpc64le-unknown-linux-gnu with no > regressions. Is this okay for

Re: [PATCH] ia32: Fix alignment of _Atomic fields [PR65146]

2020-08-27 Thread H.J. Lu via Gcc-patches
On Thu, Aug 27, 2020 at 5:20 AM Uros Bizjak wrote: > > On Thu, Aug 27, 2020 at 10:35 AM Jakub Jelinek wrote: > > > > Hi! > > > > For _Atomic fields, lowering the alignment of long long or double etc. > > fields on ia32 is undesirable, because then one really can't perform atomic > > operations

Re: [Patch, fortran] PR96624 - A segment fault occurred when using the reshape function result to assign a variable

2020-08-27 Thread Tobias Burnus
Looks good to me. Thanks for the patch! Tobias On 8/27/20 8:17 AM, Paul Richard Thomas via Fortran wrote: Hi All, Here is another of Steve Kargl's patches. Before the patch is applied, the following code is generated: atmp.0.span = 4; atmp.0.data = 0B; atmp.0.offset = 0;

[Patch, fortran] PR96624 - A segment fault occurred when using the reshape function result to assign a variable

2020-08-27 Thread Paul Richard Thomas via Gcc-patches
Hi All, Here is another of Steve Kargl's patches. Before the patch is applied, the following code is generated: atmp.0.span = 4; atmp.0.data = 0B; atmp.0.offset = 0; (*(integer(kind=4)[0] * restrict) atmp.0.data)[0] = 1; (*(integer(kind=4)[0] * restrict) atmp.0.data)[1] = 2;

RE: [PATCH] hppa: Improve expansion of ashldi3 when !TARGET_64BIT

2020-08-27 Thread Roger Sayle
>On 2020-08-26 5:23 p.m., Roger Sayle wrote: >> These more accurate target rtx_costs are used by the >> gimple-ssa-strength-reduction.c (via a call to mult_by_coeff_cost) to >> decide whether applying strength reduction would be profitable. This test >> case, slsr-13.c, assumes that two

[PATCH] tree-optimization/96579 - another special-operands fix in reassoc

2020-08-27 Thread Richard Biener
This makes sure to put special-ops expanded rhs left where expression rewrite expects it. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. 2020-08-27 Richard Biener PR tree-optimization/96579 * tree-ssa-reassoc.c (linearize_expr_tree): If we expand rhs via

[PATCH] doc: add 'cd' command before 'make check-gcc' command in install.texi

2020-08-27 Thread Hu Jiangping
Hi, This patch add 'cd' command before 'make check-gcc' command when run the testsuite on selected tests. I think the implicit meaning of the original text is to execute the cd command to move to the gcc subdirectory of the object directory before executing the make command. However, due to the

Re: [PATCH] fix testcase gcc.target/aarch64/insv_1.c

2020-08-27 Thread Richard Sandiford
"Qian, Jianhua" writes: > Hi Richard > > I found that some instructions are using '#' before immediate value, > and others are not. For example > (define_insn "insv_imm" > [(set (zero_extract:GPI (match_operand:GPI 0 "register_operand" "+r") > (const_int 16) >

Re: [PATCH PR94442] [AArch64] Redundant ldp/stp instructions emitted at -O3

2020-08-27 Thread Richard Sandiford
xiezhiheng writes: > I made two separate patches for these two groups for review purposes. > > Note: Patch for min/max intrinsics should be applied before the patch for > rounding intrinsics > > Bootstrapped and tested on aarch64 Linux platform. Thanks, LGTM. Pushed to master. Richard

Re: [PATCH] rs6000, restrict bfloat convert intrinsic to Power 10. Fix BU_P10V macro definitions.

2020-08-27 Thread Carl Love via Gcc-patches
GCC maintainers: The following patch has been updated based on the comments from Will and Segher. The patch is a subset of the mainline commit: commit 07d456bb80a16405723c98c2ab74ccc2a5a23898 Author: Carl Love

Re: [PATCH] x86: Add -mbaseline-isas-only/target("baseline-isas-only")

2020-08-27 Thread Uros Bizjak via Gcc-patches
On Thu, Aug 27, 2020 at 4:45 PM H.J. Lu wrote: > > > > > > How about target("baseline-isas-only")? All CPUID functions are > > > > > > inlined. > > > > > > > > > > No, I don't think this is a good idea. Now consider the situation that > > > > > caller functions are compiled with e.g.

Re: [PATCH] libstdc++: Fix arithmetic bug in chrono::year_month::operator+

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 27/08/20 12:37 -0400, Patrick Palka wrote: On Thu, 27 Aug 2020, Jonathan Wakely wrote: On 27/08/20 11:29 -0400, Patrick Palka via Libstdc++ wrote: > This fixes the months-based addition for year_month when the > year_month's month component is zero. > > Successfully tested on

[PATCH] aarch64: Remove redundant mult patterns

2020-08-27 Thread Alex Coplan
Hello, Following on from the earlier patch to fix up the syntax for add/sub/adds/subs and friends with a sign/zero-extended operand [0], this patch removes the "mult" variants of these patterns which are all redundant. This patch removes the following patterns from the AArch64 backend:

[PATCH] libstdc++: Fix arithmetic bug in chrono::year_month::operator+

2020-08-27 Thread Patrick Palka via Gcc-patches
This fixes the months-based addition for year_month when the year_month's month component is zero. Successfully tested on x86_64-pc-linux-gnu, on the 'date' library's calendar and (now) on libcxx's calendar tests. Does this look OK to commit? libstdc++-v3/ChangeLog: *

Re: [PATCH] libstdc++: Fix arithmetic bug in chrono::year_month::operator+

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 27/08/20 11:29 -0400, Patrick Palka via Libstdc++ wrote: This fixes the months-based addition for year_month when the year_month's month component is zero. Successfully tested on x86_64-pc-linux-gnu, on the 'date' library's calendar and (now) on libcxx's calendar tests. Does this look OK to

Re: [PATCH v2] testsuite: Update some vect cases for partial vectors

2020-08-27 Thread Richard Sandiford
"Kewen.Lin" writes: > Hi Richard, > >>> Yeah, the comments were confusing, its intent is to check which targets >>> support partial vectors and which usage to be used. >>> >>> How about to update them like: >>> >>> "Return true if loops using partial vectors are supported and usage kind is >>>

[PATCH] avoid erroneous argument types when checking built-in signatures (PR c/96596)

2020-08-27 Thread Martin Sebor via Gcc-patches
The attached change has match_builtin_function_types() fail for erroneous argument types to prevent an ICE due to assuming they are necessarily valid. Martin PR c/96596 - ICE in match_builtin_function_types on a declaration of a built-in with invalid array argument gcc/c/ChangeLog: PR c/96596

Re: [PATCH 2/6] Implement a new partitioner for parallel compilation

2020-08-27 Thread Jan Hubicka
> When using the LTO infrastructure to compile files in parallel, we > can't simply use any of the LTO partitioner, once extra dependency > analysis is required to ensure that some nodes are correctly > partitioned together. > > Therefore, here we implement a new partitioner called >

Re: [PATCH 3/6] Implement fork-based parallelism engine

2020-08-27 Thread Jan Hubicka
> We also implemented a GNU Make Jobserver integration to this mechanism, > as implemented in jobserver.cc. This works as follows: > diff --git a/gcc/jobserver.cc b/gcc/jobserver.cc > new file mode 100644 > index 000..8cb374de86e > --- /dev/null > +++ b/gcc/jobserver.cc I wonder if this

Re: [PATCH 3/6] Implement fork-based parallelism engine

2020-08-27 Thread Jan Hubicka
> diff --git a/gcc/cgraph.c b/gcc/cgraph.c > index c0b45795059..22405098dc5 100644 > --- a/gcc/cgraph.c > +++ b/gcc/cgraph.c > @@ -226,6 +226,22 @@ cgraph_node::delete_function_version_by_decl (tree decl) >decl_node->remove (); > } > > +/* Release function dominator info if present. */ > +

Re: [PATCH 4/6] Add `+' for Jobserver Integration

2020-08-27 Thread Jan Hubicka
> On Thu, 20 Aug 2020, Giuliano Belinassi via Gcc-patches wrote: > > > libbacktrace/Makefile.in | 2 +- > > zlib/Makefile.in | 64 ++-- > > These directories use makefiles generated by automake. Rather than > modifying the generated files, you need to modify the sources

Re: [PATCH] libstdc++: Fix operator overload resolution for calendar types

2020-08-27 Thread Jonathan Wakely via Gcc-patches
On 25/08/20 15:47 -0400, Patrick Palka via Libstdc++ wrote: My original patch that implemented the calendar type operations failed to enforce a constraint on some of the addition/subtraction operator overloads that take a 'months' argument: Constraints: If the argument supplied by the caller

Re: [PATCH] libstdc++: Fix arithmetic bug in chrono::year_month::operator+

2020-08-27 Thread Patrick Palka via Gcc-patches
On Thu, 27 Aug 2020, Jonathan Wakely wrote: > On 27/08/20 11:29 -0400, Patrick Palka via Libstdc++ wrote: > > This fixes the months-based addition for year_month when the > > year_month's month component is zero. > > > > Successfully tested on x86_64-pc-linux-gnu, on the 'date' library's > >

[PATCH] hppa: Improve hppa_rtx_costs for shifts by constants.

2020-08-27 Thread Roger Sayle
Hi Dave (and Jeff), For your consideration, here's a patch that should fix the recent regression of gcc.dg/tree-ssa/slrt-13.c on hppa targets. This patch provides more accurate rtx_costs estimates for shifts by integer constants (which are cheaper than by a register amount). Fine tuning these is

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Segher Boessenkool
Hi! On Thu, Aug 27, 2020 at 08:21:34AM -0500, Bill Schmidt wrote: > + /* For ELFv2, r12 and CTR need to hold the function address > + for an indirect call. */ > + if (GET_CODE (func_desc) != SYMBOL_REF && DEFAULT_ABI == ABI_ELFv2) > +{ > + r12 = gen_rtx_REG (Pmode, 12); > +

Re: [PATCH] hppa: Improve hppa_rtx_costs for shifts by constants.

2020-08-27 Thread John David Anglin
Hi Roger, On 2020-08-27 12:42 p.m., Roger Sayle wrote: > I was wondering whether you could please "put this in the queue", and > reconfirm that PR middle-end/87256 remains resolved? > > > 2020-08-27 Roger Sayle > > gcc/ChangeLog > * config/pa/pa.c (hppa_rtx_costs) [ASHIFT, ASHIFTRT,

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Bill Schmidt via Gcc-patches
Hi! On 8/27/20 1:41 PM, Segher Boessenkool wrote: Hi! On Thu, Aug 27, 2020 at 08:21:34AM -0500, Bill Schmidt wrote: + /* For ELFv2, r12 and CTR need to hold the function address + for an indirect call. */ + if (GET_CODE (func_desc) != SYMBOL_REF && DEFAULT_ABI == ABI_ELFv2) +{ +

Re: [PATCH] modules: c++: Fix push_namespace ICE with modules

2020-08-27 Thread Nathan Sidwell
On 8/14/20 11:04 AM, Jeff Chapman wrote: Hello! Attached is a patch that fixes an ICE on the devel/c++-modules branch caused by a slot invalidation edge case in push_namespace. I just fell over this myself, reducing a testcase. your fix wasn;t quite right -- we were creating an empty slot

Re: [PATCH 3/6] Implement fork-based parallelism engine

2020-08-27 Thread Giuliano Belinassi via Gcc-patches
Hi, Honza. Thank you for your detailed review! On 08/27, Jan Hubicka wrote: > > diff --git a/gcc/cgraph.c b/gcc/cgraph.c > > index c0b45795059..22405098dc5 100644 > > --- a/gcc/cgraph.c > > +++ b/gcc/cgraph.c > > @@ -226,6 +226,22 @@ cgraph_node::delete_function_version_by_decl (tree > > decl)

Re: [PATCH] rs6000, restrict bfloat convert intrinsic to Power 10. Fix BU_P10V macro definitions.

2020-08-27 Thread Segher Boessenkool
On Thu, Aug 27, 2020 at 08:43:40AM -0700, Carl Love wrote: > 2020-08-26 Carl Love > * config/rs6000/rs6000-builtin.def: (BU_P10V_VSX_1) New builtin macro > expansion. > (XVCVBF16SPN, XVCVSPBF16): Replace macro expansion BU_VSX_1 with > BU_P10V_VSX_1. > *

Re: [PATCH] hppa: Improve hppa_rtx_costs for shifts by constants.

2020-08-27 Thread Jeff Law via Gcc-patches
On Thu, 2020-08-27 at 17:42 +0100, Roger Sayle wrote: > Hi Dave (and Jeff), > For your consideration, here's a patch that should fix the recent regression > of gcc.dg/tree-ssa/slrt-13.c on hppa targets. > > This patch provides more accurate rtx_costs estimates for shifts by > integer constants

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Alan Modra via Gcc-patches
On Thu, Aug 27, 2020 at 03:17:45PM -0500, Segher Boessenkool wrote: > On Thu, Aug 27, 2020 at 01:51:25PM -0500, Bill Schmidt wrote: > It not the copy that is unnecessary: the preventing it *here*, manually, > is what is unnecessary. Blame me for the original !rtx_equal_p in rs6000_call_aix that

[PATCH] c: Silently ignore pragma region [PR85487]

2020-08-27 Thread Austin Morton via Gcc-patches
#pragma region is a feature introduced by Microsoft in order to allow manual grouping and folding of code within Visual Studio. It is entirely ignored by the compiler. Clang has supported this feature since 2012 when in MSVC compatibility mode, and enabled it across the board 3 months ago. As

[PATCH 2/n] ipa: Add more intuitive ways of constructing ipa_call_context

2020-08-27 Thread Martin Jambor
Hi, this patch adds two static methods to ipa_call_context which construct and return the object in the two scenarios where we use them (what if an edge was inlined, what if a node wascloned) which saves callers a bit work and are more intuitive. The next step is to make

libgo patch committed: Remove middle dot from shell script

2020-08-27 Thread Ian Lance Taylor via Gcc-patches
This libgo patch by Maciej W. Rozycki removes a middle dot from the gotest shell script. There was a U+00B7 middle dot character, placed after "mips64p32le" in the target lists, which is now changed to a space. The U+00B7 character may not be considered whitespace by Bourne shell and any

Re: [PATCH 1/3] vec: add exact argument for various grow functions.

2020-08-27 Thread Martin Sebor via Gcc-patches
With --enable-valgrind-annotations the change to the member function signature in this patch triggers compilation errors during bootstrap: /src/gcc/trunk/gcc/ggc-common.c: In function ‘void gt_pch_save(FILE*)’: /src/gcc/trunk/gcc/ggc-common.c:509:33: error: no matching function for call to

Re: [PATCH] rs6000: Support ELFv2 sibcall for indirect calls [PR96787]

2020-08-27 Thread Segher Boessenkool
On Thu, Aug 27, 2020 at 01:51:25PM -0500, Bill Schmidt wrote: > >>+ /* For ELFv2, r12 and CTR need to hold the function address > >>+ for an indirect call. */ > >>+ if (GET_CODE (func_desc) != SYMBOL_REF && DEFAULT_ABI == ABI_ELFv2) > >>+{ > >>+ r12 = gen_rtx_REG (Pmode, 12); > >>+

Re: [PATCH v5] genemit.c (main): split insn-emit.c for compiling parallelly

2020-08-27 Thread Segher Boessenkool
Hi! On Thu, Aug 27, 2020 at 08:47:19PM +0800, Jojo R wrote: > +insn-emit-split-c = $(foreach o, $(shell for i in > {1..$(insn-generated-split-num)}; do echo $$i; done), insn-emit$(o).c) If you use a variable for the result of that "seq", this will be more readable / maintainable / etc. (Should

Re: [PATCH 1/4] PowerPC: Change cmove function return to bool

2020-08-27 Thread will schmidt via Gcc-patches
On Wed, 2020-08-26 at 22:43 -0400, Michael Meissner via Gcc-patches wrote: > PowerPC: Change cmove function return to bool. > > In doing the other work for adding ISA 3.1 128-bit minimum, maximum, and > conditional move support, I noticed the two functions that process conditional > moves return

Re: [PATCH 2/4] PowerPC: Rename functions for min, max, cmove

2020-08-27 Thread will schmidt via Gcc-patches
On Wed, 2020-08-26 at 22:44 -0400, Michael Meissner via Gcc-patches wrote: > PowerPC: Rename functions for min, max, cmove. > > This patch renames the functions that generate the ISA 3.0 C minimum, C > maximum, and conditional move instructions to use a better name than just > using > a _p9

Re: [PATCH 3/4] PowerPC: Add power10 xsmaxcqp/xsmincqp support

2020-08-27 Thread will schmidt via Gcc-patches
On Wed, 2020-08-26 at 22:45 -0400, Michael Meissner via Gcc-patches wrote: > PowerPC: Add power10 xsmaxcqp/xsmincqp support. > > This patch adds support for the ISA 3.1 (power10) IEEE 128-bit "C" minimum and > maximum functions. Because of the NaN differences, the built-in functions > will >

Re: [PATCH 4/4] PowerPC: Add power10 xscmp{eq,gt,ge}qp support

2020-08-27 Thread will schmidt via Gcc-patches
On Wed, 2020-08-26 at 22:46 -0400, Michael Meissner via Gcc-patches wrote: > PowerPC: Add power10 xscmp{eq,gt,ge}qp support. > > This patch adds the conditional move support. In adding the conditional move > support, the optimizers will be able to convert things like: > > a = (b > c) ? b

Re: [PATCH 2/6] Implement a new partitioner for parallel compilation

2020-08-27 Thread Giuliano Belinassi via Gcc-patches
Hi, Honza. Again, thank you for your detailed review! On 08/27, Jan Hubicka wrote: > > When using the LTO infrastructure to compile files in parallel, we > > can't simply use any of the LTO partitioner, once extra dependency > > analysis is required to ensure that some nodes are correctly > >

[committed] libstdc++: Make std::chrono::duration use reduced ratio for period

2020-08-27 Thread Jonathan Wakely via Gcc-patches
This implements the changes from P0548 "common_type and duration". That was a change for C++17, but as it corrects some issues introduced by DRs I'm also treating it as a DR and changing it for all modes from C++11 up. The main change is that duration::period no longer denotes P, but rather

[committed] hppa: Fix shadd-2.c scan assembler count

2020-08-27 Thread John David Anglin
Due to revisions to hppa_rtx_costs by Roger Sayle, we now have shift add instructions in the shadd-2.c test. Committed to trunk and gcc-10 branch. Dave Fix shadd-2.c scan assembler count. 2020-08-27 John David Anglin gcc/testsuite/ * gcc.target/hppa/shadd-2.c: Adjust times to 4.

Re: [PATCH] c++: Add __builtin_bit_cast to implement std::bit_cast [PR93121]

2020-08-27 Thread Iain Buclaw via Gcc-patches
Excerpts from Jakub Jelinek's message of August 27, 2020 12:06 pm: > On Fri, Jul 31, 2020 at 04:28:05PM -0400, Jason Merrill via Gcc-patches wrote: >> On 7/31/20 6:06 AM, Jakub Jelinek wrote: >> > On Fri, Jul 31, 2020 at 10:54:46AM +0100, Jonathan Wakely wrote: >> > > > Does the standard require

Re: [PATCH] avoid erroneous argument types when checking built-in signatures (PR c/96596)

2020-08-27 Thread Joseph Myers
On Thu, 27 Aug 2020, Martin Sebor via Gcc-patches wrote: > The attached change has match_builtin_function_types() fail > for erroneous argument types to prevent an ICE due to assuming > they are necessarily valid. OK. -- Joseph S. Myers jos...@codesourcery.com

[PATCH] ipa: Merge vectors describing argument values into one type

2020-08-27 Thread Martin Jambor
Hi, this large patch is a semi-mechanical change which aims to replace uses of separate vectors about known scalar values (usually called known_vals or known_csts), known aggregate values (known_aggs), known virtual call contexts (known_contexts) and known value ranges (known_value_ranges) with

RE: [PATCH] fix testcase gcc.target/aarch64/insv_1.c

2020-08-27 Thread Qian, Jianhua
Hi Iain Iain Sandoe wrote: >Richard Sandiford wrote: >> "Qian, Jianhua" writes: >>> Hi Richard >>>  >>> I found that some instructions are using '#' before immediate value, >>> and others are not. For example >>> (define_insn "insv_imm" >>> [(set (zero_extract:GPI (match_operand:GPI 0