Re: [C++ PATCH] c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.

2019-11-28 Thread Jason Merrill
On Thu, Nov 28, 2019 at 10:28 PM Marek Polacek wrote: > On Wed, Nov 27, 2019 at 10:47:58PM -0500, Jason Merrill wrote: > > On 11/27/19 6:35 PM, Marek Polacek wrote: > > > On Wed, Nov 27, 2019 at 04:47:01PM -0500, Jason Merrill wrote: > > > > On 11/27/19 2:36 PM, Marek Polacek wrote: > > > > > On

Re: [C++ PATCH] c++/91353 - P1331R2: Allow trivial default init in constexpr contexts.

2019-11-28 Thread Marek Polacek
On Wed, Nov 27, 2019 at 10:47:58PM -0500, Jason Merrill wrote: > On 11/27/19 6:35 PM, Marek Polacek wrote: > > On Wed, Nov 27, 2019 at 04:47:01PM -0500, Jason Merrill wrote: > > > On 11/27/19 2:36 PM, Marek Polacek wrote: > > > > On Sun, Nov 24, 2019 at 12:24:48PM -0500, Jason Merrill wrote: > > >

Handle C2x attributes in Objective-C

2019-11-28 Thread Joseph Myers
When adding the initial support for C2x attributes, I deferred the unbounded lookahead support required to support such attributes in Objective-C (except for the changes to string literal handling, which were the riskier piece of preparation for such lookahead support). This patch adds that

[PATCH] rs6000: Fix formatting of *mov{si,di}_internal.*

2019-11-28 Thread Segher Boessenkool
This implements the improvements I asked for. Committing. Segher 2019-11-28 Segher Boessenkool * config/rs6000/rs6000.md (*movsi_internal1): Fix formatting. Improve formatting. (*movdi_internal64): Ditto. --- gcc/config/rs6000/rs6000.md | 192

Re: [Patch, gcc-wwdocs] Update to Fortran changes

2019-11-28 Thread Gerald Pfeifer
On Tue, 26 Nov 2019, Mark Eggleston wrote: > Second attempt this time with attachment. >From f884924877ba84578e75bd16cb127bab33eb5ee6 Mon Sep 17 00:00:00 2001 From: Mark Eggleston Date: Tue, 26 Nov 2019 10:12:44 + Subject: [PATCH] Update Fortran changes + +A blank format item

[PATCH] rs6000: Use memory_operand for all simple {l,st}*brx instructions

2019-11-28 Thread Segher Boessenkool
We run fwprop before combine, very early even in the case of fwprop1; and fwprop1 will change memory addressing to what it considers cheaper. After the "common" change, it now changes the indexed store instruction in the testcase to be to a constant address. But that is not an improvement at all:

Re: [PATCH] Trivial patch to allow bootstrap on MacOS

2019-11-28 Thread Keller, Rainer
Dear Iain, thanks for the quick reply. I wasn’t aware of the ticket 79885. Yes, the intent is to use the same sysroot for build & run. Hmm, the —with-sysroot is from gcc/configure option — not from the main configure. Not wanting to turn this into a bug-report, but… using —with-sysroot instead

RE: [PATCH][GCC][SLP][testsuite] Turn off vect-epilogue-nomask for slp-rect-3

2019-11-28 Thread Tamar Christina
Hi Richi, > > > > This patch turns off vect-epilogue-nomask for slp-reduc-3 as it seems > > that the epiloque in this loop is vectorizable using SLP and smaller > > VF. Since this test expects there to be no SLP vectorization at all > > the testcase then fails for arm targets. > > Actually we

[PATCH] [libiberty] Fix read buffer overflow in split_directories

2019-11-28 Thread Tim Rühsen
An empty name param leads to read buffer overflow in function split_directories. * libiberty/make-relative-prefix.c (split_directories): Return early on empty name. --- libiberty/ChangeLog | 7 +++ libiberty/make-relative-prefix.c | 3 +++ 2 files changed, 10 insertions(+)

Re: [PATCH v2] Add `--with-install-sysroot=' configuration option

2019-11-28 Thread Joseph Myers
On Thu, 28 Nov 2019, Maciej W. Rozycki wrote: > > > > Rather, it's a suffix (as in SYSROOT_SUFFIX_SPEC, no command-line option > > to print it), > > Do you mean that there's no option to print SYSROOT_SUFFIX_SPEC on its > own or that no option prints it as a path component? If the latter,

Re: [PATCH v2] Add `--with-install-sysroot=' configuration option

