Re: [PATCH] C/C++: add fix-it hints for missing '&' and '*' (PR c++/87850)

2018-11-09 Thread Eric Gallager
On 11/9/18, David Malcolm wrote: > This patch adds a fix-it hint to various pointer-vs-non-pointer > diagnostics, suggesting the addition of a leading '&' or '*'. > > For example, note the ampersand fix-it hint in the following: > > demo.c:5:22: error: invalid conversion from 'pthread_key_t' {aka

Re: [PATCH] x86: Optimize VFIXUPIMM* patterns with multiple-alternative constraints

2018-11-09 Thread Terry Guo
On Fri, Nov 9, 2018 at 6:05 PM Uros Bizjak wrote: > > On Fri, Nov 9, 2018 at 10:54 AM Wei Xiao wrote: > > > > Hi Uros > > > > Thanks for the remarks! > > I improve the patch as attached to address the issues you mentioned: > > 1. No changes to substs any more. > > 2. Adopt established approach (e

Re: [PATCH] Add sinh(tanh(x)) and cosh(tanh(x)) rules

2018-11-09 Thread Segher Boessenkool
On Fri, Nov 09, 2018 at 01:03:55PM -0700, Jeff Law wrote: > >> And signed zeroes.  Yeah.  I think it would have to be > >> flag_unsafe_math_optimizations + some more. > > > > Indeed. > So we need to give Giuliano some clear guidance on guarding. This is > out of my area of expertise, so looking t

Re: [PATCH] combine: Do not combine moves from hard registers

2018-11-09 Thread Segher Boessenkool
On Fri, Nov 09, 2018 at 02:12:22PM -0700, Jeff Law wrote: > On 11/8/18 1:34 PM, Segher Boessenkool wrote: > > On Thu, Nov 08, 2018 at 03:44:44PM +, Sam Tebbs wrote: > >> Does your patch fix the incorrect generation of "scvtf s1, s1"? I was > >> looking at the issue as well and don't want to do

Re: [PATCH 1/3] Add PTWRITE builtins for x86

2018-11-09 Thread Segher Boessenkool
On Thu, Nov 08, 2018 at 06:30:21PM +0100, Uros Bizjak wrote: > --- /dev/null > +++ b/gcc/testsuite/gcc.target/i386/ptwrite2.c > @@ -0,0 +1,14 @@ > +/* { dg-do compile } */ > +/* { dg-options "-O2 -mptwrite " } */ > +/* { dg-final { scan-assembler "ptwrite.*r" } } */ > +/* { dg-final { scan-assemble

Re: [PATCH] minor FDO profile related fixes

2018-11-09 Thread Indu Bhagat
Changelog entry attached. Sorry about that. Comments inline. Thanks On 11/09/2018 04:23 PM, Jeff Law wrote: On 11/7/18 5:49 PM, Indu Bhagat wrote: diff --git a/gcc/coverage.c b/gcc/coverage.c index 599a3bb..7595e6c 100644 --- a/gcc/coverage.c +++ b/gcc/coverage.c @@ -358,7 +358,7 @@ get_cover

Re: [PATCH, GCC, AArch64] Branch Dilution Pass

2018-11-09 Thread Andrew Pinski
On Fri, Nov 9, 2018 at 9:23 AM Sudakshina Das wrote: > > Hi > > I am posting this patch on behalf of Carey (cc'ed). I also have some > review comments that I will make as a reply to this later. > > > This implements a new AArch64 specific back-end pass that helps optimize > branch-dense code, whic

Re: [PATCH] minor FDO profile related fixes

2018-11-09 Thread Jeff Law
On 11/7/18 5:49 PM, Indu Bhagat wrote: > I have been looking at -fdump-ipa-profile dump with an intention to sanitize > > bits of information so that one may use it to judge the "quality of a profile" > > in FDO. > > The overall question I want to address is - are there ways to know which > func

Re: [PATCH 2/3] Add a pass to automatically add ptwrite instrumentation

2018-11-09 Thread Martin Sebor
On 11/04/2018 12:32 AM, Andi Kleen wrote: From: Andi Kleen Add a new pass to automatically instrument changes to variables with the new PTWRITE instruction on x86. PTWRITE writes a 4 or 8 byte field into an Processor Trace log, which allows log over head logging of informatin. This allows to r

Re: [patch] allow target config to state r18 is fixed on aarch64

2018-11-09 Thread Andrew Pinski
On Fri, Nov 9, 2018 at 10:09 AM Olivier Hainque wrote: > > Hello Wilco, > > Would you have further thoughts on the patches proposed in > > https://gcc.gnu.org/ml/gcc-patches/2018-10/msg01453.html > > ? > > There was: > > 1) * config/aarch64/aarch64.c (PROBE_STACK_FIRST_REG) : Redefine as > R

Re: [PATCH v2] [aarch64] Correct the maximum shift amount for shifted operands.

2018-11-09 Thread Andrew Pinski
On Fri, Nov 9, 2018 at 3:39 AM wrote: > > From: Christoph Muellner > > The aarch64 ISA specification allows a left shift amount to be applied > after extension in the range of 0 to 4 (encoded in the imm3 field). > > This is true for at least the following instructions: > > * ADD (extend register

Re: Tweak ALAP calculation in SCHED_PRESSURE_MODEL

2018-11-09 Thread Jeff Law
On 11/8/18 5:10 AM, Kyrill Tkachov wrote: > > > This patch fixes a flaw in the relationship between the way that > SCHED_PRESSURE_MODEL calculates the alap and depth vs how it uses > them in model_order_p.  A comment in model_order_p says: > >   /* Combine the length of the longest path of satis

Re: [PATCH] add simple attribute introspection

2018-11-09 Thread Martin Sebor
On 11/09/2018 12:59 PM, Jeff Law wrote: On 10/31/18 10:27 AM, Martin Sebor wrote: Ping: https://gcc.gnu.org/ml/gcc-patches/2018-10/msg01473.html With the C++ bits approved I'm still looking for a review/approval of the remaining changes: the C front end and the shared c-family handling of the n

Re: Relocation (= move+destroy)

2018-11-09 Thread Marc Glisse
On Fri, 9 Nov 2018, Jonathan Wakely wrote: Here's the fix for the regression this introduced. Thanks. I was going to handle it, but I was waiting for you to review the second relocation patch first to avoid having several patches in flight over the same piece of code. Anyway, having the regr

[PATCH] C/C++: add fix-it hints for missing '&' and '*' (PR c++/87850)

2018-11-09 Thread David Malcolm
This patch adds a fix-it hint to various pointer-vs-non-pointer diagnostics, suggesting the addition of a leading '&' or '*'. For example, note the ampersand fix-it hint in the following: demo.c:5:22: error: invalid conversion from 'pthread_key_t' {aka 'unsigned int'} to 'pthread_key_t*' {aka

RE: [PATCH] MIPS: Add `-mfix-r5900' option for the R5900 short loop erratum

2018-11-09 Thread mfortune
Hi Fredrik, > Many thanks for your prompt review, Maciej! Maciej, I am equally grateful for you stepping in to get Fredrik's contribution reviewed. I have taken a look through and have no additional comments. I'm going to be travelling this weekend so I'd like to ask Maciej to take a quick look

Re: [PATCH] Add sinh(tanh(x)) and cosh(tanh(x)) rules

2018-11-09 Thread Giuliano Augusto Faulin Belinassi
Hi. Sorry for the late reply :P > But the max. error in sinh/cosh/atanh is less than 2 ULP, with some math > ibraries. It could be < 1 ULP, in theory, so sinh(atanh(x)) less than >2 ULP even. Sorry, but doesn't the user agree to sacrifice precision for performance when -ffast-math is enabled? >

RE: [PATCH v2] MIPS: Default to --with-llsc for the R5900 Linux target as well

2018-11-09 Thread mfortune
Hi Fredrik, > Would it be possible to apply the reviewed patch below? Apologies for the total lack of response from me. Thank-you for your efforts to get this noticed! The patch looks OK to me. I didn't see a ChangeLog entry anywhere but something like the following would be appropriate. gcc/

Re: [PATCH] Instrument only selected files (PR gcov-profile/87442).

2018-11-09 Thread Jeff Law
On 11/8/18 6:42 AM, Martin Liška wrote: > Hi. > > The patch is about possibility to filter which files are instrumented. The > usage > is explained in the PR. > > Patch can bootstrap and survives regression tests on x86_64-linux-gnu. > > Ready for trunk? > Thanks, > Martin > > gcc/ChangeLog: >

Re: [PATCH] MAINTAINERS: add myself as or1k maintainer

2018-11-09 Thread Stafford Horne
On Sat, Nov 10, 2018 at 06:09:56AM +0900, Stafford Horne wrote: > Hello, > > I will just commit the below, I dont expect it to cause any problem as I am > maintainer :). > > https://gcc.gnu.org/ml/gcc/2018-08/msg00216.html > > On Fri, Nov 09, 2018 at 09:44:07PM +0900, Stafford Horne wrote: > >

Re: [PATCH] combine: Do not combine moves from hard registers

2018-11-09 Thread Jeff Law
On 11/8/18 1:34 PM, Segher Boessenkool wrote: > On Thu, Nov 08, 2018 at 03:44:44PM +, Sam Tebbs wrote: >> Does your patch fix the incorrect generation of "scvtf s1, s1"? I was >> looking at the issue as well and don't want to do any overlapping work. > > I don't know. Well, there are no incor

Re: [PATCH] MAINTAINERS: add myself as or1k maintainer

2018-11-09 Thread Stafford Horne
Hello, I will just commit the below, I dont expect it to cause any problem as I am maintainer :). https://gcc.gnu.org/ml/gcc/2018-08/msg00216.html On Fri, Nov 09, 2018 at 09:44:07PM +0900, Stafford Horne wrote: > ChangeLog: > > -mm-dd Stafford Horne > > * MAINTAINERS (CPU Port M

Re: [PATCH] -fsave-optimization-record: compress the output using zlib

2018-11-09 Thread Jeff Law
On 11/9/18 10:51 AM, David Malcolm wrote: > One of the concerns noted at Cauldron about -fsave-optimization-record > was the size of the output files. > > This file implements compression of the -fsave-optimization-record > output, using zlib. > > I did some before/after testing of this patch, us

Re: [PATCH] Add value_range_base (w/o equivs)

2018-11-09 Thread Jeff Law
On 11/9/18 7:19 AM, Richard Biener wrote: > > This adds value_range_base, a base class of class value_range > with all members but the m_equiv one. > > I have looked into the sole GC user, IPA propagation, and replaced > the value_range use there with value_range_base since it also > asserted the

Re: Ping: [PATCH, testsuite] ignore some "conflicting types for built-in" messages

2018-11-09 Thread Jeff Law
On 11/9/18 7:21 AM, Paul Koning wrote: > Ping. > > I'd like to commit this. The discussion seems to have ended up with the > conclusion that this is a reasonable approach. > > paul > > >> On Nov 1, 2018, at 3:13 PM, Paul Koning wrote: >> >> A number of test cases contain declarations l

Re: [PATCH, libgfortran] Replace sync builtins with atomic builtins

2018-11-09 Thread Jakub Jelinek
On Fri, Nov 09, 2018 at 01:13:28PM +0200, Janne Blomqvist wrote: > The old __sync builtins have been deprecated for a long time now in > favor of the __atomic builtins following the C++11/C11 memory model. > This patch converts libgfortran to use the modern __atomic builtins. > > At the same time

Re: [PATCH] Fix PIE on netbsd (PR target/87221)

2018-11-09 Thread Jeff Law
On 11/9/18 1:59 AM, co...@sdf.org wrote: > Re-sending because my patch doesn't seem to appear on the archive > > > This matches to what netbsd is doing with its own copy of GCC, > it can be simpler. > > PR target/87221: > config/netbsd-elf.h (NETBSD_STARTFILE_SPEC): use crtbeginS.o for PIE > (NE

[doc, committed] Clarify defaults for some -fno-xxx options

2018-11-09 Thread Sandra Loosemore
This patch fixes the problems with the docs for the defaults for some -fno- options as noted in PR 41179. I double-checked the behavior against the code in opts.c and didn't just base this on trying to interpret the previous contorted wording. :-) This also addresses part of PR 65703. M

[committed] Change parsing of various expressions in OpenMP clauses to assignment-expression

2018-11-09 Thread Jakub Jelinek
Hi! As mentioned recently, in OpenMP 5.0 the general rule is that the grammar has assignment-expressions inside of clauses, unless otherwise specified (e.g. in array sections, array shape operator). In some cases we were already doing that, in other cases we parsed expression non-terminal instead

[committed] Emit sorry for inscan reduction modifier

2018-11-09 Thread Jakub Jelinek
Hi! In this case, even the parsing isn't finished (while the modifier is parsed, if there is the modifier, there must be scan directive in the body etc.). This patch emits a sorry. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk. 2018-11-09 Jakub Jelinek *

[committed] Emit sorry on most requires clauses

2018-11-09 Thread Jakub Jelinek
Hi! Similarly, the parsing here is implemented, but we don't do anything with it later on (mainly propagate to the runtime library and filter the available devices to the selected subset). So, this patch again emits a sorry on it for now. Bootstrapped/regtested on x86_64-linux and i686-linux, co

[committed] Sorry on lastprivate with conditional modifier

2018-11-09 Thread Jakub Jelinek
Hi! As mentioned earlier, for this feature the branch had just parsing support and limited diagnostics, plus preparations on the runtime library side, not the actual lowering/expansion, which I think will need 2 weeks full time, so deferring that to GCC 10. Instead of backing out the parsing, thi

Re: [PATCH] Fix up affinity-fmt.c (was Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9)

2018-11-09 Thread Jakub Jelinek
On Fri, Nov 09, 2018 at 10:23:24AM -0800, Iain Sandoe wrote: > Works For Me (as amended, bootstrap succeeds): > > display-affinity-1.c: > libgomp: Affinity not supported on this configuration > L:0%0>xx.local14527_0x7fffe64ed3c0_0x7fffe64ed3c0_-01 0-7

Re: [PATCH v5] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ulrich Weigand
Ilya Leoshkevich wrote: > PR target/87762 > * config/s390/s390.c (s390_safe_relative_long_p): New function. > (annotate_constant_pool_refs): Skip insns which support > relative addressing. > (annotate_constant_pool_refs_1): New helper function. > (find_constant

[PATCH v5] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ilya Leoshkevich
Bootstrapped and regtested on s390x-redhat-linux. r265490 allowed the compiler to choose in a more flexible way whether to use load or load-address-relative-long (LARL) instruction. When it chose LARL for literal pool references, the latter ones were rewritten by pass_s390_early_mach to use UNSPE

[committed] Fix minor bugs in loongsoon_ext2_prefetch_cookie

2018-11-09 Thread Jeff Law
The recent change to mips_loongson_ext2_prefetch_cookie had a couple minor bugs which showed up in a mips bootstrap. First it has an unused argument "locality". Assuming the argument is mandated by an API/ABI, the easiest way to shut up the compiler for the unused argument is to drop its name fr

Re: Relocation (= move+destroy)

2018-11-09 Thread Jonathan Wakely
On 25/10/18 13:36 +0100, Jonathan Wakely wrote: On 25/10/18 14:30 +0200, Marc Glisse wrote: On Tue, 23 Oct 2018, Jonathan Wakely wrote: + template +inline void +__relocate_a(_Tp* __dest, _Up* __orig, _Allocator& __alloc) I find it a little surprising that this overload for single ob

Re: [RFC] support --with-multilib-list=@/path/name

2018-11-09 Thread Palmer Dabbelt
On Fri, 09 Nov 2018 07:07:06 PST (-0800), ol...@adacore.com wrote: Richard, Olivier tells me he talked to you briefly at the Cauldron about allowing custom multilib sets to be configured from custom Makefile fragments supplied at configure time, and that you was somewhat receptive to the idea.

[committed] Minor testsuite cleanup from summer's v850 work

2018-11-09 Thread Jeff Law
I've had this lying around. Recent changes in that file reminded me to push it. Essentially the v850 pushes arguments for variadic functions rather than passing them in args, similarly to the nds32. So we need to guard the test in a similar manner. Committed to the trunk. Jeff commit cc9a0d23

Re: [PATCH] Add sinh(tanh(x)) and cosh(tanh(x)) rules

2018-11-09 Thread Jeff Law
On 11/8/18 6:33 AM, Wilco Dijkstra wrote: > Hi, > >> But the max. error in sinh/cosh/atanh is less than 2 ULP, with some math >> libraries.  It could be < 1 ULP, in theory, so sinh(atanh(x)) less than >> 2 ULP even. > > You can't add ULP errors in general - a tiny difference in the input can > m

Re: [PATCH] Fix PR 86572

2018-11-09 Thread Jeff Law
On 11/5/18 4:20 PM, Bernd Edlinger wrote: > On 11/5/18 1:28 AM, H.J. Lu wrote: >> On Sun, Nov 4, 2018 at 10:02 AM Jeff Law wrote: >>> On 10/22/18 9:08 AM, Bernd Edlinger wrote: Hi! This makes c_strlen avoid an unsafe strlen folding of const arguments with non-const offset. Cur

Re: [PATCH] add simple attribute introspection

2018-11-09 Thread Jeff Law
On 10/31/18 10:27 AM, Martin Sebor wrote: > Ping: https://gcc.gnu.org/ml/gcc-patches/2018-10/msg01473.html > > With the C++ bits approved I'm still looking for a review/approval > of the remaining changes: the C front end and the shared c-family > handling of the new built-in. I thought I acked th

Re: [PATCH 21/25] GCN Back-end (part 2/2).

2018-11-09 Thread Jeff Law
On 9/5/18 7:42 AM, Andrew Stubbs wrote: > This part initially failed to send due to size. > > Here's part 2. > > 0021-gcn-port-pt2.patch [ ... ] You've already addressed Joseph's comments in a follow-up. > > diff --git a/gcc/config/gcn/gcn.c b/gcc/config/gcn/gcn.c > new file mode 100644 > inde

[PATCH v2] MIPS: Add `-mfix-r5900' option for the R5900 short loop erratum

2018-11-09 Thread Fredrik Noring
The short loop bug under certain conditions causes loops to execute only once or twice, due to a hardware bug in the R5900 chip. `-march=r5900' already enables the R5900 short loop workaround. However, the R5900 ISA and most other MIPS ISAs are mutually exclusive since R5900-specific instructions

Re: [PATCH 21/25] GCN Back-end (part 1/2).

2018-11-09 Thread Jeff Law
On 9/5/18 7:40 AM, Andrew Stubbs wrote: > This part initially failed to send due to size. > > This is the main portion of the GCN back-end, plus the configuration > adjustments needed to build it. > > The config.sub patch is here so people can try it, but I'm aware that > needs to > be committed 

libgo patch committed: Fix typo in gccgo name mangling in cgo

2018-11-09 Thread Ian Lance Taylor
This patch by Than McIntosh fixes a typo in cmd/cgo in the gccgo name mangling recipe. The code to implement new-style gccgo name mangling had a recipe that didn't quite match the one in the compiler (incorrect handling for '.'). This showed up as a failure in the gotools cgo test if the directory

Re: [PATCH 20/25] GCN libgcc.

2018-11-09 Thread Jeff Law
On 9/5/18 5:52 AM, a...@codesourcery.com wrote: > This patch contains the GCN port of libgcc. I've broken it out just to keep > both parts more manageable. > > We have the usual stuff, plus a "gomp_print" implementation intended to > provide > a means to output text to console without using the

Re: [PATCH] MIPS: Add `-mfix-r5900' option for the R5900 short loop erratum

2018-11-09 Thread Fredrik Noring
Many thanks for your prompt review, Maciej! > > * gcc/config/mips/mips.c (mips_reorg_process_insns) > > (mips_option_override): Default to working around R5900 > > errata only if the processor was selected explicitly. > > I think this only describes the `mips_option_override' par

Re: [PATCH][RFC] Come up with -flive-patching master option.

2018-11-09 Thread Bernhard Reutner-Fischer
On 9 November 2018 16:33:22 CET, "Martin Liška" wrote: >Hi. > >After I added 2 new options, I would like to include a new master >option. >It's minimal version which only disables optimizations that we are >aware of >and can potentially cause problems for live-patching. I think you attached the w

Re: [RFT PATCH, i386]: Fix PR87928, ICE in ix86_compute_frame_layout

2018-11-09 Thread Iain Sandoe
Hi Uros, > On 8 Nov 2018, at 23:53, Uros Bizjak wrote: > > Attached patch fixes PR87928, where we ICE in ix86_compute_frame_layout in > I will commit the patch to mainline SVN early next week to allow > Darwin and Ming/Cygwin maintainers some time to test the patch on > their targets. Bootst

Re: Small typo in iconv.m4

2018-11-09 Thread Jeff Law
On 11/9/18 10:57 AM, Eric Gallager wrote: > On 11/7/18, Jeff Law wrote: >> On 11/6/18 9:37 AM, Hafiz Abid Qadeer wrote: >>> Hi All, >>> I was investigating a character set related problem with windows hosted >>> GDB and I tracked it down to a typo in iconv.m4. This typo caused >>> libiconv detecti

Re: [PATCH] Fix up affinity-fmt.c (was Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9)

2018-11-09 Thread Iain Sandoe
Hi Jakub, > On 9 Nov 2018, at 07:40, Jakub Jelinek wrote: > > On Fri, Nov 09, 2018 at 07:33:44AM -0800, Iain Sandoe wrote: >>> On 9 Nov 2018, at 06:37, Jakub Jelinek wrote: >> >>> +#if defined (HAVE_INTTYPES_H) && defined (PRIx64) >>> + else if (sizeof (gomp_integral (handle)) == sizeof

Re: [PATCH v2] [aarch64] Correct the maximum shift amount for shifted operands.

2018-11-09 Thread Kyrill Tkachov
Hi Christoph, On 09/11/18 11:38, christoph.muell...@theobroma-systems.com wrote: From: Christoph Muellner The aarch64 ISA specification allows a left shift amount to be applied after extension in the range of 0 to 4 (encoded in the imm3 field). This is true for at least the following instruc

Re: [PATCH, GCC, ARM] Enable armv8.5-a and add +sb and +predres for previous ARMv8-a in ARM

2018-11-09 Thread Kyrill Tkachov
Hi Sudi, On 09/11/18 15:33, Sudakshina Das wrote: Hi This patch adds -march=armv8.5-a to the Arm backend. (https://developer.arm.com/products/architecture/cpu-architecture/a-profile/exploration-tools) Armv8.5-A also adds two new security features: - Speculation Barrier instruction - Execution a

Re: [PATCH 2/3] Add a pass to automatically add ptwrite instrumentation

2018-11-09 Thread Andi Kleen
Hi Richard, On Fri, Nov 09, 2018 at 04:27:22PM +0100, Richard Biener wrote: > > Passes bootstrap and test suite on x86_64-linux, also > > bootstrapped and tested gcc itself with full -fvartrace > > and -fvartrace-locals instrumentation. > > So how is this supposed to be used? I guess in a > edit

Re: [patch] allow target config to state r18 is fixed on aarch64

2018-11-09 Thread Olivier Hainque
Hello Wilco, Would you have further thoughts on the patches proposed in https://gcc.gnu.org/ml/gcc-patches/2018-10/msg01453.html ? There was: 1) * config/aarch64/aarch64.c (PROBE_STACK_FIRST_REG) : Redefine as R9_REGNUM instead of 9. (PROBE_STACK_SECOND_REG): Redefine as R10_REGNUM

Re: [PATCH][cunroll] Add unroll-known-loop-iterations-only param and use it in aarch64

2018-11-09 Thread Kyrill Tkachov
On 09/11/18 12:18, Richard Biener wrote: On Fri, Nov 9, 2018 at 11:47 AM Kyrill Tkachov wrote: Hi all, In this testcase the codegen for VLA SVE is worse than it could be due to unrolling: fully_peel_me: mov x1, 5 ptrue p1.d, all whilelo p0.d, xzr, x1

Re: Small typo in iconv.m4

2018-11-09 Thread Eric Gallager
On 11/7/18, Jeff Law wrote: > On 11/6/18 9:37 AM, Hafiz Abid Qadeer wrote: >> Hi All, >> I was investigating a character set related problem with windows hosted >> GDB and I tracked it down to a typo in iconv.m4. This typo caused >> libiconv detection to fail and related support was not built into

Re: [PATCH v4] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ilya Leoshkevich
> Am 09.11.2018 um 18:30 schrieb Ulrich Weigand : > > Ilya Leoshkevich wrote: > >> gcc_assert (GET_CODE (x) != SYMBOL_REF >> - || !CONSTANT_POOL_ADDRESS_P (x)); >> + || !CONSTANT_POOL_ADDRESS_P (x) >> + || s390_symbol_relative_long_p (x)); > > Hmm, it's a bit weird t

[patch, libgfortran] Patch committed as obvious

2018-11-09 Thread Jerry DeLisle
Committed as obvious. I had inserted this line to check effects of the -fdec flags and forgot to delete it before my previous commit. Author: jvdelisle Date: Fri Nov 9 17:29:33 2018 New Revision: 265979 URL: https://gcc.gnu.org/viewcvs?rev=265979&root=gcc&view=rev Log: 2018-11-09 Jerry DeLisl

Re: [PATCH] Add value_range_base (w/o equivs)

2018-11-09 Thread Aldy Hernandez
On 11/9/18 9:19 AM, Richard Biener wrote: This adds value_range_base, a base class of class value_range with all members but the m_equiv one. First of all, thanks so much for doing this! I have looked into the sole GC user, IPA propagation, and replaced the value_range use there with value_

Re: [PATCH][RFC] Come up with -flive-patching master option.

2018-11-09 Thread Qing Zhao
Hi, Martin, thanks a lot for the previous two new options for live-patching. I have two more questions below: 1. do we still need new options to disable the following: A. unreachable code/variable removal? B. Visibility changes with -flto and/or -fwhole-program? 2. for this new patch,

Re: [PATCH][AArch64] PR79262: Adjust vector cost

2018-11-09 Thread Wilco Dijkstra
Hi James, >On Mon, Jan 22, 2018 at 09:22:27AM -0600, Richard Biener wrote: >> It would be better to dissect this cost into vec_to_scalar and vec_extract >> where >> vec_to_scalar really means getting at the scalar value of a vector of >> uniform values >> which most targets can do without any ins

Re: [PATCH] detect attribute mismatches in alias declarations (PR 81824)

2018-11-09 Thread Martin Sebor
+/* Handle the "copy" attribute by copying the set of attributes + from the symbol referenced by ARGS to the declaration of *NODE. */ + +static tree +handle_copy_attribute (tree *node, tree name, tree args, + int flags, bool *no_add_attrs) +{ + /* Break cycles in circular

Re: [PATCH][AArch64] PR79262: Adjust vector cost

2018-11-09 Thread Wilco Dijkstra
Hi James, > We have 7 unique target tuning structures in the AArch64 backend, of which > only one has a 2x ratio between scalar_int_cost and vec_to_scalar_cost. Other > ratios are 1, 3, 8, 3, 4, 6. I wouldn't read too much in the exact value here - the costs are simply relative to other values f

Re: [PATCH v4] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ulrich Weigand
Ilya Leoshkevich wrote: >gcc_assert (GET_CODE (x) != SYMBOL_REF > - || !CONSTANT_POOL_ADDRESS_P (x)); > + || !CONSTANT_POOL_ADDRESS_P (x) > + || s390_symbol_relative_long_p (x)); Hmm, it's a bit weird that this routine now uses a different check than the other tw

arm - minor cleanups for CPU alias support

2018-11-09 Thread Richard Earnshaw (lists)
A couple of very minor issues with the new support for CPU aliases. * config/arm/parsecpu.awk (/alias/): Tighten invisible alias matching criteria. Remove unused array initializer. Committed. diff --git a/gcc/config/arm/parsecpu.awk b/gcc/config/arm/parsecpu.awk index ba2dee5fdcb

[PATCH, GCC, AArch64] Branch Dilution Pass

2018-11-09 Thread Sudakshina Das
Hi I am posting this patch on behalf of Carey (cc'ed). I also have some review comments that I will make as a reply to this later. This implements a new AArch64 specific back-end pass that helps optimize branch-dense code, which can be a bottleneck for performance on some Arm cores. This is achi

Re: PING [PATCH] use MAX_OFILE_ALIGNMENT to validate attribute aligned (PR 87795)

2018-11-09 Thread Martin Sebor
On 11/07/2018 03:43 PM, Jeff Law wrote: On 11/6/18 5:06 PM, Martin Sebor wrote: Ping: https://gcc.gnu.org/ml/gcc-patches/2018-10/msg02081.html I thought I'd already ACK's this one... OK. You did but I made changes afterwards in response to Joseph's comment. I've committed the final patch i

Re: [PATCH] Simplify floating point comparisons

2018-11-09 Thread Wilco Dijkstra
Richard Biener wrote: >Marc Glisse wrote: >> Let's try with C = DBL_MIN and x = 婊BL_MAX. I don't believe it involves >> signed zeros or infinities, just an underflow. First, the result depends on >> the rounding mode. And in the default round-to-nearest, both divisions give >> 0, and thus compare t

[PATCH] -fsave-optimization-record: compress the output using zlib

2018-11-09 Thread David Malcolm
One of the concerns noted at Cauldron about -fsave-optimization-record was the size of the output files. This file implements compression of the -fsave-optimization-record output, using zlib. I did some before/after testing of this patch, using SPEC 2017's 502.gcc_r with -O3, looking at the sizes

[PATCH v4] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ilya Leoshkevich
Bootstrapped and regtested on s390x-redhat-linux. r265490 allowed the compiler to choose in a more flexible way whether to use load or load-address-relative-long (LARL) instruction. When it chose LARL for literal pool references, the latter ones were rewritten by pass_s390_early_mach to use UNSPE

Re: [PATCH] Fix not properly nul-terminated string constants in JIT

2018-11-09 Thread Bernd Edlinger
Hi Dave, is the patch OK, or do you still have questions? Thanks Bernd. On 11/2/18 10:48 PM, Bernd Edlinger wrote: > On 11/2/18 9:40 PM, David Malcolm wrote: >> On Sun, 2018-08-05 at 16:59 +, Bernd Edlinger wrote: >>> Hi! >>> >>> >>> My other patch with adds assertions to varasm.c regarding

Re: [PATCH v3] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ilya Leoshkevich
> Am 09.11.2018 um 14:43 schrieb Ulrich Weigand : > > Ilya Leoshkevich wrote: > >> + /* Return unannotated constant pool references, so that the corresponding >> + entries are added to the back-end-managed pool. Not doing so would >> result >> + in those entries being placed in the mid

Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9

2018-11-09 Thread David Edelsohn
> 2018-11-08 Rainer Orth > > * affinity.c: Include , . > (gomp_display_affinity_place): Remove cpusetp. > * teams.c: Include . This fixed AIX bootstrap failure also. Thanks, David

Re: [PATCH][GCC] Make DR_TARGET_ALIGNMENT compile time variable

2018-11-09 Thread Andre Vieira (lists)
On 05/11/18 12:41, Richard Biener wrote: > On Mon, Nov 5, 2018 at 1:07 PM Andre Vieira (lists) > wrote: >> >> >> Hi, >> Hi, Thank you for the quick response! See inline responses below. >> This patch enables targets to describe DR_TARGET_ALIGNMENT as a >> compile-time variable. It does so by tu

Re: [RFC][PATCH]Merge VEC_COND_EXPR into MASK_STORE after loop vectorization

2018-11-09 Thread Renlin Li
Hi Richard, On 11/09/2018 11:48 AM, Richard Biener wrote: On Thu, Nov 8, 2018 at 5:55 PM Renlin Li wrote: Hi Richard, *However*, after I rebased my patch on the latest trunk. Got the following dump from ifcvt: [local count: 1006632961]: # i_20 = PHI # ivtmp_18 = PHI a_10

Re: [RFC] support --with-multilib-list=@/path/name

2018-11-09 Thread Richard Earnshaw (lists)
On 09/11/2018 15:07, Alexandre Oliva wrote: > Richard, > > Olivier tells me he talked to you briefly at the Cauldron about allowing > custom multilib sets to be configured from custom Makefile fragments > supplied at configure time, and that you was somewhat receptive to the > idea. I have implem

Re: [PATCH] Fix up affinity-fmt.c (was Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9)

2018-11-09 Thread Jakub Jelinek
On Fri, Nov 09, 2018 at 07:33:44AM -0800, Iain Sandoe wrote: > > On 9 Nov 2018, at 06:37, Jakub Jelinek wrote: > > > +#if defined (HAVE_INTTYPES_H) && defined (PRIx64) > > + else if (sizeof (gomp_integral (handle)) == sizeof (uint64_t)) > > + sprintf (buf, "0x" PRIx64, (uint64_t) go

Re: Implement {get,set}_range_info() variants that work with value_range's

2018-11-09 Thread Martin Sebor
On 11/09/2018 03:02 AM, Aldy Hernandez wrote: On 11/8/18 4:47 PM, Martin Sebor wrote: On 11/08/2018 04:52 AM, Aldy Hernandez wrote: get/set_range_info() currently returns the extremes of a range. I have implemented overloaded variants that return a proper range. In the future we should use

Re: [PATCH] Fix up affinity-fmt.c (was Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9)

2018-11-09 Thread Iain Sandoe
Hi Jakub, > On 9 Nov 2018, at 06:37, Jakub Jelinek wrote: > +#if defined (HAVE_INTTYPES_H) && defined (PRIx64) > + else if (sizeof (gomp_integral (handle)) == sizeof (uint64_t)) > + sprintf (buf, "0x" PRIx64, (uint64_t) gomp_integral (handle)); s/0x/0x%/? Iain

[PATCH][RFC] Come up with -flive-patching master option.

2018-11-09 Thread Martin Liška
Hi. After I added 2 new options, I would like to include a new master option. It's minimal version which only disables optimizations that we are aware of and can potentially cause problems for live-patching. Martin >From dd52cd0249fc30cf6d7bf01a8826323277817b78 Mon Sep 17 00:00:00 2001 From: marx

[PATCH, GCC, ARM] Enable armv8.5-a and add +sb and +predres for previous ARMv8-a in ARM

2018-11-09 Thread Sudakshina Das
Hi This patch adds -march=armv8.5-a to the Arm backend. (https://developer.arm.com/products/architecture/cpu-architecture/a-profile/exploration-tools) Armv8.5-A also adds two new security features: - Speculation Barrier instruction - Execution and Data Prediction Restriction Instructions These are

libgo patch committed: Change RLIM_INFINITY from 0xffffffffffffffff to -1

2018-11-09 Thread Ian Lance Taylor
This libgo patch changees RLIM_INFINITY from 0x to -1 on GNU/Linux. 0x is arguably the correct value, but in the gc toolchain's syscall package the value is -1. So we are compatible. New programs should be using the golang.org/x/sys/unix package anyhow. This fixe

Re: [PATCH 2/3] Add a pass to automatically add ptwrite instrumentation

2018-11-09 Thread Richard Biener
On Sun, Nov 4, 2018 at 7:33 AM Andi Kleen wrote: > > From: Andi Kleen > > Add a new pass to automatically instrument changes to variables > with the new PTWRITE instruction on x86. PTWRITE writes a 4 or 8 byte > field into an Processor Trace log, which allows log over head > logging of informatin

[RFC] support --with-multilib-list=@/path/name

2018-11-09 Thread Alexandre Oliva
Richard, Olivier tells me he talked to you briefly at the Cauldron about allowing custom multilib sets to be configured from custom Makefile fragments supplied at configure time, and that you was somewhat receptive to the idea. I have implemented this as follows, for ARM targets only so far, usin

Re: [PATCH][AArch64] PR79262: Adjust vector cost

2018-11-09 Thread James Greenhalgh
On Mon, Jan 22, 2018 at 09:22:27AM -0600, Richard Biener wrote: > On Mon, Jan 22, 2018 at 4:01 PM, Wilco Dijkstra > wrote: > > PR79262 has been fixed for almost all AArch64 cpus, however the example is > > still > > vectorized in a few cases, resulting in lower performance. Increase the > > co

Re: [PATCH][AArch64] PR79262: Adjust vector cost

2018-11-09 Thread James Greenhalgh
On Fri, Nov 09, 2018 at 08:14:27AM -0600, Wilco Dijkstra wrote: > PR79262 has been fixed for almost all AArch64 cpus, however the example is > still > vectorized in a few cases, resulting in lower performance.  Increase the cost > of > vector-to-scalar moves so it is more similar to the other vec

Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9

2018-11-09 Thread David Malcolm
On Fri, 2018-11-09 at 12:11 +0100, Jakub Jelinek wrote: > On Fri, Nov 09, 2018 at 12:04:54PM +0100, Jakub Jelinek wrote: > > On Fri, Nov 09, 2018 at 11:34:48AM +0100, Dominique d'Humières > > wrote: > > > Bootstrapping r265942 on darwin failed with > > > > > > In file included from /Applications/X

[PATCH][AArch64] Fix symbol offset limit

2018-11-09 Thread Wilco Dijkstra
In aarch64_classify_symbol symbols are allowed full-range offsets on relocations. This means the offset can use all of the +/-4GB offset, leaving no offset available for the symbol itself. This results in relocation overflow and link-time errors for simple expressions like &global_char + 0x

[PATCH] Fix up affinity-fmt.c (was Re: [committed 0/4] (Partial) OpenMP 5.0 support for GCC 9)

2018-11-09 Thread Jakub Jelinek
Hi! The earlier patch doesn't work, because there were still expressions where handle could be still cast to integer of different size if it happened to be a pointer, or an invalid cast of e.g. aggregate to integer. The following patch so far only tested on a simplified code should handle it prop

Ping: [PATCH, testsuite] ignore some "conflicting types for built-in" messages

2018-11-09 Thread Paul Koning
Ping. I'd like to commit this. The discussion seems to have ended up with the conclusion that this is a reasonable approach. paul > On Nov 1, 2018, at 3:13 PM, Paul Koning wrote: > > A number of test cases contain declarations like: > void *memcpy(); > which currently are silently

[PATCH] Add value_range_base (w/o equivs)

2018-11-09 Thread Richard Biener
This adds value_range_base, a base class of class value_range with all members but the m_equiv one. I have looked into the sole GC user, IPA propagation, and replaced the value_range use there with value_range_base since it also asserted the equiv member is always NULL. This in turn means I hav

[PATCH][AArch64] Set SLOW_BYTE_ACCESS

2018-11-09 Thread Wilco Dijkstra
Contrary to all documentation, SLOW_BYTE_ACCESS simply means accessing bitfields by their declared type, which results in better codegeneration on practically any target. I'm thinking we should completely remove all trace of SLOW_BYTE_ACCESS from GCC as it's confusing and useless. OK for commit

[PATCH][AArch64] PR79262: Adjust vector cost

2018-11-09 Thread Wilco Dijkstra
PR79262 has been fixed for almost all AArch64 cpus, however the example is still vectorized in a few cases, resulting in lower performance.  Increase the cost of vector-to-scalar moves so it is more similar to the other vector costs. As a result -mcpu=cortex-a53 no longer vectorizes the testcase -

[PATCH][ARM] Update max_cond_insns settings

2018-11-09 Thread Wilco Dijkstra
The existing setting of max_cond_insns for most cores is non-optimal. Thumb-2 IT has a maximum limit of 4, so 5 means emitting 2 IT sequences. Also such long sequences of conditional instructions can increase the number of executed instructions significantly, so using 5 for max_cond_insns is non-op

Re: [PATCH v3] S/390: Allow relative addressing of literal pool entries

2018-11-09 Thread Ulrich Weigand
Ilya Leoshkevich wrote: > + /* Return unannotated constant pool references, so that the corresponding > + entries are added to the back-end-managed pool. Not doing so would > result > + in those entries being placed in the middle-end-managed pool, which > would > + in turn prevent

Re: [PATCH, arm] Backport -- Fix ICE during thunk generation with -mlong-calls

2018-11-09 Thread Mihail Ionescu
Hi Sudi On 11/08/2018 06:53 PM, Sudakshina Das wrote: Hi Mihail On 08/11/18 10:02, Ramana Radhakrishnan wrote: On 07/11/2018 17:49, Mihail Ionescu wrote: Hi All, This is a backport from trunk for GCC 8 and 7. SVN revision: r264595. Regression tested on arm-none-eabi. gcc/ChangeLog 2018-

Re: [PATCH] Come up with htab_hash_string_vptr and use string-specific if possible.

2018-11-09 Thread Michael Matz
Hi, On Thu, 8 Nov 2018, Martin Liška wrote: > > That seems better. But still, why declare this in system.h? It seems > > hash-table.h seems more appropriate. > > I need to declare it before I'll poison it. As system.h is included very > early, one can guarantee that there will be no usage be

[committed] json.cc: fix comment

2018-11-09 Thread David Malcolm
I've committed this obvious fix to trunk as r265968 (a copy&paste error). gcc/ChangeLog: * json.cc (selftest::test_writing_literals): Fix comment. --- gcc/json.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gcc/json.cc b/gcc/json.cc index a0c43956..46b6ef6 100644 -

  1   2   >