Re: [PATCH] Warn when comparing nonnull arguments to NULL in a function.

2015-09-15 Thread Mark Wielaard
On Tue, 2015-09-15 at 14:21 +0200, Manuel López-Ibáñez wrote: > On 15/09/15 10:32, Mark Wielaard wrote: > > On Mon, 2015-09-14 at 21:37 -0600, Martin Sebor wrote: > > Although I now notice they differ on the placement of the carrot. > > Maybe the location passed into the warning is not correct/idea

Re: [patch] Bump size of stack checking protection area

2015-09-15 Thread Eric Botcazou
> For avoidance of doubt, the patch is fine then. Thanks, installed with the tm.texi bits. -- Eric Botcazou

Re: [PATCH] PR66870 PowerPC64 Enable gold linker with split stack

2015-09-15 Thread Ian Lance Taylor
On Thu, Aug 27, 2015 at 2:00 PM, Lynn A. Boger wrote: > Here is an updated patch, with a summary of the differences from my previous > patch: > > - In my previous patch gcc configure was verifying the gold linker even if > it was the > default linker, but that is not necessary since in that case -

Re: [PATCH][C++] Avoid PCH dependent mangling

2015-09-15 Thread Richard Biener
On September 15, 2015 4:25:37 PM GMT+02:00, Jason Merrill wrote: >On 08/27/2015 09:36 AM, Richard Biener wrote: >> >> With the passes.c hunk in the patch below we FAIL assembly comparison >> of g++.dg/pch/system-[12].C because with PCH we have computed >> DECL_ASSEMBLER_NAME and thus appended DW_

[C PATCH] Better diagnostics for missing struct/union (PR c/67580)

2015-09-15 Thread Marek Polacek
Currently, when one writes a code that is missing the struct/union/enum tag, we get less than ideal error message. The following patch improves the situation a bit by giving a hint to the user. I couldn't use lookup_tag as that gives the "defined as wrong kind of tag" error; instead I wrote a new

Re: [PATCH 01/22] Change of location_get_source_line signature

2015-09-15 Thread David Malcolm
On Mon, 2015-09-14 at 13:26 -0600, Jeff Law wrote: > On 09/10/2015 02:28 PM, David Malcolm wrote: > > location_get_source_line takes an expanded_location, but the column > > is irrelevant; it just needs a filename and line number. > > > > This change is used by, but independent of, the new implemen

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Steve Ellcey
On Mon, 2015-09-14 at 09:50 +0200, Bernd Schmidt wrote: > On 09/13/2015 08:24 PM, Mark Wielaard wrote: > > commit 97505bd0e4ac15d86c2a302cfebc5f1a4fc2c2e8 > > Author: Mark Wielaard > > Date: Fri Sep 11 23:54:15 2015 +0200 > > > > PR28901 -Wunused-variable ignores unused const initialised var

[PATCH] More class-ification of DOM

2015-09-15 Thread Jeff Law
This turns the available expression structures into a class. To recap the goal is to be able to pass that class into the threader so the threader can manipulate the tables in well defined ways ultimately allowing us to resolve PR47679. This patch turns expr_hash_elt into a class and introdu

libgo patch committed: check linking split-stack and non-split-stack together

2015-09-15 Thread Ian Lance Taylor
Mainline GCC and gold now support -fsplit-stack for PPC. This means that if you are using mainline GCC with an old version of gold, and you compile with -fsplit-stack, and there is split-stack code that calls non-split-stack code, then gold will give an error because it doesn't know how to handle

Re: [C PATCH] Better diagnostics for missing struct/union (PR c/67580)

2015-09-15 Thread Joseph Myers
On Tue, 15 Sep 2015, Marek Polacek wrote: > Currently, when one writes a code that is missing the struct/union/enum > tag, we get less than ideal error message. The following patch improves > the situation a bit by giving a hint to the user. > > I couldn't use lookup_tag as that gives the "defin

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Jakub Jelinek
On Tue, Sep 15, 2015 at 10:02:15AM -0700, Steve Ellcey wrote: > I am not sure I like this change. It broke the GLIBC build for me on > MIPS. Basically GLIBC has a header file with initialized static > constant globals (sysdeps/ieee754/dbl-64/atnat2.h contains tqpi1 and > qpi1) and that header fil

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Joseph Myers
On Tue, 15 Sep 2015, Steve Ellcey wrote: > I am not sure I like this change. It broke the GLIBC build for me on > MIPS. Basically GLIBC has a header file with initialized static > constant globals (sysdeps/ieee754/dbl-64/atnat2.h contains tqpi1 and > qpi1) and that header file is included in mul

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Steve Ellcey
On Tue, 2015-09-15 at 19:10 +0200, Jakub Jelinek wrote: > On Tue, Sep 15, 2015 at 10:02:15AM -0700, Steve Ellcey wrote: > > I am not sure I like this change. It broke the GLIBC build for me on > > MIPS. Basically GLIBC has a header file with initialized static > > constant globals (sysdeps/ieee75

Re: [C++] Coding rule enforcement

2015-09-15 Thread Manuel López-Ibáñez
On 15/09/15 15:26, Richard Biener wrote: On Tue, Sep 15, 2015 at 3:02 PM, Nathan Sidwell wrote: Jason, somme of our customers have 'interesting' C++ coding rules, they'd like to have the compiler enforced. They want to disable: 1) namespace definitions 2) template declarations 3) multiple inh

Re: [C PATCH] Better diagnostics for missing struct/union (PR c/67580)

2015-09-15 Thread Martin Sebor
On 09/15/2015 10:52 AM, Marek Polacek wrote: Currently, when one writes a code that is missing the struct/union/enum tag, we get less than ideal error message. The following patch improves the situation a bit by giving a hint to the user. I can't count the number of times I've made this mistak

Re: [C PATCH] Better diagnostics for missing struct/union (PR c/67580)

2015-09-15 Thread Marek Polacek
On Tue, Sep 15, 2015 at 11:26:03AM -0600, Martin Sebor wrote: > On 09/15/2015 10:52 AM, Marek Polacek wrote: > >Currently, when one writes a code that is missing the struct/union/enum > >tag, we get less than ideal error message. The following patch improves > >the situation a bit by giving a hint

dejagnu version update?

2015-09-15 Thread Mike Stump
On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: >> Maybe GCC-6 can bump the required >> dejagnu version to allow for getting rid of all these superfluous >> load_gcc_lib? *blink* :) > I'd support that as a direction. > > Certainly dropping the 2001 version from our website in favor of 1.5 (which >