2019-11-28 Thread Maciej W. Rozycki
On Fri, 22 Nov 2019, Joseph Myers wrote: > > As I recall the MIPS sysroot setup (please correct me if I got something > > wrong here) was like: > > Yes, that's the sort of layout you get with sysroot suffixes. See > gcc/config/mips/{st.h,t-st} for an example. Thanks for the pointer. > >

Re: [PATCH 2/4] The main m68k cc0 conversion

2019-11-28 Thread Bernd Schmidt
On 11/28/19 8:53 PM, Gunther Nikl wrote:> Bernd Schmidt : >> On 11/23/19 9:53 PM, Bernd Schmidt wrote: >> move.w %a4,%d0 >> - tst.b %d0 >> - jeq .L352 >> + jeq .L353 >> >> And the reason - that's a movqi using move.w. > > Can this problem also happen on older

Making things a bit easier (was: [Patch, gcc-wwdocs] Update to Fortran changes)

2019-11-28 Thread Gerald Pfeifer
On Tue, 26 Nov 2019, Mark Eggleston wrote: > I've check the changes with W3 validator. There are no problems related > to my changes, however, it does object to the lack of character encoding > in the file. My knowledge of HTML is limited, so don't know how to fix > that. Let me take this as

Re: [PATCH 2/4] The main m68k cc0 conversion

2019-11-28 Thread Gunther Nikl
Bernd Schmidt : > On 11/23/19 9:53 PM, Bernd Schmidt wrote: > > I'll spend a few more days trying to see if I can do something > > about the bootstrap failure Mikael saw (currently trying to do a > > two-stage cross build rather than a really slow bootstrap). > > Whew, I think I have it. One

[wwwdocs] Push down into individual HTML files.

2019-11-28 Thread Gerald Pfeifer
This will make it easier to edit/validate pages and reduces our dependency on preprocessing yet a bit more on top of the change series I worked on last fall. This change was triggered by feedback from Mark Eggleston; thank you! Committed. Gerald commit 34bfcf1947c44e458af1b7ba201f25071c4d80a5

[Darwin, X86, testsuite, committed] Update tests for common section use.

2019-11-28 Thread Iain Sandoe
The switch to default of no-common means that we no longer indirect the accesses to 'xxx' in this test. Adjust the scan- assembler tests to reflect this. tested on x86_64-darwin16, x86_64-linux-gnu applied to mainline, thanks Iain gcc/testsuite/ChangeLog: 2019-11-28 Iain Sandoe *

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Richard Biener
On Thu, Nov 28, 2019 at 4:04 PM Joseph Myers wrote: > > On Thu, 28 Nov 2019, Julian Brown wrote: > > > Unlike e.g. the _FloatN types, when decimal floating-point types are > > enabled, common tree nodes are created for each float type size (e.g. > > dfloat32_type_node) and also a pointer to each

Re: [PATCH][GCC][SLP][testsuite] Turn off vect-epilogue-nomask for slp-rect-3

2019-11-28 Thread Richard Biener
On Thu, 28 Nov 2019, Tamar Christina wrote: > Hi All, > > This patch turns off vect-epilogue-nomask for slp-reduc-3 as it seems that > the epiloque in this loop is vectorizable using SLP and smaller VF. Since > this > test expects there to be no SLP vectorization at all the testcase then fails

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Joseph Myers
On Thu, 28 Nov 2019, Julian Brown wrote: > On Thu, 28 Nov 2019 15:04:05 + > Joseph Myers wrote: > > > On Thu, 28 Nov 2019, Julian Brown wrote: > > > > > Unlike e.g. the _FloatN types, when decimal floating-point types are > > > enabled, common tree nodes are created for each float type

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Julian Brown
On Thu, 28 Nov 2019 15:04:05 + Joseph Myers wrote: > On Thu, 28 Nov 2019, Julian Brown wrote: > > > Unlike e.g. the _FloatN types, when decimal floating-point types are > > enabled, common tree nodes are created for each float type size > > (e.g. dfloat32_type_node) and also a pointer to

Fix leftover optimize checks

2019-11-28 Thread Jan Hubicka
Hi, these optimize flag checks was forgotten after the params conversion. Comitted as obvious. Honza * ipa-inline.c (want_early_inline_function_p): Remove leftover optimize checks. Index: ipa-inline.c === ---

