Re: [PATCH] avoid calling alloca(0)

2016-11-19 Thread Jakub Jelinek
On Sat, Nov 19, 2016 at 04:43:29PM -0700, Martin Sebor wrote: > Thanks for calling out the realloc(0, p) case! Realloc(0, p) is ?? The DR you refer to deprecates realloc(p, 0), not realloc(0, p). The latter is used much more widely, e.g. by not special casing the first allocation. So you use

Re: [PATCH] warn on overflow in calls to allocation functions (bugs 77531 and 78284)

2016-11-19 Thread Martin Sebor
The attached update is an attempt to incorporate the feedback I received last week during the discussion of the prerequisite patch to avoid calling alloca(0)​. The important changes are: 1) Add attribute returns_nonnull to __builtin_alloca. 2) Prevent calls to alloca(0) from triggering the -Wall

Re: [PATCH] avoid calling alloca(0)

2016-11-19 Thread Martin Sebor
So far I thought the warning is trying to make no differences between malloc, realloc and alloca. I would say that using realloc(x,0) is for sure always wrong. Nobody will object against a warning for that. Thanks for calling out the realloc(0, p) case! Realloc(0, p) is impossible to use porta

Re: Ping: Re: [PATCH 1/2] gcc: Remove unneeded global flag.

2016-11-19 Thread Andrew Burgess
* Christophe Lyon [2016-11-18 13:21:50 +0100]: > On 16 November 2016 at 23:12, Andrew Burgess > wrote: > > * Mike Stump [2016-11-16 12:59:53 -0800]: > > > >> On Nov 16, 2016, at 12:09 PM, Andrew Burgess > >> wrote: > >> > My only remaining concern is the new tests, I've tried to restrict > >>

Re: [RFC PATCH] avoid printing type suffix with %E (PR c/78165)

2016-11-19 Thread Martin Sebor
On 10/26/2016 02:46 PM, Joseph Myers wrote: On Wed, 26 Oct 2016, Martin Sebor wrote: The attached patch implements one such approach by having the pretty printer recognize the space format flag to suppress the type suffix, so "%E" still prints the suffix but "% E" does not. I did this to prese

Re: [PATCH v3] bb-reorder: Improve compgotos pass (PR71785)

2016-11-19 Thread Andreas Schwab
On Nov 17 2016, Segher Boessenkool wrote: > PR rtl-optimization/71785 > * bb-reorder.c (maybe_duplicate_computed_goto): New function. > (duplicate_computed_gotos): New function. > (pass_duplicate_computed_gotos::execute): Rewrite. This breaks gcc.c-torture/execute/comp-go

Re: [PATCH] libgcc/mkmap-symver: support skip_underscore (PR74748)

2016-11-19 Thread Jeff Law
On 11/19/2016 02:45 AM, Thomas Petazzoni wrote: All symbols in Blackfin are prepended with an underscore, so we're pretty much guaranteed there is one, and we precisely want to get rid of this prepended underscore. So I'd say it's good enough to get rid of the first character, without checking if

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Uros Bizjak
On Sat, Nov 19, 2016 at 6:24 PM, Jakub Jelinek wrote: > On Sat, Nov 19, 2016 at 12:28:22PM +0100, Jakub Jelinek wrote: >> On x86_64-linux with the 3 patches I'm not seeing any new FAILs >> compared to before r242569, on i686-linux there is still: >> +FAIL: gcc.target/i386/pr57756.c (test for erro

[committed] Link various gfortran tests against libatomic when available

2016-11-19 Thread John David Anglin
The attached change fixes these tests on hppa. We need to link against libatomic. Committed to trunk. Dave -- John David Anglin dave.ang...@bell.net 2016-11-19 John David Anglin * gfortran.dg/coarray_alloc_comp_1.f08: Add "-latomic" option if libatomic_available.

[PR target/25111] New patterns for m68k bit insns

