[patch] configure option to override TARGET_LIBC_PROVIDES_SSP

2017-10-08 Thread Sandra Loosemore
This patch allows you to configure GCC to explicitly (not) add -lssp_nonshared -lssp link options when the -fstack-protector options are provided, by overriding the inferred default setting for TARGET_LIBC_PROVIDES_SSP. The specific use case this is for is a bare-metal target where the

Re: Restore functional DONT_USE_BUILTIN_SETJMP support

2017-10-08 Thread Joseph Myers
On Sun, 8 Oct 2017, Andreas Schwab wrote: > On Okt 08 2017, Eric Botcazou wrote: > > > * builtins.def (BUILT_IN_SETJMP): Declare as library builtin instead > > of GCC builtin if DONT_USE_BUILTIN_SETJMP is defined. > > This breaks gcc.dg/plugin/must-tail-call-2.c,

[PATCH 2/2] rs6000: Cleanup of various jump patterns

2017-10-08 Thread Segher Boessenkool
This cleans up formatting of many jump patterns. Mostly it is writing output statements as brace blocks, and deleting default arguments. It also makes indentation a little bit more consistent, and uses b%T0 (instead of bctr/blr alternatives) in two more places. Tested as usual; committing to

[PATCH 1/2] rs6000: Update conditional jump patterns, no more (pc) (label_ref)

2017-10-08 Thread Segher Boessenkool
Currently we have two patterns for every conditional jump: one jumping if some condition is met, and the other jumping if it is not met. We don't need that second form because all our conditions have an opposite already, and the generic code can deal with that just fine. This patch deletes that

Re: [patch] Fix wrong code with small structure return on PowerPC

