[PATCH 7/7] make targetm.gen_ccmp{first,next} take rtx_insn **

2016-10-17 Thread tbsaunde+gcc
From: Trevor Saunders gcc/ChangeLog: 2016-10-17 Trevor Saunders * ccmp.c (expand_ccmp_expr_1): Adjust. (expand_ccmp_expr): Likewise. (expand_ccmp_next): Likewise. * config/aarch64/aarch64.c (aarch64_gen_ccmp_next): Likewise. (aarch64_gen_ccmp_first): L

Re: [PATCH] (PR 65950) Improve predicate for exit(0);

2016-10-17 Thread Andrew Pinski
On Wed, Sep 21, 2016 at 1:53 AM, Richard Biener wrote: > On Wed, Sep 21, 2016 at 10:45 AM, Andrew Pinski wrote: >> On Wed, Sep 21, 2016 at 4:32 PM, Richard Biener >> wrote: >>> On Wed, Sep 21, 2016 at 9:13 AM, Andrew Pinski wrote: Hi, While looking through bug reports, I noticed som

Re: [PATCH] read-md.c: Move various state to within class rtx_reader (v3)

2016-10-17 Thread Richard Sandiford
David Malcolm writes: >> I assume you didn't turn the functions above into member functions >> because they aren't primitives. OTOH it might seem inconsistent >> to have things like traverse_enum_types as member functions but >> traverse_md_constants not. > > In the following I've converted trave

Re: RFC [1/3] divmod transform v2

2016-10-17 Thread Jeff Law
On 10/15/2016 11:59 PM, Prathamesh Kulkarni wrote: This patch is mostly the same as previous one, except it drops targeting __udivmoddi4() because it gave undefined reference link error for calling __udivmoddi4() on aarch64-linux-gnu. It appears aarch64 has hardware insn for DImode div, so __udiv

Re: [PATCH] PR77895: DWARF: Emit DW_AT_comp_dir in all cases, even if source is an absolute path

2016-10-17 Thread Mike Stump
On Oct 17, 2016, at 11:00 AM, Ximin Luo wrote: > Therefore, it is better to emit it in all circumstances, in case the reader > needs to know what the working > directory was at compile-time. I can't help but wonder if this would break ccache some?

[PATCH] DWARF5 DW_TAG_call_site support

2016-10-17 Thread Jakub Jelinek
Hi! This is on top of the http://gcc.gnu.org/ml/gcc-patches/2016-10/msg01202.html patch. This is yet another GNU extension that got accepted into DWARF5, though in this case various attributes got renamed (other than just dropping GNU_ middle parts), or extra attributes have been added instead of

Re: [PATCH] PR77895: DWARF: Emit DW_AT_comp_dir in all cases, even if source is an absolute path

2016-10-17 Thread Ximin Luo
Mike Stump: > On Oct 17, 2016, at 11:00 AM, Ximin Luo wrote: >> Therefore, it is better to emit it in all circumstances, in case the reader >> needs to know what the working >> directory was at compile-time. > > I can't help but wonder if this would break ccache some? > Could you explain this

[PATCH] DWARF5 DW_FORM_data16 support

2016-10-17 Thread Jakub Jelinek
Hi! DWARF5 has a new 128-bit constant class form, this patch uses it e.g. for __int128 values. Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk? 2016-10-17 Jakub Jelinek * dwarf2out.c (size_of_die, value_format, output_die): Use DW_FORM_data16 for 128-bit d

Re: [PATCH] PR77895: DWARF: Emit DW_AT_comp_dir in all cases, even if source is an absolute path

2016-10-17 Thread Mike Stump
On Oct 17, 2016, at 2:38 PM, Ximin Luo wrote: > > Mike Stump: >> On Oct 17, 2016, at 11:00 AM, Ximin Luo wrote: >>> Therefore, it is better to emit it in all circumstances, in case the reader >>> needs to know what the working >>> directory was at compile-time. >> >> I can't help but wonder if

[PATCH] DWARF5 DW_FORM_implicit_const support

2016-10-17 Thread Jakub Jelinek
Hi! This patch starts using DW_FORM_implicit_const (new in DWARF5), though only for cases where the constants are the same among all DIEs with the same abbreviation (and only for abbrevs used only in the main compilation unit, because right now we don't give all DIEs abbreviations first before out

Re: [PATCH] fix outstanding -Wformat-length failures (pr77735 et al.)

2016-10-17 Thread Martin Sebor
On 10/17/2016 01:11 PM, Jeff Law wrote: On 10/02/2016 02:10 PM, Martin Sebor wrote: The attached patch fixes a number of outstanding test failures and ILP32-related bugs in the gimple-ssa-sprintf pattch pointed out in bug 77676 and 77735). The patch also fixes c_strlen to correctly handle wid

[PATCH] Fix PR77916

2016-10-17 Thread Bill Schmidt
Hi, https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77916 identifies a situation where SLSR will ICE when exposed to a cast from integer to pointer. This is because we try to convert a PLUS_EXPR with an addend of -1 * S into a MINUS_EXPR with a subtrahend of S, but the base operand is unexpectedly o

Re: [patch v2] Get rid of stack trampolines for nested functions (0/4)

2016-10-17 Thread Eric Botcazou
> On ia64 I get this regression: > > FAIL: gcc.dg/Wtrampolines.c (test for warnings, line 31) > > Since ia64 never uses trampolines this is probably ok and the test > should be adjusted. This actually revealed a problem: the same regression should have appeared on PowerPC64/Linux (ELFv1 ABI) b