Re: [patch] Get rid of useless EH cleanups at -O0

2015-09-15 Thread Eric Botcazou
> Played with this a bit, this appears to be fine. Thanks. To answer your earlier question, the first part of the patch is only for debugging: this will e.g. prevent multiple breakpoints from being set by the debugger when there are more than 2 non-EH paths. -- Eric Botcazou

[PATCH, alpha]: Fix alpha bootstrap failure due to -Werror=shift-negative-value

2015-09-15 Thread Uros Bizjak
2015-09-15 Uros Bizjak * config/alpha/alpha.c (alpha_expand_block_clear): Use HOST_WIDE_INT_M1U instead of ~(HOST_WIDE_INT)0 when shifting. Bootstrapped and regression tested on alpha-linux-gnu. Committed to mainline SVN. Uros. Index: config/alpha/alpha.c

[PATCH, i386]: Fix PR 67484, asan detects heap-use-after-free with target options

2015-09-15 Thread Uros Bizjak
Hello! As mentioned in the PR, ix86_valid_target_attribute_tree creates temporary copies of current options strings and saves *pointers* to these copies with build_target_option_node. A couple of lines below, these temporary copies are freed, leaving dangling pointers in the saved structure. Use

Re: [PATCH] PR66870 PowerPC64 Enable gold linker with split stack

2015-09-15 Thread David Edelsohn
On Thu, Aug 27, 2015 at 5:00 PM, Lynn A. Boger wrote: > Here is an updated patch, with a summary of the differences from my previous > patch: > > - In my previous patch gcc configure was verifying the gold linker even if > it was the > default linker, but that is not necessary since in that case -

Re: [PATCH 1/2] xtensa: fix TLS calls for call0 ABI

2015-09-15 Thread augustine.sterl...@gmail.com
On Tue, Sep 15, 2015 at 3:00 AM, Max Filippov wrote: > 2015-09-15 Max Filippov > gcc/ > * config/xtensa/xtensa.c (xtensa_call_tls_desc): Use a10 or a2 > to pass TLS call argument, according to current ABI. > * config/xtensa/xtensa.md (tls_call pattern): Use callx8 or Ap

Re: [PATCH 2/2] xtensa: fix xtensa_fallback_frame_state for call0 ABI

2015-09-15 Thread augustine.sterl...@gmail.com
On Tue, Sep 15, 2015 at 3:00 AM, Max Filippov wrote: > 2015-09-15 Max Filippov > gcc/ > * config/xtensa/xtensa.h (DWARF_ALT_FRAME_RETURN_COLUMN): New > definition. > (DWARF_FRAME_REGISTERS): Reserve space for one extra register in > call0 ABI. > > libgcc/ >

Re: [PATCH] PR66870 PowerPC64 Enable gold linker with split stack

2015-09-15 Thread Lynn A. Boger
I will make the changes Ian suggested to gospec.c and was planning to fix the sed string in gcc/configure.ac as David suggested. I need some feedback on whether to enable the gold linker at all for split stack on platforms other than Power in gcc/configure.ac. I don't know if there are gold linke

Re: [C++] Coding rule enforcement

2015-09-15 Thread Jason Merrill
On 09/15/2015 01:20 PM, Manuel López-Ibáñez wrote: On 15/09/15 15:26, Richard Biener wrote: On Tue, Sep 15, 2015 at 3:02 PM, Nathan Sidwell wrote: Jason, somme of our customers have 'interesting' C++ coding rules, they'd like to have the compiler enforced. They want to disable: 1) namespace

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Mark Wielaard
On Tue, 2015-09-15 at 10:20 -0700, Steve Ellcey wrote: > On Tue, 2015-09-15 at 19:10 +0200, Jakub Jelinek wrote: > > On Tue, Sep 15, 2015 at 10:02:15AM -0700, Steve Ellcey wrote: > > > I am not sure I like this change. It broke the GLIBC build for me on > > > MIPS. Basically GLIBC has a header fi

Merge from trunk to gccgo branch

2015-09-15 Thread Ian Lance Taylor
I merged trunk revision 227802 to the gccgo branch. Ian

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Mark Wielaard
On Tue, 2015-09-15 at 20:33 +0200, Mark Wielaard wrote: > I build glibc and found 9 unused variables. They all look like they are > really not used in the code, so they can all just be removed. Someone of > course should double check they aren't unused by accident before > committing upstream. For