2016-11-19 Thread Jeff Law
This BZ is a request to improve the code we generate for single bit set/clear/flip on the m68k where the target bit varies *and* is properly masked to avoid undefined behavior. I wasn't able to trigger this in GCC or newlib's runtime, but in the past Kazu was looking at real embedded code,

Re: [PATCH] shrink-wrap: New spread_components

2016-11-19 Thread Segher Boessenkool
Ping. On Wed, Nov 09, 2016 at 09:46:55PM +, Segher Boessenkool wrote: > This patch changes spread_components to use a simpler algorithm that > puts prologue components as early as possible, and epilogue components > as late as possible. This allows better scheduling, and also saves a > bit of

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Jakub Jelinek
On Sat, Nov 19, 2016 at 12:28:22PM +0100, Jakub Jelinek wrote: > On x86_64-linux with the 3 patches I'm not seeing any new FAILs > compared to before r242569, on i686-linux there is still: > +FAIL: gcc.target/i386/pr57756.c (test for errors, line 6) > +FAIL: gcc.target/i386/pr57756.c (test for wa

Re: [PATCH, Fortran, pr78395, v1] [OOP] error on polymorphic assignment

2016-11-19 Thread Janus Weil
Hi Andre, > When checking the shortened example in comment #3 one gets a segfault, because > v6 is not allocated explicitly. The initial example made sure, that v6 was > allocated. sorry, I guess that's my fault. I blindly removed the allocate statement when looking for a reduced test case for th

Re: PR69741: Bad error in formal with array scalar loop counters

2016-11-19 Thread Harald Anlauf
Sorry, forgot to mention: regtested on i686-pc-linux-gnu Harald On 11/19/16 15:42, Harald Anlauf wrote: > Hi Steve, all, > > On 11/19/16 02:18, Steve Kargl wrote: >> The error message is still not clear. 42 is a scalar integer. Why >> not use the language in the standard? >> >> C739 (R753) The

Re: PR69741: Bad error in formal with array scalar loop counters

2016-11-19 Thread Harald Anlauf
Hi Steve, all, On 11/19/16 02:18, Steve Kargl wrote: > The error message is still not clear. 42 is a scalar integer. Why > not use the language in the standard? > > C739 (R753) The index-name shall be a named scalar variable of type integer. I had adjusted the error message to the same appeari

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Andrew Senkevich
2016-11-19 13:17 GMT+03:00 Uros Bizjak : > On Sat, Nov 19, 2016 at 9:05 AM, Jakub Jelinek wrote: >> On Fri, Nov 18, 2016 at 09:30:06PM +0100, Jakub Jelinek wrote: >>> On Fri, Nov 18, 2016 at 08:41:01PM +0100, Jakub Jelinek wrote: >>> > I'm seeing lots of ICEs with this. >>> >>> Here is untested fi

[patch committed SH] Fix PR target/78426

2016-11-19 Thread Kaz Kojima
I've applied the attached patch to fix PR target/78426 which is a regression caused by rtl sharing with sh_expand_{cmpnstr,setmem}. Tested with "make -k check" on sh4-unknown-linux-gnu. I'll backport it to release branches. Regards, kaz -- 2016-11-19 Kaz Kojima PR target/78426

[PATCH] shrink-wrap: Fix problem with DF checking (PR78400)

2016-11-19 Thread Segher Boessenkool
With my previous patch the compiler ICEs if you use --enable-checking=df. This patch fixes it, by calling df_update_entry_exit_and_calls instead of df_update_entry_block_defs and df_update_exit_block_uses. Bootstrapped and checked on powerpc64-linux (also with --enable-checking=df). Is this okay f

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Jakub Jelinek
On Sat, Nov 19, 2016 at 11:17:55AM +0100, Uros Bizjak wrote: > > Here is another patch I'm going to test which fixes many other FAILs, but > > still some are left: > > FAIL: gcc.target/i386/funcspec-3.c (internal compiler error) > > FAIL: gcc.target/i386/funcspec-3.c (test for excess errors) > > FA

Re: [PATCH] Fix NetBSD bootstrap