Add sanity checking for profile counter compatibility

2019-11-28 Thread Jan Hubicka
Hi, this patch adds sanity checks with uncovered all the latent bugs I fixed today. I will add similar checking to cfg profile, too, and also few unit tests. Bootstrapped/regtested x86_64-linux, plan to commit it shortly. * profile-count.c (profile_count::to_cgraph_frequency,

[PATCH][GCC][SLP][testsuite] Turn off vect-epilogue-nomask for slp-rect-3

2019-11-28 Thread Tamar Christina
Hi All, This patch turns off vect-epilogue-nomask for slp-reduc-3 as it seems that the epiloque in this loop is vectorizable using SLP and smaller VF. Since this test expects there to be no SLP vectorization at all the testcase then fails for arm targets. Regtested on arm-none-eabi and no

Minor fix for profile_count::combine_with_ipa_count

2019-11-28 Thread Jan Hubicka
Hi, this patch makes combine_with_ipa_count to return uninitialized when called on uninitialized count. Previously in some cases it returned IPA, which is probably not a big deal but it should not do that for consistency. Bootstrapped/regtested x86_64-linux, comitted. * profile-count.c

Re: [Patch][Fortran] OpenACC – permit common blocks in some clauses

2019-11-28 Thread Thomas Schwinge
Hi Tobias! On 2019-11-26T15:02:34+0100, Tobias Burnus wrote: > I now played also around common blocks with "!$acc declare > device_resident (/block/)". [See attached test-case diff.] If you'd like to, please commit that, to document the status quo. (I have not reviewed.) There are several

Prevent inconsistent profiles to be created in inline_transform

2019-11-28 Thread Jan Hubicka
Hi, ipa-inline-transforms first applies edge redirection and then scales profile. For some reason cgraph_edge::redirect_call_stmt_to_callee copies bb's count into callgraph edge count. This leads to inconsistency because cfg profile is before scaling at this point. Fixed thus.

Re: [Patch][Fortran] OpenACC – permit common blocks in some clauses

2019-11-28 Thread Thomas Schwinge
Hi Tobias! On 2019-11-25T15:02:16+0100, Tobias Burnus wrote: > sorry for the belated reply. Eh, no worries -- I'm way more behind on things... > On 11/11/19 10:39 AM, Thomas Schwinge wrote: >> By the way, do you know what's the status is for Fortran common blocks in >> OpenMP: supported vs.

Re: [patch,fortran] PR90374 add e0 zero width exponent support

2019-11-28 Thread Steve Kargl
On Thu, Nov 28, 2019 at 08:05:31AM -0800, Jerry DeLisle wrote: > On 11/28/19 7:53 AM, Steve Kargl wrote: > > On Thu, Nov 28, 2019 at 07:45:25AM -0800, Jerry DeLisle wrote: > >> +if (u == FMT_ZERO) > >> + { > >> +if (!gfc_notify_std (GFC_STD_F2018, > >> +

Re: [patch,fortran] PR90374 add e0 zero width exponent support

2019-11-28 Thread Jerry DeLisle
On 11/28/19 7:53 AM, Steve Kargl wrote: On Thu, Nov 28, 2019 at 07:45:25AM -0800, Jerry DeLisle wrote: + if (u == FMT_ZERO) + { + if (!gfc_notify_std (GFC_STD_F2018, + "Positive exponent width required in " +

Re: [patch,fortran] PR90374 add e0 zero width exponent support

2019-11-28 Thread Steve Kargl
On Thu, Nov 28, 2019 at 07:45:25AM -0800, Jerry DeLisle wrote: > + if (u == FMT_ZERO) > + { > + if (!gfc_notify_std (GFC_STD_F2018, > + "Positive exponent width required in " > + "format string

Fix profile_count::max and profile_count::apply_scale WRT counts of different types

2019-11-28 Thread Jan Hubicka
Hi, profile_count::max and profile_count::apply_scale and two functions that needs to work with pairs of counters from different functions (first is used to obtain overall statistics used by e.g. inliner and profile_count::apply_scale is used to scale function profile when inline clones are

[patch,fortran] PR90374 add e0 zero width exponent support

2019-11-28 Thread Jerry DeLisle
Hi all, The attached patch implements the last piece of this which enables the zero width exponent, giving a processor dependent width. Regression tested on x86_64-pc-linux-gnu. I don't think it is very intrusive and I updated the test case. OK for trunk? Regards, Jerry 2019-11-27

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Segher Boessenkool
Hi Joseph, On Thu, Nov 28, 2019 at 03:04:05PM +, Joseph Myers wrote: > On Thu, 28 Nov 2019, Julian Brown wrote: > > Unlike e.g. the _FloatN types, when decimal floating-point types are > > enabled, common tree nodes are created for each float type size (e.g. > > dfloat32_type_node) and also a

Re: [PATCH] Trivial patch to allow bootstrap on MacOS

2019-11-28 Thread Iain Sandoe
Hello again Rainer, Iain Sandoe wrote: GMP however is installed elsewhere (by Homebrew, MacPorts etc), so ignore any -nostdinc it also works to symlink the sources for gmp, mpfr, mpc (and isl, if you use it) into the source tree - those then get boostrapped along with the compiler and

Re: [PATCH] cgraph: ifunc resolvers cannot be made local (PR 92697)

2019-11-28 Thread Jan Hubicka
> Hi, > > In the attached testcase, IPA-SRA thinks that an ifunc resolver > (meanwhile IPA-split into two functions) function can be changed and so > goes ahead. The cgraph machinery then however throws away the new clone > of the caller instead of the "old" caller and inliner inlines the clone

[PATCH] cgraph: ifunc resolvers cannot be made local (PR 92697)

2019-11-28 Thread Martin Jambor
Hi, In the attached testcase, IPA-SRA thinks that an ifunc resolver (meanwhile IPA-split into two functions) function can be changed and so goes ahead. The cgraph machinery then however throws away the new clone of the caller instead of the "old" caller and inliner inlines the clone of the

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Thomas Schwinge
Hi Julian! On 2019-11-28T14:24:02+, Julian Brown wrote: > As mentioned in PR91985, offloading compilation is broken at present > because of an issue with LTO streaming. With thanks to Joseph for > hints, here's a solution. > > Unlike e.g. the _FloatN types, when decimal floating-point types

Re: [PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Joseph Myers
On Thu, 28 Nov 2019, Julian Brown wrote: > Unlike e.g. the _FloatN types, when decimal floating-point types are > enabled, common tree nodes are created for each float type size (e.g. > dfloat32_type_node) and also a pointer to each type is created > (e.g. dfloat32_ptr_type_node).

Fix profile adjusments while cloning

2019-11-28 Thread Jan Hubicka
Hi, this patch fixes profile updates while cloning. When new clone is produced its global profile is subtracted from the original function. If the original function profile drops to 0 we want to switch from global profiles to global0 profiles which is implemented by

[PATCH] Fix decimal floating-point LTO streaming for offloading compilation

2019-11-28 Thread Julian Brown
As mentioned in PR91985, offloading compilation is broken at present because of an issue with LTO streaming. With thanks to Joseph for hints, here's a solution. Unlike e.g. the _FloatN types, when decimal floating-point types are enabled, common tree nodes are created for each float type size

Fix scaling of profiles in ipa_merge_profiles

2019-11-28 Thread Jan Hubicka
Hi this patch fixes two problems in ipa_merge_profiles. First we allow cfg profile to diverge from cgraph profile and prior summing cfg profiles we must compensate for this change. Second the function is trying to preserve as much information as possible (for example to handle cases one function

Re: Prevent all uses of DFP when unsupported (PR c/91985)

2019-11-28 Thread Thomas Schwinge
Hi! So, testing just finished, and indeed: On 2019-11-27T22:33:25+, Joseph Myers wrote: > On Wed, 27 Nov 2019, Thomas Schwinge wrote: > >> If I turn that conditional cited above into 'if (1)', then nvptx >> offloading testing seems to return to normality, but I have not yet >> assessed

Re: [PATCH] [dlang/phobos] S/390: Fix PR91628

2019-11-28 Thread Robin Dapp
> OK from me, what about earlier comments of using __asm__ in a C > source file? > > I wouldn't really object to converting all .S sources (infact I can > do this myself) if it meant slightly better portability. Adding to yesterday's message: feel free to apply the current version if it's OK.

Fix scaling in update_profiling_info

2019-11-28 Thread Jan Hubicka
Hi, This patch fixes scaling in update_profiling_info. My understanding is that there is orig_node and new_node which have some counts that comes from cloning but real distribution of execution counts is determined by counting callers to new clone. This is new_sum. We thus want to scale

[PATCH] Elide return during inlining when possible

2019-11-28 Thread Richard Biener
Also from investigating the abstraction penalty in PR92645 I noticed we create pointless stmts to copy the return value to the result decl at the return. That's not needed if the call doesn't have a LHS. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk. Richard.

[PATCH] More PR92645, teach vector CTOR optimization about more conversions

2019-11-28 Thread Richard Biener
The following fixes the reduced testcase in PR92645 (but not the original C++ one because of abstraction - digging into that). It teaches simplify_vector_constructor to consider all kinds of conversions, even those changing the element size. Since we now have truncate and extend optabs for

Re: [PATCH] PR90838: Support ctz idioms

2019-11-28 Thread Wilco Dijkstra
ping Hi Richard, > Uh. Well. I think that the gimple-match-head.c hunk isn't something we > want. Instead, > since this optimizes a memory access, the handling should move > to tree-ssa-forwprop.c where you _may_ use a (match ...) > match.pd pattern to do the (rshift (mult (bit_and (negate

[committed] [testsuite][arm] Force use of -mfloat-abi=softfp in asm-flag-4.c

2019-11-28 Thread Christophe Lyon
Hi, I've just committed the patch below as r278804. It avoids annoying failures on asm-flag-4.c when the compiler is configured --with-float=hard. 2019-11-28 Christophe Lyon * gcc.target/arm/asm-flag-4.c: Use -mfloat-abi=softfp. Index: gcc/testsuite/gcc.target/arm/asm-flag-4.c

Re: Ping: [PATCH] Add explicit description for -finline

2019-11-28 Thread Richard Biener
On Thu, 28 Nov 2019, luoxhu wrote: > > > On 2019/11/4 11:42, luoxhu wrote: > > On 2019/11/2 00:23, Joseph Myers wrote: > >> On Thu, 31 Oct 2019, Xiong Hu Luo wrote: > >> > >>> +@code{-finline} enables inlining of function declared \"inline\". > >>> +@code{-finline} is enabled at levels -O1,

Re: [PATCH] Trivial patch to allow bootstrap on MacOS

2019-11-28 Thread Iain Sandoe
Hello Rainer, thanks for the patch, but I think it’s only a work-around to part of the problem and there are alternate strategies for the “usual case” on MacOS/Darwin. Keller, Rainer wrote: the following is required to allow bootstrap in libcc1 during stage3 on MacOS Catalina (10.15).

Re: [PATCH] Fix ICE in tree-ssa-strlen.c (PR tree-optimization/92691)

2019-11-28 Thread Richard Biener
On Thu, 28 Nov 2019, Jakub Jelinek wrote: > Hi! > > The various routines propagate to the caller whether > if (check_and_optimize_stmt (, _eh, evrp.get_vr_values ())) > gsi_next (); > should do gsi_next or not (return false if e.g. gsi_remove is done, thus > gsi is already moved to

Handle correctly global0 and global counters in profile_count::to_sreal_scale

2019-11-28 Thread Jan Hubicka
Hi, This patch fixes problem in profile_count::to_sreal_scale. We our porfile counters can be function local, global (ipa) or function local but globally 0. The last is used to hold static estimates for functions executed 0 times in profile. Now only one 64bit value is stored and if we compute

Re: [PATCH, GCC, AArch64] Fix PR88398 for AArch64

2019-11-28 Thread Richard Biener
On Wed, Nov 27, 2019 at 2:17 PM Wilco Dijkstra wrote: > > Hi Richard, > > >> Yes so it does the insane "fully unrolled trailing loop before the unrolled > >> loop" thing. One always does the trailing loop last (and typically as an > >> actual loop of course) and then the code ends up much faster,

[PATCH] Trivial patch to allow bootstrap on MacOS

2019-11-28 Thread Keller, Rainer
Dear all, the following is required to allow bootstrap in libcc1 during stage3 on MacOS Catalina (10.15). libcc1 invokes g++ with —nostdinc++ MacOS Catalina doesn’t provide /usr/include anymore, instead one builds with: OSX_SDK_VERSION=`xcodebuild -showsdks | grep 'macOS\ 10' | cut -f2- -d'-' |