Re: dejagnu version update?

2015-09-15 Thread David Malcolm
On Tue, 2015-09-15 at 10:39 -0700, Mike Stump wrote: > On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: > >> Maybe GCC-6 can bump the required > >> dejagnu version to allow for getting rid of all these superfluous > >> load_gcc_lib? *blink* :) > > I'd support that as a direction. > > > > Certainly dr

Re: dejagnu version update?

2015-09-15 Thread Bernhard Reutner-Fischer
On September 15, 2015 7:39:39 PM GMT+02:00, Mike Stump wrote: >On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: >>> Maybe GCC-6 can bump the required >>> dejagnu version to allow for getting rid of all these superfluous >>> load_gcc_lib? *blink* :) >> I'd support that as a direction. >> >> Certainl

Re: [PATCH] PR28901 -Wunused-variable ignores unused const initialised variables

2015-09-15 Thread Joseph Myers
timezone/private.h comes verbatim from the tzcode project and should not be modified locally in glibc. -- Joseph S. Myers jos...@codesourcery.com

Re: [PATCH] PR66870 PowerPC64 Enable gold linker with split stack

2015-09-15 Thread Ian Lance Taylor
On Tue, Sep 15, 2015 at 11:24 AM, Lynn A. Boger wrote: > > I need some feedback on whether to enable the gold linker at > all for split stack on platforms other than Power in gcc/configure.ac. > I don't know if there are gold linker versions that should be verified for > non-Power platforms. My f

Re: dejagnu version update?

2015-09-15 Thread Jeff Law
On 09/15/2015 01:23 PM, Bernhard Reutner-Fischer wrote: On September 15, 2015 7:39:39 PM GMT+02:00, Mike Stump wrote: On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: Maybe GCC-6 can bump the required dejagnu version to allow for getting rid of all these superfluous load_gcc_lib? *blink* :) I'd

Re: dejagnu version update?

2015-09-15 Thread Jeff Law
On 09/15/2015 01:21 PM, David Malcolm wrote: On Tue, 2015-09-15 at 10:39 -0700, Mike Stump wrote: On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: Maybe GCC-6 can bump the required dejagnu version to allow for getting rid of all these superfluous load_gcc_lib? *blink* :) I'd support that as a dir

Re: [PATCH, rs6000] Use hardware support for vector character multiply

2015-09-15 Thread Andrew Pinski
On Tue, Sep 15, 2015 at 6:58 AM, Richard Biener wrote: > On Thu, Sep 3, 2015 at 5:32 PM, Bill Schmidt > wrote: >> On Thu, 2015-09-03 at 23:26 +0800, Andrew Pinski wrote: >>> On Thu, Sep 3, 2015 at 11:20 PM, Bill Schmidt >>> wrote: >>> > Hi, >>> > >>> > It was pointed out to me recently that mult

Re: [PATCH, rs6000] Use hardware support for vector character multiply

2015-09-15 Thread Bill Schmidt
On Tue, 2015-09-15 at 13:29 -0700, Andrew Pinski wrote: > On Tue, Sep 15, 2015 at 6:58 AM, Richard Biener > wrote: > > On Thu, Sep 3, 2015 at 5:32 PM, Bill Schmidt > > wrote: > >> On Thu, 2015-09-03 at 23:26 +0800, Andrew Pinski wrote: > >>> On Thu, Sep 3, 2015 at 11:20 PM, Bill Schmidt > >>> wr

Re: dejagnu version update?

2015-09-15 Thread Bernhard Reutner-Fischer
On September 15, 2015 10:05:27 PM GMT+02:00, Jeff Law wrote: >On 09/15/2015 01:21 PM, David Malcolm wrote: >> On Tue, 2015-09-15 at 10:39 -0700, Mike Stump wrote: >>> On Sep 14, 2015, at 3:37 PM, Jeff Law wrote: > Maybe GCC-6 can bump the required > dejagnu version to allow for getting ri

libgo patch committed: Use -fno-split-stack for Go if linker doesn't support split-stack

2015-09-15 Thread Ian Lance Taylor
Another patch for libgo with an old linker: if the compiler supports -fsplit-stack but the linker does not, then we need to explicitly compile the Go code with -fno-split-stack. Otherwise the linker will complain when linking libgo.so. This patch fixes the problem. Bootstrapped on x86_64-unknown-

Re: Merge from trunk to gccgo branch

2015-09-15 Thread Ian Lance Taylor
On Tue, Sep 15, 2015 at 11:55 AM, Ian Lance Taylor wrote: > I merged trunk revision 227802 to the gccgo branch. And again, from revision 227811. Ian

Re: [PATCH 1/2] xtensa: fix TLS calls for call0 ABI

2015-09-15 Thread Max Filippov
On Tue, Sep 15, 2015 at 9:21 PM, augustine.sterl...@gmail.com wrote: > On Tue, Sep 15, 2015 at 3:00 AM, Max Filippov wrote: >> 2015-09-15 Max Filippov >> gcc/ >> * config/xtensa/xtensa.c (xtensa_call_tls_desc): Use a10 or a2 >> to pass TLS call argument, according to current AB

Re: debug mode symbols cleanup