2017-10-08 Thread Eric Botcazou
@adacore.com> * gcc.c-torture/execute/20171008-1.c: New test. -- Eric BotcazouIndex: expr.c === --- expr.c (revision 253506) +++ expr.c (working copy) @@ -9909,24 +9909,43 @@ expand_expr_real_1 (tree exp, rtx target && GET_M

[patch][arm][FreeBSD] gcc-6/5: add support for armv7*-*-freebsd*

2017-10-08 Thread Andreas Tobler
Hi all, and here is the patch for gcc-6/5 branch to add support for armv7*-*-freebsd* The difference towards trunk is the missing of target_cpu_cname which is solved differently. I'm aware of the gcc-5 branch status and I will not apply before gcc-5.5 is released. I'll also will not apply

[patch][arm][FreeBSD] gcc-7 branch: add support for armv7*-*-freebsd*

2017-10-08 Thread Andreas Tobler
Hi all, here is the patch witch adds support for armv7*-*-freebsd* on the gcc-7 branch. The difference towards trunk is the target_cpu_cname. I'll commit this one if no objections pop up. TIA, Andreas 2017-10-08 Andreas Tobler * config.gcc:

[patch][arm][FreeBSD] add support for armv7*-*-freebsd*

2017-10-08 Thread Andreas Tobler
Hi all, I'm going to commit this patch if no objections pop up. We (FreeBSD folks) have added a new target tripplet for armv7*-*-freebsd* To be able to build GCC we need the below changes. Results will be posted to the usual place, once they completed While here I remove an obsolete

Re: Restore functional DONT_USE_BUILTIN_SETJMP support

2017-10-08 Thread Eric Botcazou
> This also breaks gcc.c-torture/compile/951222-1.c: > > during GIMPLE pass: lower > /opt/gcc/gcc-20171008/gcc/testsuite/gcc.c-torture/compile/951222-1.c:4:1: > internal compiler error: in gimple_call_arg, at gimple.h:3159 0x118ab1b > gimple_call_arg You're right, not clear

[Fortran] Committed patch.

2017-10-08 Thread Steve Kargl
In check.c, gfc_check_x and gfc_check_fn_r were indentical functions (well other than the names). I have removed gfc_check_x and updated its uses to those of gfc_check_fn_r. After a bootstrap and regression testing I've committed the attached patch. 2017-10-08 Steven G. Kargl

Re: [RFA] [PATCH] Add a warning for invalid function casts

2017-10-08 Thread Eric Gallager
On Fri, Oct 6, 2017 at 2:06 PM, Bernd Edlinger wrote: > On 10/06/17 17:43, Martin Sebor wrote: >> On 10/06/2017 07:25 AM, Bernd Edlinger wrote: >>> On 10/05/17 18:16, Martin Sebor wrote: In my (very quick) tests the warning appears to trigger on all strictly

Re: [RFA] [PATCH] Add a warning for invalid function casts

2017-10-08 Thread Eric Gallager
On Fri, Oct 6, 2017 at 4:37 PM, Martin Sebor wrote: > On 10/06/2017 12:06 PM, Bernd Edlinger wrote: >> >> On 10/06/17 17:43, Martin Sebor wrote: >>> >>> On 10/06/2017 07:25 AM, Bernd Edlinger wrote: On 10/05/17 18:16, Martin Sebor wrote: > > In my (very quick)

Re: Restore functional DONT_USE_BUILTIN_SETJMP support

2017-10-08 Thread Andreas Schwab
> defined, force the creation of a new block for a dispatch label. This also breaks gcc.c-torture/compile/951222-1.c: during GIMPLE pass: lower /opt/gcc/gcc-20171008/gcc/testsuite/gcc.c-torture/compile/951222-1.c:4:1: internal compiler error: in gimple_call_arg, at gimple.h:3159 0x118ab

[committed][PATCH] Avoid stack-clash tests which do not work with -fstack-protector

2017-10-08 Thread Jeff Law
Red Hat's internal GCC testing does runs with -fstack-protector. This exposed failures with a few of the stack clash protection tests. I looked at all the failures. In every case we were still getting proper protection, but the addition of stack-protector code subtly changes the code

Re: [PATCH] libstdc++: istreambuf_iterator proxy

2017-10-08 Thread François Dumont
On 06/10/2017 20:00, Petr Ovtchenkov wrote: On Fri, 6 Oct 2017 18:01:36 +0200 François Dumont wrote: ... The test itself simulate "stop and go" istream usage. stringstream is convenient for behaviuor illustration, but in "real life" I can assume socket or tty on this

Re: [patch, fortran, committed] Small -fdump-fortran-original fixes, plus documentation update

2017-10-08 Thread Mikael Morin
Hello, Le 08/10/2017 à 15:15, Paul Richard Thomas a écrit : I thought that the suggestion to add the original input lines was not bad. It would be even better if -fdump-tree-original could do that. There is -fdump-tree-original-lineno. I think it does that. Cheers Mikael

Re: [patch, fortran, committed] Small -fdump-fortran-original fixes, plus documentation update

2017-10-08 Thread Thomas Koenig
Hi Paul, I thought that the suggestion to add the original input lines was not bad. It would be even better if -fdump-tree-original could do that. I often time find myself putting a line under the spotlight in a contained subroutine. This should be doable. What should be the perferred

Re: Restore functional DONT_USE_BUILTIN_SETJMP support

2017-10-08 Thread Andreas Schwab
On Okt 08 2017, Eric Botcazou wrote: > * builtins.def (BUILT_IN_SETJMP): Declare as library builtin instead > of GCC builtin if DONT_USE_BUILTIN_SETJMP is defined. This breaks gcc.dg/plugin/must-tail-call-2.c, gcc.dg/torture/pr81083.c and

Re: r253513 - in /trunk/gcc: ChangeLog common.opt d...

2017-10-08 Thread Andreas Schwab
FAIL: gcc.dg/cold-1.c (test for excess errors) Excess errors: /usr/local/gcc/gcc-20171008/gcc/testsuite/gcc.dg/cold-1.c:10:5: warning: implicit declaration of function 'abort' [-Wimplicit-function-declaration] /usr/local/gcc/gcc-20171008/gcc/testsuite/gcc.dg/cold-1.c:10:5: warning: incompatible

Re: [patch, fortran, committed] Small -fdump-fortran-original fixes, plus documentation update

2017-10-08 Thread Paul Richard Thomas
Hi Thomas, I thought that the suggestion to add the original input lines was not bad. It would be even better if -fdump-tree-original could do that. I often time find myself putting a line under the spotlight in a contained subroutine. Thanks for working on -fdump-parse-tree. Cheers Paul On 8

[patch, fortran, committed] Small -fdump-fortran-original fixes, plus documentation update

2017-10-08 Thread Thomas Koenig
Hello world, I have committed a few small fixes for -fdump-fortran-original and friends. Since there was interest on c.l.f from somebdoy who actually wanted to use the dump for something useful, I have also clarified in the docs that this is something that is not guaranteed to work between

Re: [PATCH][mingw] Enable colorized diagnostics

2017-10-08 Thread Liu Hao
On 2017/10/8 20:24, Hannes Domani wrote: Am Sonntag, 8. Oktober 2017, 14:02:48 MESZ hat Liu Hao Folgendes geschrieben: > On 2017/10/8 19:55, Hannes Domani wrote: > > > So why not just enable it on Win10? > > > It is up to you, GCC maintainers. If dropping support for

Re: [PATCH][mingw] Enable colorized diagnostics

2017-10-08 Thread Liu Hao
On 2017/10/8 19:55, Hannes Domani wrote: So why not just enable it on Win10? It is up to you, GCC maintainers. If dropping support for Windows prior to Windows 10 TH2 is an option, I may provide another patch, which I can't test because I primarily work on Windows 7. XD -- Best regards,

Re: [PATCH][mingw] Enable colorized diagnostics

2017-10-08 Thread Liu Hao
On 2017/9/28 4:09, Joseph Myers wrote: On Thu, 28 Sep 2017, Liu Hao wrote: Colorized diagnostics used to be disabled for MinGW targets (on which the macro `_WIN32` is defined), and this patch enables it. I'd hope this is all to do with MinGW host, and nothing to do with the target. Ping?

X+Y < X iff Y<0 moved to match.pd

2017-10-08 Thread Marc Glisse
Hello, this moves (and extends a bit) one more transformation from fold-const.c to match.pd. The single_use restriction is necessary for consistency with the existing X+CST1 CMP CST2 transformation (if we do only one of the 2 transformations, gcc.dg/tree-ssa/vrp54.c regresses because DOM

Re: [PATCH PR79868 ][aarch64] Fix error calls in aarch64 code so they can be translated (version 2)

2017-10-08 Thread Frédéric Marchal
Sorry for the delay. I lost track of this discussion. The patch looks good to me. I haven't checked the unit tests because I don't understand them. I assume they all succeed when you run the tests so they are all ok. I don't remember seeing a definite answer about the C-only syntax used in

Zen tuning part 5: Disable buldozer dispatch scheduling

2017-10-08 Thread Jan Hubicka
Hi, at the moment we do dispatch scheduling which is trying to optimize for Buldrozer's decoder. This does not make much sense as both decoders are significantly different. Bootstrapped/regtested x86_64-linux, comitted. Honza * i386.c (has_dispatch): Disable for Ryzen. Index: i386.c

Zen tuning part 4: Avoid 512bit memcpy/memset expansions on AVX128 optimal targets

2017-10-08 Thread Jan Hubicka
Hi, ix86_expand_set_or_movmem is trying to use widest possible vector mode available. This does not help for ryzen, because 512 operations are performed by halves. This patch by itself does not affect generated code because memcpy/memset expansion tables needs to be updated.