Re: [PATCH] Add if-chain to switch conversion pass.

2020-10-07 Thread Richard Biener via Gcc-patches
On Tue, Oct 6, 2020 at 4:03 PM Martin Liška wrote: > > On 10/6/20 9:47 AM, Richard Biener wrote: > > But is it really extensible with the current implementation? I doubt so. > > I must agree with the statement. So let's make the pass properly. > I would need a help with the algorithm where I'm pl

Re: [PATCH] ipa-prop: Fix multiple-target speculation resolution

2020-10-07 Thread Martin Liška
On 10/1/20 7:39 PM, Martin Jambor wrote: OK for trunk? Approved. Martin

[PATCH] bootstrap/95582 - adjust what types we consider boolean for vectorization

2020-10-07 Thread Richard Biener
This excludes BOOLEAN_TYPE which are signed or have TYPE_PRECISION != 1 from being handled as VECTOR_BOOLEAN_TYPE_P. This fixes a bootstrap ICE with LTO and PGO in the Ada frontend. Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2020-10-07 Richard Biener PR

[PATCH] arc: Use separate predicated patterns for mpyd(u)

2020-10-07 Thread Claudiu Zissulescu via Gcc-patches
From: Claudiu Zissulescu The compiler can match mpyd.eq r0,r1,r0 as a predicated instruction, which is incorrect. The mpyd(u) instruction takes as input two 32-bit registers, returning into a double 64-bit even-odd register pair. For the predicated case, the ARC instruction decoder expects the d

Re: libgfortran caf API help needed: Fixing fnspec strings in trans-decl

2020-10-07 Thread Andre Vehreschild
Hi, I am confused. Given that on 2. Oct. 2020 you committed changes to the caf-fn_spec strings means: you don't need anymore help on this? - Andre On Wed, 30 Sep 2020 18:12:31 +0200 Jan Hubicka wrote: > Hi, > this patch contains basic fixup of the fnspec strings for caf, however I > am quite s

[PATCH, wwwdocs] gcc-11/changes: C++11 is now required to build GCC

2020-10-07 Thread David Malcolm via Gcc-patches
This summarizes GCC 11's change in build requirements from C++98 to C++11, for the release notes. I've put it in the Caveats immediately below the "The default mode for C++ is..." change hence the wording. I've based it on the change to gcc/doc/install.texi in the GCC source tree, which was 5329b