2015-09-15 Thread Jonathan Wakely
On 14/09/15 20:26 +0200, François Dumont wrote: On 08/09/2015 22:47, François Dumont wrote: On 07/09/2015 13:03, Jonathan Wakely wrote: On 05/09/15 22:53 +0200, François Dumont wrote: I remember Paolo saying once that we were not guarantiing any abi compatibility for debug mode. I haven't f

Re: dejagnu version update?

2015-09-15 Thread Mike Stump
On Sep 15, 2015, at 1:04 PM, Jeff Law wrote: > Given we haven't updated the dejagnu reqs since ~2001, I think stepping > forward would be appropriate and I'd support moving all the way to 1.5.3 with > the expectation that we'll be on a cadence of no faster than 2 years going > forward. So, I a

Go patch committed: Avoid compiler crash on initialization error

2015-09-15 Thread Ian Lance Taylor
This patch by Chris Manghane to the Go frontend avoids a compiler crash on an initialization error involving builtin functions. This fixes https://golang.org/issue/12319 . Bootstrapped and ran Go testsuite on x86_64-unknown-linux-gnu. Committed to mainline. Ian Index: gcc/go/gofrontend/MERGE ==

[PATCH] shrink-wrap: Fix up partitions (PR67587)

2015-09-15 Thread Segher Boessenkool
With the new shrink-wrap algorithm, blocks reachable both with and without prologue are duplicated, and their incoming edges are then distributed accordingly. So we need to call fixup_partitions. Is this okay for trunk? Segher 2015-09-16 Segher Boessenkool PR bootstrap/67587

Re: [PATCH] [ping] Use single shared memory block pool for all pool allocators