2016-11-19 Thread Krister Walfridsson
On Thu, 17 Nov 2016, Joseph Myers wrote: I'll presume you know best about the choices of stdint.h types. You may wish to consider what the correct value of use_gcc_stdint is - the default "none" (rely on the system's header), or "wrap" (use GCC's header in freestanding mode) or "provide" (alway

[PATCHv2, C++] Warn on redefinition of builtin functions (PR c++/71973)

2016-11-19 Thread Bernd Edlinger
Hi, On 11/18/16 22:19, Jason Merrill wrote: > On 11/05/2016 12:44 PM, Bernd Edlinger wrote: >> + warning_at (DECL_SOURCE_LOCATION (newdecl), 0, >> + "declaration of %q+#D conflicts with built-in " >> + "declaration %q#D", newdecl, olddecl); > > There needs to be

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Uros Bizjak
On Sat, Nov 19, 2016 at 9:05 AM, Jakub Jelinek wrote: > On Fri, Nov 18, 2016 at 09:30:06PM +0100, Jakub Jelinek wrote: >> On Fri, Nov 18, 2016 at 08:41:01PM +0100, Jakub Jelinek wrote: >> > I'm seeing lots of ICEs with this. >> >> Here is untested fix for that, will bootstrap/regtest it soon (afte

Re: [PATCH] libgcc/mkmap-symver: support skip_underscore (PR74748)

2016-11-19 Thread Thomas Petazzoni
Hello, On Thu, 17 Nov 2016 14:08:34 -0700, Jeff Law wrote: > AFAICT this skips the first character regardless of whether or not it is > an underscore when skip_underscore is in effect, right. Correct. > Is that intentional? All symbols in Blackfin are prepended with an underscore, so we're p

New Spanish PO file for 'gcc' (version 6.2.0)

2016-11-19 Thread Translation Project Robot
Hello, gentle maintainer. This is a message from the Translation Project robot. A revised PO file for textual domain 'gcc' has been submitted by the Spanish team of translators. The file is available at: http://translationproject.org/latest/gcc/es.po (This file, 'gcc-6.2.0.es.po', has just

Re: [Patch, Fortran] PR 78392: ICE in gfc_trans_auto_array_allocation, at fortran/trans-array.c:5979

2016-11-19 Thread Janus Weil
Hi all, > I previously assumed that the test case for this PR would be legal, > but by now I think that's wrong. The test case should be rejected, and > we already have checking mechanisms for this (see > resolve_fl_variable), but apparently they are not working. > > My current suspicion is that '

[PATCH, committed] TILEPro: link against libgcc.a when creating shared libraries

2016-11-19 Thread Walter Lee
This patch forces gcc to link against libgcc.a when creating shared libraries, needed for 64-bit multiplies. Bootstrapped and tested on tilepro hardware, also backported to GCC 6. 2016-11-18 Walter Lee * config.host (tilepro*-*-linux*): Add t-slibgcc-libgcc. diff --git a/libgcc/confi

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Jakub Jelinek
On Sat, Nov 19, 2016 at 09:05:05AM +0100, Jakub Jelinek wrote: > On Fri, Nov 18, 2016 at 09:30:06PM +0100, Jakub Jelinek wrote: > > On Fri, Nov 18, 2016 at 08:41:01PM +0100, Jakub Jelinek wrote: > > > I'm seeing lots of ICEs with this. > > > > Here is untested fix for that, will bootstrap/regtest

Re: [PATCH] Enable Intel AVX512_4FMAPS and AVX512_4VNNIW instructions

2016-11-19 Thread Jakub Jelinek
On Fri, Nov 18, 2016 at 09:30:06PM +0100, Jakub Jelinek wrote: > On Fri, Nov 18, 2016 at 08:41:01PM +0100, Jakub Jelinek wrote: > > I'm seeing lots of ICEs with this. > > Here is untested fix for that, will bootstrap/regtest it soon (after my > current set of bootstraps finishes). > > 2016-11-18