[PATCH] Remove leftover comment

2016-10-17 Thread Bill Schmidt
Whoops. Discovered I had inadvertently left in a comment that made no sense when fixing PR77916. This patch removes it. Committed as obvious. Thanks, Bill 2016-10-17 Bill Schmidt * gimple-ssa-strength-reduction.c (record_increment): Remove garbage comment. Index: gcc/gim

Re: [PATCH] rs6000: Fix separate shrink-wrapping for TARGET_MULTIPLE

2016-10-17 Thread Iain Sandoe
Hi Segher, > On 17 Oct 2016, at 09:13, Segher Boessenkool > wrote: > > We cannot use {SAVE,REST}_MULTIPLE and separate shrink-wrapping together, > not without checking when actually emitting the prologue/epilogue that the > registers to save/restore are actually still one contiguous block up to

[PATCH] xtensa: don't use unwind-dw2-fde-dip with elf targets

2016-10-17 Thread Max Filippov
Define LIB2ADDEH_XTENSA_UNWIND_DW2_FDE to unwind-dw2-fde.c in xtensa/t-elf and to unwind-dw2-fde-dip.c in xtensa/t-linux and use LIB2ADDEH_XTENSA_UNWIND_DW2_FDE in LIB2ADDEH definition. 2016-10-17 Max Filippov libgcc/ * config/xtensa/t-elf (LIB2ADDEH_XTENSA_UNWIND_DW2_FDE): New

[patch, gfortran] PR48298 DTIO, implement size=

2016-10-17 Thread Jerry DeLisle
Hi all, The attached patch enables the size= specifier in a READ statement to work with child DTIO procedures. This is accomplished by moving the size_used variable from the dtp structure to the gfc_unit structure so that the accumulation of bytes during READ is carried across the procedures v

[PATCH] xtensa: add -mpreferred-stack-boundary option

2016-10-17 Thread Max Filippov
2016-05-24 Max Filippov gcc/ * config/xtensa/xtensa.opt (mpreferred-stack-boundary=): New option. * config/xtensa/xtensa.h (STACK_BOUNDARY): Redefine as 64 for windowed ABI/32 for call0 ABI. (PREFERRED_STACK_BOUNDARY): New definition. * config/xten

Re: [patch, gfortran] PR48298 DTIO, implement size=

2016-10-17 Thread Steve Kargl
On Mon, Oct 17, 2016 at 06:02:52PM -0700, Jerry DeLisle wrote: > Hi all, > > The attached patch enables the size= specifier in a READ statement to work > with > child DTIO procedures. This is accomplished by moving the size_used variable > from the dtp structure to the gfc_unit structure so tha

Re: [PATCH] Fix PR77916

2016-10-17 Thread Markus Trippelsdorf
On 2016.10.17 at 17:23 -0500, Bill Schmidt wrote: > Hi, > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77916 identifies a situation > where SLSR will ICE when exposed to a cast from integer to pointer. This > is because we try to convert a PLUS_EXPR with an addend of -1 * S into a > MINUS_EXPR

Re: [PATCH] Fix PR77916

2016-10-17 Thread Markus Trippelsdorf
On 2016.10.18 at 05:13 +0200, Markus Trippelsdorf wrote: > On 2016.10.17 at 17:23 -0500, Bill Schmidt wrote: > > Hi, > > > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77916 identifies a situation > > where SLSR will ICE when exposed to a cast from integer to pointer. This > > is because we try

Re: RFC [1/3] divmod transform v2

2016-10-17 Thread Prathamesh Kulkarni
On 18 October 2016 at 02:46, Jeff Law wrote: > On 10/15/2016 11:59 PM, Prathamesh Kulkarni wrote: >> >> This patch is mostly the same as previous one, except it drops >> targeting __udivmoddi4() because it gave undefined reference link >> error for calling __udivmoddi4() on aarch64-linux-gnu. It a

Re: Use FOR_ALL_BB_FN in a few more places (was: [PATCH] Clear BB_VISITED in bb-reorder)

2016-10-17 Thread Richard Biener
On October 17, 2016 6:09:02 PM GMT+02:00, Thomas Schwinge wrote: >Hi! > >On Mon, 17 Oct 2016 15:17:13 +0200, Richard Biener > wrote: >> On Mon, Oct 17, 2016 at 3:12 PM, Thomas Schwinge >> wrote: >> > On Mon, 17 Oct 2016 14:26:42 +0200 (CEST), Richard Biener > wrote: >> >> --- gcc/bb-reorder.c (

Re: [PATCH] Clear BB_VISITED in bb-reorder

2016-10-17 Thread Andrew Pinski
On Mon, Oct 17, 2016 at 5:26 AM, Richard Biener wrote: > > $subject, applied as obvious. I think you should do the same for the vectorizer too. I noticed that when testing the patch for loop splitting. Thanks, Andrew > > Richard. > > 2016-10-17 Richard Biener > > * bb-reorder.c (reo

[patch] Fix PHI optimization issue with boolean types

2016-10-17 Thread Eric Botcazou
Hi, this is a regression present on the mainline and 6 branch: the compiler now generates wrong code for the attached testcase at -O because of an internal conflict about boolean types. The sequence is as follows. In .mergephi3: boolean _22; p__enum res; : if (_22 != 0) goto ;

<    1   2