2015-09-15 Thread Mikhail Maltsev
On 08/31/2015 02:44 PM, Richard Biener wrote: > Apart from Richards comments: > > +/* Return UNCAST_BLOCK to pool. */ > +inline void > +memory_block_pool::remove (void *uncast_block) > +{ > + block_list *block = reinterpret_cast (uncast_block); > + block->m_next = instance.m_blocks; > + instan

[PATCH][PING][C++] Fix PR67333

2015-09-15 Thread Mikhail Maltsev
Ping. On 08/27/2015 09:27 PM, Mikhail Maltsev wrote: > Hi. > This patch fixes a rejects-valid bug related to volatile-qualified arguments > of > constexpr functions. This is essentially a one-line change in constexpr.c. > Bootstrapped and regtested on x86_64-pc-linux-gnu. OK for trunk? > > gcc/c

Re: [wwwdocs] GCC 6 Release Notes for RTEMS

2015-09-15 Thread Sebastian Huber
I checked this in. On 15/09/15 09:49, Sebastian Huber wrote: I think there are some head lines missing: Index: htdocs/gcc-6/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-6/changes.html,v retrieving revision 1.29 diff -u -r

Re: libgo patch committed: Don't provide ustat on arm64 GNU/Linux

2015-09-15 Thread Andreas Schwab
Ian Lance Taylor writes: > Apparently arm64 GNU/Linux does not provide ustat, and the linker > warns about it when using glibc. This patch to libgo avoids providing > syscall.Ustat on arm64 GNU/Linux, since it will apparently never work. > > Since I was touching Makefile.am I rebuilt with automa

Re: [PATCH] Teach genmatch.c to generate single-use restrictions from flags

2015-09-15 Thread Richard Biener
On Mon, 14 Sep 2015, Bernhard Reutner-Fischer wrote: > On September 14, 2015 11:23:28 AM GMT+02:00, Richard Biener > wrote: > >On Fri, 11 Sep 2015, Bernd Schmidt wrote: > > > >> On 07/08/2015 04:39 PM, Richard Biener wrote: > >> > > >> > This introduces a :s flag to match expressions which enfo

Re: [PATCH][20/n] Remove GENERIC stmt combining from SCCVN

2015-09-15 Thread Eric Botcazou
> > That's old code and the comment makes it quite clear why this is done > > though. > > Yeah, but then here "we don't need to evaluate it just for the check" > applies - the check is dead code as the outer comparison is always > false. I think what the code in the Ada frontend tries to achieve >

Re: [PATCH 2/5] completely_scalarize arrays as well as records.

2015-09-15 Thread Richard Biener
On Mon, 14 Sep 2015, Alan Lawrence wrote: > Ping. (Rerevert with 5 lines extra paranoia in scalarizable_type_p). Sorry for chiming in so late... + if (TYPE_DOMAIN (type) == NULL_TREE + || !TREE_CONSTANT (TYPE_MIN_VALUE (TYPE_DOMAIN (type))) + || !TREE_CONSTANT (TYPE_MAX_VALU

Re: [wwwdocs] GCC 6 Release Notes for RTEMS

2015-09-15 Thread Sebastian Huber
I think there are some head lines missing: Index: htdocs/gcc-6/changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-6/changes.html,v retrieving revision 1.29 diff -u -r1.29 changes.html --- htdocs/gcc-6/changes.html 15 Sep 2015 0

Re: [patch] Bump size of stack checking protection area

2015-09-15 Thread Eric Botcazou
> So it looks like some targets are at least optionally still using sjlj > exceptions and would be affected by this change. AFAICT it only makes a > difference with -fstack-check and would be a bugfix even for those > targets - correct? Yes, for example the 32-bit Windows compiler still uses SJLJ

[PATCH] Fix PR67568

2015-09-15 Thread Richard Biener
Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2015-09-15 Richard Biener PR lto/67568 * lto-streamer.h (lto_location_cache::current_sysp): Properly initialize. * lto-streamer-out.c (clear_line_info): Likewise. Index: gcc/lto-streamer.h =

Re: [AArch64] Force __builtin_aarch64_fp[sc]r argument into a REG

2015-09-15 Thread James Greenhalgh
On Mon, Sep 14, 2015 at 06:49:15PM +0100, Richard Sandiford wrote: > The attached testcase triggered an ICE because the builtin expansion > code passed the output of expand_normal directly to the SET_FP[SC]R > generator, without forcing it into a register first. > > Tested on aarch64-linux-gnu. O

Re: [PATCH] Warn when comparing nonnull arguments to NULL in a function.

2015-09-15 Thread Mark Wielaard
On Mon, 2015-09-14 at 21:37 -0600, Martin Sebor wrote: > > +void foo(void *bar) __attribute__((nonnull(1))); > > + > > +void foo(void *bar) { if (!bar) abort(); } /* { dg-warning "null" > > "argument ‘bar’ compared to NULL" } */ > > This looks like a very useful enhancement. Since the change is l

Re: [PATCH][C++] Avoid PCH dependent mangling

2015-09-15 Thread Richard Biener
On Thu, 27 Aug 2015, Richard Biener wrote: > > With the passes.c hunk in the patch below we FAIL assembly comparison > of g++.dg/pch/system-[12].C because with PCH we have computed > DECL_ASSEMBLER_NAME and thus appended DW_AT_linkage_name early during > PCH generation while without PCH we comput

Re: [PATCH][AArch64 array_mode 1/8] Rename vec_store_lanes_lane to aarch64_vec_store_lanes_lane

2015-09-15 Thread James Greenhalgh
On Wed, Aug 26, 2015 at 02:46:52PM +0100, Alan Lawrence wrote: > vec_store_lanes{oi,ci,xi}_lane are not standard pattern names, so using them > in aarch64-simd.md is misleading. This adds an aarch64_ prefix to those > pattern names, paralleling aarch64_vec_load_lanes_lane. > > bootstrapped and che

Re: [PATCH][AArch64 array_mode 2/8] Remove VSTRUCT_DREG, use BLKmode for d-reg aarch64_st/ld expands

2015-09-15 Thread James Greenhalgh
On Wed, Aug 26, 2015 at 02:46:53PM +0100, Alan Lawrence wrote: > aarch64_st and > aarch64_ld expanders back onto 12 insns > aarch64_{ld,st}{2,3,4}_dreg (for VD and DX modes), using the > VSTRUCT_DREG iterator over TI/EI/OI modes to represent the block of memory > transferred. Instead, use BLKmode f

Re: [PATCH][AArch64 0/8] Add D-registers to TARGET_ARRAY_MODE_SUPPORTED_P

2015-09-15 Thread Alan Lawrence
Here's a rebased version, which fixes conflicts with float16 and Christophe's fixes for bigendian lane indices. Also fiddled around with whitespace in aarch64-simd.md

[PATCH][AArch64 array_mode 3/8] Stop using EImode in aarch64-simd.md and iterators.md

2015-09-15 Thread Alan Lawrence
The V_THREE_ELEM attribute used BLKmode for most sizes, but occasionally EImode. This patch changes to BLKmode in all cases, explicitly setting memory size (thus, preserving size for the cases that were EImode, and setting size for the first time for cases that were already BLKmode). The patterns

[PATCH][AArch64 array_mode 2/8] Remove VSTRUCT_DREG, use BLKmode for d-reg aarch64_st/ld expands

2015-09-15 Thread Alan Lawrence
aarch64_st and aarch64_ld expanders back onto 12 insns aarch64_{ld,st}{2,3,4}_dreg (for VD and DX modes), using the VSTRUCT_DREG iterator over TI/EI/OI modes to represent the block of memory transferred. Instead, use BLKmode for all memory transfers, explicitly setting mem_size. Bootstrapped and c

[PATCH][AArch64 array_mode 6/8] Remove V_TWO_ELEM, again using BLKmode + set_mem_size.

2015-09-15 Thread Alan Lawrence
Same logic as previous; this makes the 2-, 3-, and 4-lane expanders all follow the same pattern. bootstrapped and check-gcc on aarch64-none-linux-gnu. gcc/ChangeLog: * config/aarch64/aarch64-simd.md (aarch64_simd_ld2r, aarch64_vec_load_lanesoi_lane, aarch64_vec_store_lan

[PATCH][AArch64 array_mode 8/8] Add d-registers to TARGET_ARRAY_MODE_SUPPORTED_P

2015-09-15 Thread Alan Lawrence
This adds an AARCH64_VALID_SIMD_DREG_MODE exactly paralleling the existing ...QREG... macro. The new test now compiles (at -O3) to: test_1: add v1.2s, v1.2s, v5.2s add v2.2s, v2.2s, v6.2s add v3.2s, v3.2s, v7.2s add v0.2s, v0.2s, v4.2s ret

[PATCH][AArch64 array_mode 5/8] Remove V_FOUR_ELEM, again using BLKmode + set_mem_size.

2015-09-15 Thread Alan Lawrence
This removes V_FOUR_ELEM in the same way that patch 3 removed V_THREE_ELEM, again using BLKmode + set_mem_size. (This makes the four-lane expanders very similar to the three-lane expanders, and they will be combined in patch 7.) bootstrapped and check-gcc on aarch64-none-linux-gnu gcc/ChangeLog:

[PATCH][AArch64 array_mode 7/8] Combine the expanders using VSTRUCT:nregs

2015-09-15 Thread Alan Lawrence
The previous patches leave ld[234]_lane, st[234]_lane, and ld[234]r expanders all nearly identical, so we can easily parameterize across the number of lanes and combine them. For the ld_lane pattern, I switched from the VCONQ attribute to just using the MODE attribute, this is identical for all

[PATCH][AArch64 array_mode 4/8] Remove EImode

2015-09-15 Thread Alan Lawrence
This removes EImode from the (AArch64) compiler, and all mention of or support for it. bootstrapped and check-gcc on aarch64-none-linux-gnu gcc/ChangeLog: * config/aarch64/aarch64.c (aarch64_simd_attr_length_rglist): Update comment. * config/aarch64/aarch64-builtins.c (

[PATCH][AArch64 array_mode 1/8] Rename vec_store_lanes_lane to aarch64_vec_store_lanes_lane

2015-09-15 Thread Alan Lawrence
vec_store_lanes{oi,ci,xi}_lane are not standard pattern names, so using them in aarch64-simd.md is misleading. This adds an aarch64_ prefix to those pattern names, paralleling aarch64_vec_load_lanes_lane. bootstrapped and check-gcc on aarch64-none-linux-gnu gcc/ChangeLog: * config/aarc

Re: [patch] Get rid of useless EH cleanups at -O0

2015-09-15 Thread Bernd Schmidt
On 09/14/2015 11:56 AM, Eric Botcazou wrote: this patchlet makes it possible to get rid of useless EH cleanups generated at -O0 in Ada for simple constructs involving VLAs: declare S : String (1 .. N); begin ... end; by duplicating finally blocks that contain only a stack re

Re: [patch] Bump size of stack checking protection area

2015-09-15 Thread Bernd Schmidt
On 09/15/2015 09:50 AM, Eric Botcazou wrote: It's not Ada-specific in the sense that, if you want to raise an exception on a stack overflow in any language with the middle-end SJLJ scheme, the current setting is definitely not sufficient and you'll get a crash during unwinding. For avoidance o

Re: [PATCH, PR67405, committed] Avoid NULL pointer dereference

2015-09-15 Thread Ilya Enkovich
2015-09-13 16:36 GMT+03:00 Richard Biener : > On Mon, Sep 7, 2015 at 2:39 PM, Ilya Enkovich wrote: >> 2015-09-02 15:35 GMT+03:00 Richard Biener : >>> >>> DECL_FIELD_BIT_OFFSET should be never NULL. Whoever created that >>> FIELD_DECL created an invalid one. >>> >>> Richard. >>> >> >> layout_class

Re: [PATCH][AArch64 array_mode 3/8] Stop using EImode in aarch64-simd.md and iterators.md

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:38AM +0100, Alan Lawrence wrote: > The V_THREE_ELEM attribute used BLKmode for most sizes, but occasionally > EImode. This patch changes to BLKmode in all cases, explicitly setting > memory size (thus, preserving size for the cases that were EImode, and > setting size

Re: [PATCH][AArch64 array_mode 4/8] Remove EImode

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:39AM +0100, Alan Lawrence wrote: > This removes EImode from the (AArch64) compiler, and all mention of or > support for it. OK. Thanks, James > > bootstrapped and check-gcc on aarch64-none-linux-gnu > > gcc/ChangeLog: > > * config/aarch64/aarch64.c (aarch64

Re: [PATCH][AArch64 array_mode 5/8] Remove V_FOUR_ELEM, again using BLKmode + set_mem_size.

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:40AM +0100, Alan Lawrence wrote: > This removes V_FOUR_ELEM in the same way that patch 3 removed V_THREE_ELEM, > again using BLKmode + set_mem_size. (This makes the four-lane expanders very > similar to the three-lane expanders, and they will be combined in patch 7.) >

Re: [PATCH][AArch64 array_mode 6/8] Remove V_TWO_ELEM, again using BLKmode + set_mem_size.

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:41AM +0100, Alan Lawrence wrote: > Same logic as previous; this makes the 2-, 3-, and 4-lane expanders all > follow the same pattern. > > bootstrapped and check-gcc on aarch64-none-linux-gnu. OK. Thanks, James > gcc/ChangeLog: > > * config/aarch64/aarch64-si

Re: [patch] Avoid #ifdef _GLIBCXX_DEBUG in regex_compiler.h

2015-09-15 Thread Jonathan Wakely
On 14/09/15 21:54 -0700, Tim Shen wrote: As for #ifdef _GLIBCXX_DEBUG, I think it's fine to delete them, since they seem not catching any useful bugs. Sounds good to me.

Re: [PATCH, ARM] Clean up arm_option_params_internals macro settings for attribute/pragma targets

2015-09-15 Thread Kyrill Tkachov
Hi Christian, On 14/09/15 10:05, Christian Bruel wrote: Hi, Prior sending the remaining target attributes, I'd like to simplify a few chunks (thinko) that were unnecessary complicated : The options checks in arm_option_params_internal can't be from another context than global_options. Hmmm..

Re: [patch match.pd c c++]: Ignore results of 'shorten_compare' and move missing patterns in match.pd

2015-09-15 Thread Kai Tietz
2015-09-15 0:45 GMT+02:00 Jeff Law : > On 09/08/2015 05:17 AM, Kai Tietz wrote: >> >> Hi, >> >> This patch is the first part of obsoleting 'shorten_compare' function >> for folding. >> It adjusts the uses of 'shorten_compare' to ignore folding returned by >> it, and adds >> missing pattterns to mat

Re: [PATCH][AArch64 array_mode 7/8] Combine the expanders using VSTRUCT:nregs

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:42AM +0100, Alan Lawrence wrote: > The previous patches leave ld[234]_lane, st[234]_lane, and ld[234]r expanders > all nearly identical, so we can easily parameterize across the number of > lanes and combine them. > > For the ld_lane pattern, I switched from the VCONQ

Re: [PATCH][AArch64 array_mode 8/8] Add d-registers to TARGET_ARRAY_MODE_SUPPORTED_P

2015-09-15 Thread James Greenhalgh
On Tue, Sep 15, 2015 at 10:14:43AM +0100, Alan Lawrence wrote: > This adds an AARCH64_VALID_SIMD_DREG_MODE exactly paralleling the existing > ...QREG... macro. > > The new test now compiles (at -O3) to: > > test_1: > add v1.2s, v1.2s, v5.2s > add v2.2s, v2.2s, v6.2s >

[PATCH 1/2] xtensa: fix TLS calls for call0 ABI

2015-09-15 Thread Max Filippov
2015-09-15 Max Filippov gcc/ * config/xtensa/xtensa.c (xtensa_call_tls_desc): Use a10 or a2 to pass TLS call argument, according to current ABI. * config/xtensa/xtensa.md (tls_call pattern): Use callx8 or callx0 for TLS call, according to current ABI. --- gcc/con

[PATCH 0/2] xtensa: call0 ABI fixes

2015-09-15 Thread Max Filippov
Hi Sterling, this series fixes two bugs in Xtensa call0 ABI support: callx8 unconditionally used for TLS calls and missing signal frame unwinding code for xtensa_fallback_frame_state. With these fixes uClibc testsuite results for windowed and call0 ABIs become identical. Max Filippov (2): xten

[PATCH 2/2] xtensa: fix xtensa_fallback_frame_state for call0 ABI

2015-09-15 Thread Max Filippov
2015-09-15 Max Filippov gcc/ * config/xtensa/xtensa.h (DWARF_ALT_FRAME_RETURN_COLUMN): New definition. (DWARF_FRAME_REGISTERS): Reserve space for one extra register in call0 ABI. libgcc/ * config/xtensa/linux-unwind.h (xtensa_fallback_frame_state):

Re: [patch match.pd c c++]: Ignore results of 'shorten_compare' and move missing patterns in match.pd

2015-09-15 Thread Richard Biener
On Tue, Sep 8, 2015 at 1:17 PM, Kai Tietz wrote: > Hi, > > This patch is the first part of obsoleting 'shorten_compare' function > for folding. > It adjusts the uses of 'shorten_compare' to ignore folding returned by > it, and adds > missing pattterns to match.pd to allow full bootstrap of C/C++ w

Re: [PATCH] Update ENABLE_CHECKING to make it usable in "if" conditions

2015-09-15 Thread Richard Biener
On Mon, Sep 14, 2015 at 8:41 PM, Jeff Law wrote: > On 09/14/2015 04:11 AM, Richard Biener wrote: >> >> On Wed, Sep 9, 2015 at 11:07 PM, Jeff Law wrote: >>> >>> On 08/31/2015 05:30 AM, Richard Biener wrote: On Mon, Aug 31, 2015 at 7:49 AM, Mikhail Maltsev wrote: > > >>

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Richard Biener
On Thu, Sep 10, 2015 at 10:28 PM, David Malcolm wrote: > This patch adds source *range* information to libcpp's cpp_token, and to > c_token and cp_token in the C and C++ frontends respectively. > > To minimize churn, I kept the existing location_t fields, though in > theory these are always just e

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Jakub Jelinek
On Tue, Sep 15, 2015 at 12:14:22PM +0200, Richard Biener wrote: > > diff --git a/gcc/cp/parser.h b/gcc/cp/parser.h > > index 760467c..c7558a0 100644 > > --- a/gcc/cp/parser.h > > +++ b/gcc/cp/parser.h > > @@ -61,6 +61,8 @@ struct GTY (()) cp_token { > >BOOL_BITFIELD purged_p : 1; > >/* The

Re: [patch] Get rid of useless EH cleanups at -O0

2015-09-15 Thread Richard Biener
On Tue, Sep 15, 2015 at 11:18 AM, Bernd Schmidt wrote: > On 09/14/2015 11:56 AM, Eric Botcazou wrote: > >> this patchlet makes it possible to get rid of useless EH cleanups >> generated at >> -O0 in Ada for simple constructs involving VLAs: >> >>declare >> S : String (1 .. N); >>begin

Re: [PATCH, PR67405, committed] Avoid NULL pointer dereference

2015-09-15 Thread Richard Biener
On Tue, Sep 15, 2015 at 11:28 AM, Ilya Enkovich wrote: > 2015-09-13 16:36 GMT+03:00 Richard Biener : >> On Mon, Sep 7, 2015 at 2:39 PM, Ilya Enkovich wrote: >>> 2015-09-02 15:35 GMT+03:00 Richard Biener : DECL_FIELD_BIT_OFFSET should be never NULL. Whoever created that FIELD_DECL

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Richard Biener
On Tue, Sep 15, 2015 at 12:20 PM, Jakub Jelinek wrote: > On Tue, Sep 15, 2015 at 12:14:22PM +0200, Richard Biener wrote: >> > diff --git a/gcc/cp/parser.h b/gcc/cp/parser.h >> > index 760467c..c7558a0 100644 >> > --- a/gcc/cp/parser.h >> > +++ b/gcc/cp/parser.h >> > @@ -61,6 +61,8 @@ struct GTY ((

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Jakub Jelinek
On Tue, Sep 15, 2015 at 12:33:58PM +0200, Richard Biener wrote: > On Tue, Sep 15, 2015 at 12:20 PM, Jakub Jelinek wrote: > > On Tue, Sep 15, 2015 at 12:14:22PM +0200, Richard Biener wrote: > >> > diff --git a/gcc/cp/parser.h b/gcc/cp/parser.h > >> > index 760467c..c7558a0 100644 > >> > --- a/gcc/c

Re: [PATCH, PR67405, committed] Avoid NULL pointer dereference

2015-09-15 Thread Ilya Enkovich
2015-09-15 13:32 GMT+03:00 Richard Biener : > On Tue, Sep 15, 2015 at 11:28 AM, Ilya Enkovich > wrote: >> 2015-09-13 16:36 GMT+03:00 Richard Biener : >>> On Mon, Sep 7, 2015 at 2:39 PM, Ilya Enkovich >>> wrote: 2015-09-02 15:35 GMT+03:00 Richard Biener : > > DECL_FIELD_BIT_OFFSET s

[Committed] S/390: Add missing brackets

2015-09-15 Thread Andreas Krebbel
gcc/ChangeLog: 2015-09-15 Andreas Krebbel * config/s390/s390.c (s390_const_operand_ok): Add missing brackets. Index: gcc/config/s390/s390.c === --- gcc/config/s390/s390.c (revision 227779) +++ gcc/config/s390

Re: [PATCH] vectorizing conditional expressions (PR tree-optimization/65947)

2015-09-15 Thread Richard Biener
On Fri, Sep 11, 2015 at 6:29 PM, Ramana Radhakrishnan wrote: > Saying that all reductions have equivalent performance is unlikely to be true for many platforms. On PowerPC, for example, a PLUS reduction has very different cost from a MAX reduction. If the model isn't fine-gra

Re: [patch] libstdc++/65142 Check read() result in std::random_device.

2015-09-15 Thread Jonathan Wakely
On 11/09/15 14:44 +0100, Jonathan Wakely wrote: We should not silently ignore a failure to read from the random device. Tested powerpc64le-linux, committed to trunk. I'm going to commit this to the gcc-5 branch too. commit 2d2f7012dc3744dafef0de94dd845bd190253dbd Author: Jonathan Wakely Da

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Manuel López-Ibáñez
On 15/09/15 12:20, Jakub Jelinek wrote: On Tue, Sep 15, 2015 at 12:14:22PM +0200, Richard Biener wrote: diff --git a/gcc/cp/parser.h b/gcc/cp/parser.h index 760467c..c7558a0 100644 --- a/gcc/cp/parser.h +++ b/gcc/cp/parser.h @@ -61,6 +61,8 @@ struct GTY (()) cp_token { BOOL_BITFIELD purged_p

Re: [PATCH] vectorizing conditional expressions (PR tree-optimization/65947)

2015-09-15 Thread Richard Biener
On Thu, Sep 10, 2015 at 4:51 PM, Alan Hayward wrote: > Hi, > This patch (attached) adds support for vectorizing conditional expressions > (PR 65947), for example: > > int condition_reduction (int *a, int min_v) > { > int last = 0; > for (int i = 0; i < N; i++) > if (a[i] < min_v) > l

Re: [PATCH] vectorizing conditional expressions (PR tree-optimization/65947)

2015-09-15 Thread Richard Biener
On Thu, Sep 10, 2015 at 4:51 PM, Alan Hayward wrote: > Hi, > This patch (attached) adds support for vectorizing conditional expressions > (PR 65947), for example: > > int condition_reduction (int *a, int min_v) > { > int last = 0; > for (int i = 0; i < N; i++) > if (a[i] < min_v) > l

CSE pass prevents loop-invariant motion

2015-09-15 Thread Robin Dapp
Hi, recently, I came across a problem that keeps a load instruction in a loop although it is loop-invariant. A simple example is: #include #define SZ 256 int a[SZ], b[SZ], c[SZ]; int main() { int i; for (i = 0; i < SZ; i++) { a[i] = b[i] + c[i]; } printf("%d\n", a[0]); } The re

Re: [PATCH 07/22] Implement token range tracking within libcpp and C/C++ FEs

2015-09-15 Thread Richard Biener
On Tue, Sep 15, 2015 at 2:08 PM, Manuel López-Ibáñez wrote: > On 15/09/15 12:20, Jakub Jelinek wrote: >> >> On Tue, Sep 15, 2015 at 12:14:22PM +0200, Richard Biener wrote: diff --git a/gcc/cp/parser.h b/gcc/cp/parser.h index 760467c..c7558a0 100644 --- a/gcc/cp/parser.h ++

  1   2   >