RE: [PATCH v2] arm: [MVE[ Add vqdmlashq intrinsics

2020-10-07 Thread Kyrylo Tkachov via Gcc-patches
Hi Christophe > -Original Message- > From: Gcc-patches On Behalf Of > Christophe Lyon via Gcc-patches > Sent: 06 October 2020 16:59 > To: gcc-patches@gcc.gnu.org > Subject: [PATCH v2] arm: [MVE[ Add vqdmlashq intrinsics > > This patch adds: > vqdmlashq_m_n_s16 > vqdmlashq_m_n_s32 > vqdml

[PATCH] IPA: merge profiles more sensitively

2020-10-07 Thread Martin Liška
During WPA we merge 2 functions where one is built with -O3 -fprofile-use while the other one uses -O0. We end up with: prevailing node: BitwiseCast (const double aFrom) { long unsigned int temp; long unsigned int D.4528; : BitwiseCast (aFrom_2(D), &temp); _4 = temp; temp ={v} {CLO

Re: [PATCH] IPA: merge profiles more sensitively

2020-10-07 Thread Martin Liška
On 10/7/20 1:18 PM, Martin Liška wrote: * ipa-utils.c (ipa_merge_profiles): I forgot to fill up the ChangeLog entry. Fixed. Martin

Re: [PATCH] IPA: merge profiles more sensitively

2020-10-07 Thread Martin Liška
On 10/7/20 1:18 PM, Martin Liška wrote: * ipa-utils.c (ipa_merge_profiles): I forgot to fill up the ChangeLog entry. Fixed. Martin >From a5d5d23175d336883972ebef66380cbc4f1b6d54 Mon Sep 17 00:00:00 2001 From: Martin Liska Date: Wed, 7 Oct 2020 12:30:27 +0200 Subject: [PATCH] IPA: merge p

Re: [PATCH] IPA: merge profiles more sensitively

2020-10-07 Thread Jan Hubicka
> During WPA we merge 2 functions where one is built with -O3 > -fprofile-use while the other one uses -O0. We end up with: > > prevailing node: > > BitwiseCast (const double aFrom) > { > long unsigned int temp; > long unsigned int D.4528; > >: > BitwiseCast (aFrom_2(D), &temp); > _4

Re: libgfortran caf API help needed: Fixing fnspec strings in trans-decl

2020-10-07 Thread Tobias Burnus
Hi Andre, On 10/7/20 12:21 PM, Andre Vehreschild wrote: I am confused. Given that on 2. Oct. 2020 you committed changes to the caf-fn_spec strings means: you don't need anymore help on this? Do you mean the change by the patch "Perforate fnspec attribute strings"? (https://gcc.gnu.org/g:762cca

Re: [PATCH] debug: Pass --gdwarf-N to assembler if fixed gas is detected during configure

2020-10-07 Thread Mark Wielaard
Hi, On Tue, 2020-10-06 at 16:57 -0400, Jason Merrill wrote: > All three of these patches (Jakub's, and your two) look good to me, > except that your add_filepath_AT_string patch is missing comments on > some of the new functions. I added documentation for the two new functions missing comments

Re: [PATCH] IPA: merge profiles more sensitively

2020-10-07 Thread Martin Liška
On 10/7/20 1:23 PM, Jan Hubicka wrote: During WPA we merge 2 functions where one is built with -O3 -fprofile-use while the other one uses -O0. We end up with: prevailing node: BitwiseCast (const double aFrom) { long unsigned int temp; long unsigned int D.4528; : BitwiseCast (aFrom

[committed] amdgcn: Use scalar instructions for addptrdi3

2020-10-07 Thread Andrew Stubbs
This patch adds an extra alternative to the existing addptrdi3 pattern. It permits safe 64-bit addition in scalar registers, as well as vector registers. This is especially useful because the result of addptr typically gets fed to instructions that expect the base address to be in a scalar regi

c++: Adding exception specs can changed dependentness

2020-10-07 Thread Nathan Sidwell
Making an exception variant can cause a non-dependent function type to become dependent (since c++17 eh-specs are part of the type). The same is (possibly?) true for adding a late return type. Fixed thusly. My upcoming local extern-decl changes have a test case that covers this (which was how I

Re: GCC 10 backports

2020-10-07 Thread Martin Liška
On 10/1/20 9:18 PM, Martin Liška wrote: I'm going to install the following 3 tested backports. Martin One more patch that I've tested. Martin >From d957172d0d43cdcf8dc098ae493c193d6678ecfd Mon Sep 17 00:00:00 2001 From: Martin Liska Date: Mon, 5 Oct 2020 18:03:08 +0200 Subject: [PATCH] lto:

c++: Rename DECL_BUILTIN_P to DECL_UNDECLARED_BUILTIN_P

2020-10-07 Thread Nathan Sidwell
I realized I'd misnamed DECL_BUILTIN_P, it's only true of compiler builtins unless and until the user declares them -- at that point they're real decls, and will have a location in the user's source. (BUILT_IN_FN and friends still work though). This renames them so future-me is not confused as t

c++: block-scope externs get an alias [PR95677,PR31775,PR95677]

2020-10-07 Thread Nathan Sidwell
This patch improves block-scope extern handling by always injecting a hidden copy into the enclosing namespace (or using a match already there). This hidden copy will be revealed if the user explicitly declares it later. We can get from the DECL_LOCAL_DECL_P local extern to the alias via DECL_LO

[committed] Add -fdiagnostics-path-format=separate-events to -fdiagnostics-plain-output

2020-10-07 Thread David Malcolm via Gcc-patches
The path-printing default of -fdiagnostics-path-format=inline-events interacted poorly with -fdiagnostics-plain-output, so it makes most sense to add -fdiagnostics-path-format=separate-events to -fdiagnostics-plain-output. Seen when adding an experimental analyzer plugin to gcc.dg/plugin.exp. Suc

[committed] analyzer: handle C++ argument numbers and "this" [PR97116]

2020-10-07 Thread David Malcolm via Gcc-patches
Successfully bootstrapped & regrtested on x86_64-pc-linux-gnu. Pushed to master as r11-3701-g2f7c50b7091c09d665aaf27173aacf34c9904e4c. gcc/analyzer/ChangeLog: PR analyzer/97116 * sm-malloc.cc (method_p): New. (describe_argument_index): New. (inform_nonnull_attribute

[PUSHED] Off by one final fix.

2020-10-07 Thread Andrew MacLeod via Gcc-patches
On 10/6/20 2:59 PM, Andrew MacLeod via Gcc-patches wrote: On 10/6/20 2:41 PM, Andreas Schwab wrote: On Okt 06 2020, Andrew MacLeod via Gcc-patches wrote: diff --git a/gcc/value-range.h b/gcc/value-range.h index 7031a823138..02a952bf81f 100644 --- a/gcc/value-range.h +++ b/gcc/value-range.h @@

Re: [PUSHED] Hybrid EVRP and testcases

2020-10-07 Thread Andrew MacLeod via Gcc-patches
On 10/7/20 2:10 AM, Richard Biener wrote: On Tue, Oct 6, 2020 at 7:06 PM Andrew MacLeod via Gcc-patches wrote: I have now checked in the hybrid EVRP pass. We have resolved all the issue we are aware of with a full Fedora build, but if any more issues arise, please let us know. (And Im sure you

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Jason Merrill via Gcc-patches
On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9/22/20 4:05 PM, Martin Sebor wrote: The rebased and retested patches are attached. On 9/21/20 3:17 PM, Martin Sebor wrote: Ping: https://gcc.gnu.org/pipermail/gcc-patches/2020-September/553906.html (I'm wo

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Martin Sebor via Gcc-patches
On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9/22/20 4:05 PM, Martin Sebor wrote: The rebased and retested patches are attached. On 9/21/20 3:17 PM, Martin Sebor wrote: Ping: https://gcc.gnu.org/pipermail/gcc-pa

Re: [PATCH] c++: ICE in dependent_type_p with constrained auto [PR97052]

2020-10-07 Thread Patrick Palka via Gcc-patches
On Tue, 6 Oct 2020, Jason Merrill wrote: > On 10/5/20 4:30 PM, Patrick Palka wrote: > > On Wed, 30 Sep 2020, Jason Merrill wrote: > > > > > On 9/29/20 5:01 PM, Patrick Palka wrote: > > > > This patch fixes an "unguarded" call to coerce_template_parms in > > > > build_standard_check: processing_te

Re: [PATCH] c++: Set the constraints of a class type sooner [PR96229]

2020-10-07 Thread Patrick Palka via Gcc-patches
On Tue, 29 Sep 2020, Patrick Palka wrote: > In the testcase below, during processing (at parse time) of Y's base > class X, convert_template_argument calls is_compatible_template_arg > to check if the template argument Y is no more constrained than the > parameter P. But at this point we haven't

[PATCH] tree-optimization/97307 - improve sinking of loads

2020-10-07 Thread Richard Biener
This improves the heuristics finding a sink location for loads that does not cross any store. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. 2020-10-07 Richard Biener PR tree-optimization/97307 * tree-ssa-sink.c (statement_sink_location): Change heuristic

Re: [PATCH] divmod: Match and expand DIVMOD even in some cases of constant divisor [PR97282]

2020-10-07 Thread Christophe Lyon via Gcc-patches
On Tue, 6 Oct 2020 at 11:42, Christophe Lyon wrote: > > Hi Jakub, > > On Tue, 6 Oct 2020 at 10:13, Richard Biener wrote: > > > > On Tue, 6 Oct 2020, Jakub Jelinek wrote: > > > > > Hi! > > > > > > As written in the comment, tree-ssa-math-opts.c wouldn't create a DIVMOD > > > ifn call for division

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Jason Merrill via Gcc-patches
On 10/7/20 10:42 AM, Martin Sebor wrote: On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9/22/20 4:05 PM, Martin Sebor wrote: The rebased and retested patches are attached. On 9/21/20 3:17 PM, Martin Sebor wrote: P

Re: [PUSHED] Hybrid EVRP and testcases

2020-10-07 Thread Aldy Hernandez via Gcc-patches
On 10/7/20 8:10 AM, Richard Biener wrote: > On Tue, Oct 6, 2020 at 7:06 PM Andrew MacLeod via Gcc-patches > wrote: >> >> I have now checked in the hybrid EVRP pass. >> >> We have resolved all the issue we are aware of with a full Fedora build, >> but if any more issues arise, please let us kno

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Martin Sebor via Gcc-patches
On 10/7/20 9:07 AM, Jason Merrill wrote: On 10/7/20 10:42 AM, Martin Sebor wrote: On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9/22/20 4:05 PM, Martin Sebor wrote: The rebased and retested patches are attached.

Re: [PUSHED] Hybrid EVRP and testcases

2020-10-07 Thread Andrew MacLeod via Gcc-patches
On 10/7/20 11:19 AM, Aldy Hernandez wrote: On 10/7/20 8:10 AM, Richard Biener wrote: > On Tue, Oct 6, 2020 at 7:06 PM Andrew MacLeod via Gcc-patches > wrote: >> >> I have now checked in the hybrid EVRP pass. >> >> We have resolved all the issue we are aware of with a full Fedora build, >> but

Re: [PATCH] libstdc++: Make ranges::construct_at constexpr-friendly [PR95788]

2020-10-07 Thread Patrick Palka via Gcc-patches
On Wed, 30 Sep 2020, Patrick Palka wrote: > This rewrites ranges::construct_at in terms of std::construct_at so > that we can piggy back on the compiler's existing support for > recognizing placement new within std::construct_at during constexpr > evaluation instead of having to additionally teach

Re: [patch] Add an if-exists-then-else spec function

2020-10-07 Thread Olivier Hainque
Hello Armin, > On 1 Oct 2020, at 18:20, Armin Brauns via Gcc-patches > wrote: > > > could you please make sure to update the documentation around > gcc/doc/invoke.texi:31574 accordingly? Oh, sure. > There's already a pending patch to make it more complete at > https://gcc.gnu.org/pipermail

fixing commits?

2020-10-07 Thread Andrew MacLeod via Gcc-patches
When I broke r11-3684 temporarily yesterday, it was fixed in the next commit. But it does mean that for anyone bisecting a problem, theres a broken commit. Is there a blessed way to fix that? or does it stay broken forever? All I need to do is change a single line in gimple-range.h... or do

[PATCH] libstdc++: Implement C++20 features for

2020-10-07 Thread Thomas Rodgers
From: Thomas Rodgers New ctors and ::view() accessor for - * basic_stingbuf * basic_istringstream * basic_ostringstream * basic_stringstreamm New ::get_allocator() accessor for basic_stringbuf. libstdc++-v3/ChangeLog: * acinclude.m4 (glibcxx_SUBDIRS): Add src/c++20. * co

Re: fixing commits?

2020-10-07 Thread Jeff Law via Gcc-patches
On 10/7/20 10:43 AM, Andrew MacLeod via Gcc-patches wrote: > When I broke r11-3684 temporarily yesterday, it was fixed in the next > commit. > > But it does mean that for anyone bisecting a problem, theres a broken > commit. > > Is there a blessed way to fix that? or does it stay broken forever?

Re: make sincos take type from intrinsic formal, not from result assignment

2020-10-07 Thread Alexandre Oliva
On Oct 6, 2020, Richard Biener wrote: > So how about that mathfn_type helper instead of hard-wring this logic > in sincos()? Like this? Regstrapped on x86_64-linux-gnu. Ok to install? I'm a little unhappy with the duplication of the CASE_MATHFN* sequence, that ought to be kept in sync, , and

[PATCH, rs6000] rename BU_P10_MISC_2 define to BU_P10_POWERPC64_MISC_2

2020-10-07 Thread will schmidt via Gcc-patches
Hi, Rename our BU_P10_MISC_2 built-in define macro to be BU_P10_POWERPC64_MISC_2. This more accurately reflects that the macro includes the RS6000_BTM_POWERPC64 entry that is not present in the other BU_P10_MISC macros, and matches the style we used for the P7 equivalent. Should be entirely

Re: [PATCH v2] c++: Verify 'this' of NS member functions in constexpr [PR97230]

2020-10-07 Thread Marek Polacek via Gcc-patches
On Tue, Oct 06, 2020 at 01:06:37AM -0400, Jason Merrill via Gcc-patches wrote: > On 10/1/20 1:08 PM, Marek Polacek wrote: > > @@ -2496,8 +2502,72 @@ cxx_eval_call_expression (const constexpr_ctx *ctx, > > tree t, > > new_obj = NULL_TREE; > > } > > } > > + /* Verify that the obj

libgo patch committed: Handle go1.10+ correctly in match.sh

2020-10-07 Thread Ian Lance Taylor via Gcc-patches
This libgo patch by Nikhil Benesch handles go1.10+ correctly in match.sh. The same issue will arise with Go 1.100, but that is a long ways off. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 33137fb1974e4b4aa5c82fbcecc2d9e2d854c394 diff --git a/gcc/go/gofron

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Jason Merrill via Gcc-patches
On 10/7/20 11:19 AM, Martin Sebor wrote: On 10/7/20 9:07 AM, Jason Merrill wrote: On 10/7/20 10:42 AM, Martin Sebor wrote: On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9/22/20 4:05 PM, Martin Sebor wrote: The r

Re: [PATCH] libstdc++: Implement C++20 features for

2020-10-07 Thread Jonathan Wakely via Gcc-patches
On 07/10/20 09:55 -0700, Thomas Rodgers wrote: From: Thomas Rodgers New ctors and ::view() accessor for - * basic_stingbuf * basic_istringstream * basic_ostringstream * basic_stringstreamm New ::get_allocator() accessor for basic_stringbuf. libstdc++-v3/ChangeLog: * acinclude.m4 (

[PATCH] MIPS/libphobos: Fix switchcontext.S assembly for MIPS I ISA

2020-10-07 Thread Maciej W. Rozycki
Correct MIPS I assembly build errors in switchcontext.S: .../libphobos/libdruntime/config/mips/switchcontext.S: Assembler messages: .../libphobos/libdruntime/config/mips/switchcontext.S:50: Error: opcode not supported on this processor: mips1 (mips1) `sdc1 $f20,(0*8-((6*8+4+(-6*8+4&7($sp)'

Re: [PATCH v2] c++: Verify 'this' of NS member functions in constexpr [PR97230]

2020-10-07 Thread Jason Merrill via Gcc-patches
On 10/7/20 2:48 PM, Marek Polacek wrote: On Tue, Oct 06, 2020 at 01:06:37AM -0400, Jason Merrill via Gcc-patches wrote: On 10/1/20 1:08 PM, Marek Polacek wrote: @@ -2496,8 +2502,72 @@ cxx_eval_call_expression (const constexpr_ctx *ctx, tree t, new_obj = NULL_TREE; }

Re: [PATCH] c++: Set the constraints of a class type sooner [PR96229]

2020-10-07 Thread Jason Merrill via Gcc-patches
On 9/29/20 10:26 AM, Patrick Palka wrote: In the testcase below, during processing (at parse time) of Y's base class X, convert_template_argument calls is_compatible_template_arg to check if the template argument Y is no more constrained than the parameter P. But at this point we haven't yet set

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Martin Sebor via Gcc-patches
On 10/7/20 1:28 PM, Jason Merrill wrote: On 10/7/20 11:19 AM, Martin Sebor wrote: On 10/7/20 9:07 AM, Jason Merrill wrote: On 10/7/20 10:42 AM, Martin Sebor wrote: On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/25/20 11:17 PM, Jason Merrill wrote: On 9

Re: [PATCH] c++: ICE in dependent_type_p with constrained auto [PR97052]

2020-10-07 Thread Jason Merrill via Gcc-patches
On 10/7/20 10:46 AM, Patrick Palka wrote: On Tue, 6 Oct 2020, Jason Merrill wrote: On 10/5/20 4:30 PM, Patrick Palka wrote: On Wed, 30 Sep 2020, Jason Merrill wrote: On 9/29/20 5:01 PM, Patrick Palka wrote: This patch fixes an "unguarded" call to coerce_template_parms in build_standard_chec

Re: [PING][PATCH] correct handling of indices into arrays with elements larger than 1 (PR c++/96511)

2020-10-07 Thread Jason Merrill via Gcc-patches
On 10/7/20 4:11 PM, Martin Sebor wrote: On 10/7/20 1:28 PM, Jason Merrill wrote: On 10/7/20 11:19 AM, Martin Sebor wrote: On 10/7/20 9:07 AM, Jason Merrill wrote: On 10/7/20 10:42 AM, Martin Sebor wrote: On 10/7/20 8:26 AM, Jason Merrill wrote: On 9/28/20 6:01 PM, Martin Sebor wrote: On 9/2

Re: [PATCH 1/5] RS6000 Add 128-bit Binary Integer sign extend operations

2020-10-07 Thread will schmidt via Gcc-patches
On Mon, 2020-10-05 at 11:51 -0700, Carl Love wrote: > Will, Segher: > > Patch 1, adds the 128-bit sign extension instruction support and > corresponding builtin support. > > I updated the change log per the comments from Will. > > Patch has been retested on Power 9 LE. > > Pet me know if it i

Re: [PATCH] c++: Fix P0846 (ADL and function templates) in template [PR97010]

2020-10-07 Thread Jason Merrill via Gcc-patches
On 9/10/20 6:15 PM, Marek Polacek wrote: To quickly recap, P0846 says that a name is also considered to refer to a template if it is an unqualified-id followed by a < and name lookup finds either one or more functions or finds nothing. In a template, when parsing a function call that has type-de

Re: [PATCH 2a/5] rs6000, vec_rlnm builtin fix arguments

2020-10-07 Thread will schmidt via Gcc-patches
On Mon, 2020-10-05 at 11:52 -0700, Carl Love wrote: > Will, Segher: > > > > The following changes were made from the previous version: > > Per Will's comments, I split the bug fix from patch 2 into a separate > patch. This patch is the bug fix for the vec_rlnm builtin. I recommend trying to k

libgo patch committed: Stop using -fno-section-anchors on AIX

2020-10-07 Thread Ian Lance Taylor via Gcc-patches
This patch by Clément Chigot changes the libgo configure script to stop using -fno-section-anchors on AIX. This option is no longer needed. There is no crash without it since at least gcc-9. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 45376dc0f426c0fc39c5

Re: [PATCH 2b/5] RS6000 add 128-bit Integer Operations

2020-10-07 Thread will schmidt via Gcc-patches
On Mon, 2020-10-05 at 11:52 -0700, Carl Love wrote: > Will and Segher: > > This is the rest of the second patch which adds the 128-bit integer > support for divide, modulo, shift, compare of 128-bit > integers instructions and builtin support. > > In the last round of changes, the flag for the 12

[PATCH] libstdc++: Implement C++20 features for

2020-10-07 Thread Thomas Rodgers
From: Thomas Rodgers New ctors and ::view() accessor for - * basic_stingbuf * basic_istringstream * basic_ostringstream * basic_stringstreamm New ::get_allocator() accessor for basic_stringbuf. libstdc++-v3/ChangeLog: * acinclude.m4 (glibcxx_SUBDIRS): Add src/c++20. * co

Re: Problem with static const objects and LTO

2020-10-07 Thread Jeff Law via Gcc-patches
On 9/17/20 1:03 PM, Jakub Jelinek wrote: [ ... Big snip, starting over ... ] I may have not explained things too well.  So I've put together a small example that folks can play with to show the underlying issue. There's a static library libfu.a.  In this static library we have a hunk of local

Re: Problem with static const objects and LTO

2020-10-07 Thread Jeff Law via Gcc-patches
Adding the testcase... On 10/7/20 4:08 PM, Jeff Law wrote: > On 9/17/20 1:03 PM, Jakub Jelinek wrote: > [ ... Big snip, starting over ... ] > > I may have not explained things too well.  So I've put together a small > example that folks can play with to show the underlying issue. > > > There's a s

testsuite: [arm] add -mthumb to arm/cortex-m55 tests

2020-10-07 Thread Christophe Lyon via Gcc-patches
The recently added arm/cortex-m55-* tests fail if the compiler does not default to thumb code. This patch adds -mthumb to the dg-additional-options, which fixes the problem in most cases. When running the tests with an incompatible -march= value, the tests also fail because it conflicts with -mcp

[PATCH 4/8] [RS6000] rs6000_rtx_costs tidy break/return

2020-10-07 Thread Alan Modra via Gcc-patches
Most cases use "return false" rather than breaking out of the switch. Do so in all cases. * config/rs6000/rs6000.c (rs6000_rtx_costs): Tidy break/return. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index bc5e51aa5ce..383d2901c9f 100644 --- a/gcc/config/rs6000/rs60

[PATCH 1/8] [RS6000] rs6000_rtx_costs comment

2020-10-07 Thread Alan Modra via Gcc-patches
This lays out the ground rules for following patches. * config/rs6000/rs6000.c (rs6000_rtx_costs): Expand comment. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index b58eeae2b98..97180bb3819 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @

[PATCH 5/8] [RS6000] rs6000_rtx_costs cost IOR

2020-10-07 Thread Alan Modra via Gcc-patches
* config/rs6000/rs6000.c (rotate_insert_cost): New function. (rs6000_rtx_costs): Cost IOR. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index 383d2901c9f..15a806fe307 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @@ -21206,6 +21206

[PATCH 3/8] [RS6000] rs6000_rtx_costs tidy AND

2020-10-07 Thread Alan Modra via Gcc-patches
* config/rs6000/rs6000.c (rs6000_rtx_costs): Tidy AND code. Don't avoid recursion on const_int shift count. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/rs6000.c index e870ba0039a..bc5e51aa5ce 100644 --- a/gcc/config/rs6000/rs6000.c +++ b/gcc/config/rs6000/rs6000.c @

[PATCH 7/8] [RS6000] rs6000_rtx_costs reduce cost for SETs

2020-10-07 Thread Alan Modra via Gcc-patches
The aim of this patch is to make rtx_costs for SETs closer to insn_cost for SETs. One visible effect on powerpc code is increased if-conversion. * config/rs6000/rs6000.c (rs6000_rtx_costs): Reduce cost of SET operands. diff --git a/gcc/config/rs6000/rs6000.c b/gcc/config/rs6000/r

[PATCH 2/8] [RS6000] rs6000_rtx_costs for AND

2020-10-07 Thread Alan Modra via Gcc-patches
The existing "case AND" in this function is not sufficient for optabs.c:avoid_expensive_constant usage, where the AND is passed in outer_code. We'd like to cost AND of rs6000_is_valid_and_mask or rs6000_is_valid_2insn_and variety there, so that those masks aren't seen as expensive (ie. better to l

[PATCH 0/8] [RS6000] rs6000_rtx_costs V2

2020-10-07 Thread Alan Modra via Gcc-patches
This is a revised version of the patch series posted at https://gcc.gnu.org/pipermail/gcc-patches/2020-September/553919.html Patch 8/8 in particular changes rather a lot more than the original !speed changes. Bootstrapped and regression tested powerpc64le-linux and powerpc64-linux biarch. Alan M

[PATCH 6/8] [RS6000] rs6000_rtx_costs multi-insn constants

2020-10-07 Thread Alan Modra via Gcc-patches
This small patch to rs6000_rtx_costs considerably improves code generated for large constants in 64-bit code, teaching gcc that it is better to load a constant from memory than to generate a sequence of up to five dependent instructions. Note that the rs6000 backend does generate large constants a

[PATCH 8/8] [RS6000] rs6000_rtx_costs for !speed

2020-10-07 Thread Alan Modra via Gcc-patches
When optimizing for size we shouldn't be using metrics based on speed or vice-versa. rtlanal.c:get_full_rtx_cost wants both speed and size metric from rs6000_rtx_costs independent of the global optimize_size. Note that the patch changes param_simultaneous_prefetches, param_l1_cache_size, param_l1

Re: Problem with static const objects and LTO

2020-10-07 Thread H.J. Lu via Gcc-patches
On Wed, Oct 7, 2020 at 3:09 PM Jeff Law via Gcc-patches wrote: > > Adding the testcase... > > On 10/7/20 4:08 PM, Jeff Law wrote: > > On 9/17/20 1:03 PM, Jakub Jelinek wrote: > > [ ... Big snip, starting over ... ] > > > > I may have not explained things too well. So I've put together a small > >

[committed] libstdc++: Fix non-reserved names in headers

2020-10-07 Thread Jonathan Wakely via Gcc-patches
My recent changes to std::exception_ptr moved some members to be inline in the header but didn't replace the variable names with reserved names. The "tmp" variable must be fixed. The "other" parameter is actually a reserved name because of std::allocator::rebind::other but should be fixed anyway.

Re: Problem with static const objects and LTO

2020-10-07 Thread Jeff Law via Gcc-patches
On 10/7/20 5:12 PM, H.J. Lu wrote: > On Wed, Oct 7, 2020 at 3:09 PM Jeff Law via Gcc-patches > wrote: >> Adding the testcase... >> >> On 10/7/20 4:08 PM, Jeff Law wrote: >>> On 9/17/20 1:03 PM, Jakub Jelinek wrote: >>> [ ... Big snip, starting over ... ] >>> >>> I may have not explained things t

[committed] libstdc++: Fix divide by zero in default template argument

2020-10-07 Thread Jonathan Wakely via Gcc-patches
libstdc++-v3/ChangeLog: * include/bits/random.h (__detail::_Mod): Avoid divide by zero. * testsuite/26_numerics/random/linear_congruential_engine/operators/call.cc: New test. Tested powerpc64le-linux. Committed to trunk. commit 6ae17a3b6835b30102607d45ac89c7a668e2c8d4 Au

Re: [PATCH] rs6000: Fix extraneous characters in the documentation

2020-10-07 Thread Segher Boessenkool
Hi! On Wed, Aug 19, 2020 at 04:03:31PM -0300, Tulio Magno Quites Machado Filho via Gcc-patches wrote: > Replace them with a whitespace in order to avoid artifacts in the HTML > document. Multiple whitespaces in texinfo are supposed to work correctly, and are good to have for various reasons (mor

Re: [PATCH, rs6000] rename BU_P10_MISC_2 define to BU_P10_POWERPC64_MISC_2

2020-10-07 Thread Segher Boessenkool
Hi! On Wed, Oct 07, 2020 at 12:44:04PM -0500, will schmidt wrote: > Rename our BU_P10_MISC_2 built-in define macro to be > BU_P10_POWERPC64_MISC_2. This more accurately reflects > that the macro includes the RS6000_BTM_POWERPC64 entry > that is not present in the other BU_P10_MISC macros, > a

[PATCH] libstdc++: Implement C++20 features for

2020-10-07 Thread Thomas Rodgers
From: Thomas Rodgers New ctors and ::view() accessor for - * basic_stingbuf * basic_istringstream * basic_ostringstream * basic_stringstreamm New ::get_allocator() accessor for basic_stringbuf. libstdc++-v3/ChangeLog: * acinclude.m4 (glibcxx_SUBDIRS): Add src/c++20. * co

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

2020-10-07 Thread Jojo R
Ping …... Jojo 在 2020年9月27日 +0800 AM10:34,Jojo R ,写道: > Hi, > > Has this patch been merged ? > > Jojo > 在 2020年9月15日 +0800 PM5:16,Jojo R ,写道: > > gcc/ChangeLog: > > > > * genemit.c (main): Print 'split line'. > > * Makefile.in (insn-emit.c): Define split count and file > > > > --- > > gcc/Ma

Attempt to resolve PR83562

2020-10-07 Thread Liu Hao via Gcc-patches
[Please CC me as I am not subscribed to this list.] [This patch is only a draft and has not been tested at all.] Some details have been discussed in [1]. mingw-w64 has got an implementation [2] [3] for static libraries, but it takes a destructor using the `__thiscall` convention. As both functio

Re: [PATCH 1/9] PowerPC: Map long double built-in functions if IEEE 128-bit long double.

2020-10-07 Thread Michael Meissner via Gcc-patches
On Thu, Oct 01, 2020 at 11:05:04PM +, Joseph Myers wrote: > On Thu, 24 Sep 2020, Michael Meissner via Gcc-patches wrote: > > > To map the math functions, typically this patch changes l to > > f128. > > However there are some exceptions that are handled with this patch. > > glibc 2.32 added _