[PATCH, testsuite] Allow braces around relative line numbers

2017-03-27 Thread Tom de Vries
Hi, this patch fixes testsuite PR80220 - "relative line numbers don't work when put between braces". Consider gcc/testsuite/gcc.dg/990506-0.c, which has absolute line numbers between braces: ... $ cat -n 990506-0.c 1 /* Verify that a diagnostic is issued without crashing due to 2

[PATCH committed] avoid name lookup warning in tree.c

2017-03-27 Thread Markus Trippelsdorf
In stage1 with -std=gnu++98 I see: /home/markus/gcc/gcc/tree.c: In function ‘void inchash::add_expr(const_tree, inchash::hash&, unsigned int)’: /home/markus/gcc/gcc/tree.c:8013:11: warning: name lookup of ‘i’ changed for (i = TREE_OPERAND_LENGTH (t) - 1; i >= 0; --i) ^ /home/mark

[PATCH][P1][PR tree-optimization/80216] Avoid infinite recursion in DOM

2017-03-27 Thread Jeff Law
A dumb mistake on my part, we can have a self-referencing definition statement inside a loop. That will cause the recently added code to walk back through BIT_IOR_EXPRs to recurse forever. I've added a trivial recursion depth limit. Bootstrapped and regression tested on x86_64-linux-gnu. I

Re: [patch] Clarify interaction of -Wnarrowing with -std

2017-03-27 Thread Jonathan Wakely
On 27/03/17 10:09 +0100, Jonathan Wakely wrote: On 26/03/17 14:32 -0600, Sandra Loosemore wrote: On 03/26/2017 02:13 PM, Gerald Pfeifer wrote: Hi Jonathan, On Tue, 23 Feb 2016, Jonathan Wakely wrote: On 19/02/16 13:17 -0700, Sandra Loosemore wrote: I suppose the patch is OK as it stands, but

Re: [PATCH] Fix calls.c for a _complex type (PR ipa/80104).

2017-03-27 Thread Martin Jambor
Hi, On Mon, Mar 27, 2017 at 12:15:10PM -0600, Jeff Law wrote: > On 03/27/2017 05:40 AM, Martin Liška wrote: > > Hello. > > > > There's alternative approach suggested by Martin Jambor. > > Patch can bootstrap on ppc64le-redhat-linux and survives regression tests > > and > > s390x cross compiler d

Re: [Patch, Fortran, OOP] PR 78661: Namelist output missing object designator under DTIO

2017-03-27 Thread Janus Weil
Forgot to mention: The patch was pre-approved by Jerry, but of course I'm happy to make corrections (if necessary). Cheers, Janus 2017-03-27 22:50 GMT+02:00 Janus Weil : > Hi all, > > I intend to commit the attached patch for a problem with derived-type > I/O and namelist output by tomorrow, if

[Patch, Fortran, OOP] PR 78661: Namelist output missing object designator under DTIO

2017-03-27 Thread Janus Weil
Hi all, I intend to commit the attached patch for a problem with derived-type I/O and namelist output by tomorrow, if there are no objections. The dtio_25.f90 test case needed some adjustments (see the discussion on bugzilla) and still contains a FIXME note, which will be fixed by Jerry's upcoming

[PATCH] S/390: Optimize atomic_compare_exchange and atomic_compare builtins.

2017-03-27 Thread Dominik Vogt
The attached patch optimizes the atomic_exchange and atomic_compare patterns on s390 and s390x (mostly limited to SImode and DImode). Among general optimizaation, the changes fix most of the problems reported in PR 80080: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80080 Bootstrapped and regress

Re: [PATCH] [ARC] Define _REENTRANT when -pthread is passed.

2017-03-27 Thread Andrew Burgess
* Claudiu Zissulescu [2017-03-27 13:13:13 +0200]: > Hi Andrew, > > This is a patch which originally has been made by Thomas. As I did > arange it, I cannot push it. > > Original patch message: > > The compiler is supposed to have the builtin defined _REENTRANT defined > when -pthread is passe

Re: [PATCH] [ARC] Update ARC SIMD patterns.

2017-03-27 Thread Andrew Burgess
* Claudiu Zissulescu [2017-03-27 13:10:12 +0200]: > Hi Andrew, > > vec_select expects in selection a list of subparts. The old ARC SIMD > extension instructions were not up-to-date, update them. > > Whithout this patch ARC backend is broken. It will be great if we can have it > in before gcc7

Re: [PATCH #2, rs6000][GCC6] Fix PR78543, ICE in push_reload on powerpc64le-linux-gnu

2017-03-27 Thread Michael Meissner
On Fri, Mar 24, 2017 at 07:16:32PM -0500, Segher Boessenkool wrote: > Hi Mike, > > This patch is okay for trunk. Also for 6, but what is the hurry there? I applied the patch (svn id 246508 for trunk, svn id 246509 for gcc 6.0). The hurry up for GCC 6 is due to the fact that the bug does not sho

RE: [PATCH,testsuite] Skip pic-3,4.c and pie-3,4.c for mips*-*-linux-*.

2017-03-27 Thread Matthew Fortune
Toma Tabacu writes: > The pic-3,4.c and pie-3,4.c tests are failing for some configurations of > mips*-*-linux-*. > > This is because PIC is always on for MIPS Linux by default, except when the > compiler is built with --with-mips-plt, in which case PIC is on by default > only > for the n64 ABI,

Re: Warning annoyances in list_read.c

2017-03-27 Thread Dominique d'Humières
> Le 27 mars 2017 à 20:34, Marek Polacek a écrit : > > On Mon, Mar 27, 2017 at 11:18:46AM -0700, Jerry DeLisle wrote: >> Marek, >> >> Flame wars can be a little fun once in a while. >> >> I had previously tried the /* Fall through */ trick and it did not work as >> Dominique clarified in his n

Re: [PATCH] Fix calls.c for a _complex type (PR ipa/80104).

2017-03-27 Thread Jeff Law
On 03/27/2017 05:40 AM, Martin Liška wrote: Hello. There's alternative approach suggested by Martin Jambor. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests and s390x cross compiler does not ICE. Martin 0001-Fix-calls.c-for-a-_complex-type-PR-ipa-80104.patch From f9

Re: [PATCH] Don't cross-jump in between frame related and non-frame related insns (PR target/80102, take 4)

2017-03-27 Thread Jeff Law
On 03/26/2017 03:00 PM, Jakub Jelinek wrote: Hi! On Sat, Mar 25, 2017 at 07:45:53AM +0100, Jakub Jelinek wrote: On Fri, Mar 24, 2017 at 06:37:46PM -0500, Segher Boessenkool wrote: On Fri, Mar 24, 2017 at 08:36:16PM +0100, Jakub Jelinek wrote: + /* Skip over reg notes not related to CF

Re: [PATCH] Fix r242743 change of gcc/system.h

2017-03-27 Thread Jeff Law
On 03/19/2017 03:17 PM, Gunther Nikl wrote: Hello Paolo! Building older GCC releases with clang tends to issue warnings. This can be annoying especially when they originate from a header. While backporting r242743 I noticed that the non-C++ cases of the changed macro definitions in gcc/system.h

[PATCH] Fix ICE in fold_comparison with -fsanitize=shift (PR sanitizer/80067)

2017-03-27 Thread Marek Polacek
The code in fold_comparison calls save_expr on an expression and then tries to set a location of the expression. But since save_expr calls fold, it can produce an integer constant, so we must be more careful when setting its location. In this case we had (int) a > 646 where 'a' is signed char

Re: [PATCH #2, rs6000][GCC6] Fix PR78543, ICE in push_reload on powerpc64le-linux-gnu

2017-03-27 Thread Michael Meissner
On Fri, Mar 24, 2017 at 07:16:32PM -0500, Segher Boessenkool wrote: > Hi Mike, > > On Fri, Mar 24, 2017 at 07:23:02PM -0400, Michael Meissner wrote: > > Reload fumbles in certain conditions. > > Yeah. And it does not need bswap to get totally lost with this, so this > patch is a workaround, not

Re: [C/C++ PATCH] Fix ICEs with vector subscripting of register variables (PR middle-end/80162)

2017-03-27 Thread Marek Polacek
On Mon, Mar 27, 2017 at 12:06:03PM -0400, Jason Merrill wrote: > On Fri, Mar 24, 2017 at 2:55 PM, Jakub Jelinek wrote: > > c*_mark_addressable doesn't look through VIEW_CONVERT_EXPRs that > > vector subscripts are turned into, which means we don't diagnose > > taking address of e.g. a vector eleme

Re: [C/C++ PATCH] Fix ICEs with vector subscripting of register variables (PR middle-end/80162)

2017-03-27 Thread Jason Merrill
On Fri, Mar 24, 2017 at 2:55 PM, Jakub Jelinek wrote: > c*_mark_addressable doesn't look through VIEW_CONVERT_EXPRs that > vector subscripts are turned into, which means we don't diagnose > taking address of e.g. a vector element in a hard register. > > On the other side, I think we want to suppor

Re: PATCH for Re: Release notes for GCC 7?

2017-03-27 Thread Joseph Myers
On Mon, 27 Mar 2017, carl hansen wrote: > suggested additions: > > get and insert the latest libtool, which includes files: > libtool.m4 ltgcc.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4, > all way-old currently in gcc-7 libtool and auto* updates are only reasonable in developmen

Re: [PATCH] Fix expansion of initializer extensions (PR c/80163)

2017-03-27 Thread Jeff Law
On 03/24/2017 12:58 PM, Jakub Jelinek wrote: Hi! As can be seen on the following testcase, when expanding an extension in EXPAND_INITIALIZER context, we emit wrong extension operation (one depending on the signedness of the result type rather than on the signedness of the argument type, so e.g.

Re: [PATCH] Reject > word sign extensions in initializers (PR middle-end/80163)

2017-03-27 Thread Jeff Law
On 03/24/2017 01:27 PM, Jakub Jelinek wrote: Hi! I'm not aware of any target that would support sign extension of something that can't be folded in the compiler into some type larger than word/pointer. Zero extension is doable and assemble_variable is able to deal with it by emitting low/high s

Re: [PATCH] Real fix for AIX exception handling

2017-03-27 Thread David Edelsohn
> As far as I have discovered, the real problem with AIX exception handling is > that the exception landing pads are symbols that must not (but still are) > exported from shared libraries - even libstdc++. > > I'm wondering if attached libtool(!)-patch would fix even that GDB problem > once applied

Re: [PATCH] avoid cselib rtx_equal_for_cselib_1 infinite recursion (PR debug/80025)

2017-03-27 Thread Jeff Law
On 03/23/2017 02:39 PM, Jakub Jelinek wrote: Hi! On Thu, Mar 23, 2017 at 03:00:04PM +0100, Jakub Jelinek wrote: On Tue, Mar 21, 2017 at 07:43:51PM -0300, Alexandre Oliva wrote: When two VALUEs are recorded in the cselib equivalence table such that they are equivalent to each other XORed with t

[doc] install.texi -- update www-01.ibm.com link

2017-03-27 Thread Gerald Pfeifer
www-01.ibm.com switched back to www.ibm.com and to https by default, two changes I followed via the patch below. Looking at the interesting URL and having found https://www.ibm.com/support/knowledgecenter/ssw_aix_72/com.ibm.aix.cmds3/ld.html (which is version-specific, but the latest and I don't t

Re: [PATCH] Handle PHI nodes w/o a argument (PR ipa/80205).

2017-03-27 Thread Jeff Law
On 03/27/2017 08:27 AM, Richard Biener wrote: On Mon, Mar 27, 2017 at 4:14 PM, Richard Biener wrote: On Mon, Mar 27, 2017 at 2:47 PM, Martin Liška wrote: Hello. As described in the PR, we can create a PHI node in einline that has no argument. That can cause ICE in devirtualization and shoul

Re: [v3 PATCH] Slight cleanup of tuple constraints.

2017-03-27 Thread Jonathan Wakely
On 27/03/17 17:44 +0300, Ville Voutilainen wrote: This is not something that should go in at this stage, but I'm sending it for review. Dinka quite astutely pointed out that the sizeof...(_Elements)>=1 tests seem unnecessary, and they are; 1) the helper aliases _TCC and _TMC already check that t

[PATCH] Fix s390 testcase vcond-shift

2017-03-27 Thread Robin Dapp
Hi, this patch fixes the vcond shift testcase that failed since setting PARAM_MIN_VECT_LOOP_BOUND in the s390 backend. Regards Robin -- gcc/testsuite/ChangeLog: 2017-03-27 Robin Dapp * gcc.target/s390/vector/vcond-shift.c (void foo): Increase iteration count and assume ali

Re: [PATCH 1/5] nvptx: implement SIMT enter/exit insns

2017-03-27 Thread Bernd Schmidt
On 03/27/2017 12:56 PM, Alexander Monakov wrote: Hello Bernd, Can you have a look at this patch (unchanged from previous posting in January)? The rest of the patches in the set are reviewed. On Wed, 22 Mar 2017, Alexander Monakov wrote: This patch adds handling of new omp_simt_enter/omp_simt_

[v3 PATCH] Slight cleanup of tuple constraints.

2017-03-27 Thread Ville Voutilainen
This is not something that should go in at this stage, but I'm sending it for review. Dinka quite astutely pointed out that the sizeof...(_Elements)>=1 tests seem unnecessary, and they are; 1) the helper aliases _TCC and _TMC already check that the incoming pack and the element pack have the same

[pushed/ob] cplus_demangle_fill_component: Handle DEMANGLE_COMPONENT_RVALUE_REFERENCE (Re: [PATCH] libiberty: Initialize d_printing in all cplus_demangle_* functions.)

2017-03-27 Thread Pedro Alves
[added back gcc-patches, obvious libiberty patch below] On 03/14/2017 10:50 AM, Pedro Alves wrote: > On 03/14/2017 09:04 AM, Mark Wielaard wrote: > >> That looks good. But note that there is one behavioral change. >> cplus_demangle_fill_component is defined as: >> >> /* Fill in most component typ

Re: [PATCH] Handle PHI nodes w/o a argument (PR ipa/80205).

2017-03-27 Thread Richard Biener
On Mon, Mar 27, 2017 at 4:14 PM, Richard Biener wrote: > On Mon, Mar 27, 2017 at 2:47 PM, Martin Liška wrote: >> Hello. >> >> As described in the PR, we can create a PHI node in einline that has no >> argument. >> That can cause ICE in devirtualization and should be thus handled. >> >> Patch can

Re: [PATCH] Handle PHI nodes w/o a argument (PR ipa/80205).

2017-03-27 Thread Jeff Law
On 03/27/2017 08:14 AM, Richard Biener wrote: On Mon, Mar 27, 2017 at 2:47 PM, Martin Liška wrote: Hello. As described in the PR, we can create a PHI node in einline that has no argument. That can cause ICE in devirtualization and should be thus handled. Patch can bootstrap on ppc64le-redhat

Re: [PATCH] Handle PHI nodes w/o a argument (PR ipa/80205).

2017-03-27 Thread Richard Biener
On Mon, Mar 27, 2017 at 2:47 PM, Martin Liška wrote: > Hello. > > As described in the PR, we can create a PHI node in einline that has no > argument. > That can cause ICE in devirtualization and should be thus handled. > > Patch can bootstrap on ppc64le-redhat-linux and survives regression tests.

Re: [testsuite] Add missing dg-require-effective-target alloca to gcc testsuite

2017-03-27 Thread Tom de Vries
On 24/03/17 18:13, Mike Stump wrote: On Mar 24, 2017, at 5:58 AM, Rainer Orth wrote: - { /* { dg-warning "statement may fall through" "" { target c } 23 } */ - int a[i]; /* { dg-warning "statement may fall through" "" { target c++ } 24 } */ + { /* { dg-warning "statement may fa

Re: [testsuite] Add missing dg-require-effective-target alloca to gcc testsuite

2017-03-27 Thread Tom de Vries
On 24/03/17 13:38, Rainer Orth wrote: Hi Tom, On 23/03/17 18:25, Mike Stump wrote: On Mar 23, 2017, at 8:46 AM, Tom de Vries wrote: I've run the gcc testsuite for target nvptx-none and ran into "test for excess errors" FAILs due to: ... sorry, unimplemented: target cannot support alloca. We

[PATCH] Fix PR80181

2017-03-27 Thread Richard Biener
Bootstrapped and tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-03-27 Richard Biener PR tree-optimization/80181 * tree-ssa-ccp.c (likely_value): UNDEFINED ^ X is UNDEFINED. * gcc.dg/torture/pr80181.c: New testcase. Index: gcc/tree-ssa-ccp.c =

[PATCH] Handle PHI nodes w/o a argument (PR ipa/80205).

2017-03-27 Thread Martin Liška
Hello. As described in the PR, we can create a PHI node in einline that has no argument. That can cause ICE in devirtualization and should be thus handled. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin >From d0dc319a8df5d9f00434f54fef13

Re: [PATCH] gcov: Mark BBs that do not correspond to a line in source code (PR gcov-profile/79891).

2017-03-27 Thread Martin Liška
On 03/21/2017 07:39 PM, Nathan Sidwell wrote: > Martin, Richard, > I've read up on the thread, but I'm not sure where you guys are with an > actual patch. From what I Richard nailed it in BZ with the comment that the > BB should not be associated with any source line. That's a new thing, so I

Re: [PATCH] Fix calls.c for a _complex type (PR ipa/80104).

2017-03-27 Thread Martin Liška
Hello. There's alternative approach suggested by Martin Jambor. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests and s390x cross compiler does not ICE. Martin >From f9e40be62e525d29347339316073fae425b0d516 Mon Sep 17 00:00:00 2001 From: marxin Date: Fri, 24 Mar 2017 15:4

RE: [PATCH 0/5] [ARC] Fixes backend issues

2017-03-27 Thread Claudiu Zissulescu
Hi Andrew, > [ARC] Save/restore blink when in ISR. > [ARC] Fix detection of long immediate for load/store operands. > [ARC] Disable TP register when building for bare metal. > [ARC] Fix divdf3 emulation for arcem. > [ARC] Fix move_double_src_operand predicate. > All the above patches w

[PATCH] [ARC] Define _REENTRANT when -pthread is passed.

2017-03-27 Thread Claudiu Zissulescu
Hi Andrew, This is a patch which originally has been made by Thomas. As I did arange it, I cannot push it. Original patch message: The compiler is supposed to have the builtin defined _REENTRANT defined when -pthread is passed, which wasn't done on the ARC architecture. When _REENTRANT is not p

[PATCH, GCC/ARM, gcc-6-branch] Fix PR80082: LDRD erronously used for 64bit load on ARMv7-R

2017-03-27 Thread Thomas Preudhomme
Hi, Currently GCC is happy to use LDRD to perform a 64bit load on ARMv7-R, as shown by the testcase on this patch. However, LDRD is only atomic when LPAE extensions is available, which they are not for ARMv7-R. This commit solve the issue by introducing a new feature bit to distinguish LPAE exten

[PATCH] [ARC] Update ARC SIMD patterns.

2017-03-27 Thread Claudiu Zissulescu
Hi Andrew, vec_select expects in selection a list of subparts. The old ARC SIMD extension instructions were not up-to-date, update them. Whithout this patch ARC backend is broken. It will be great if we can have it in before gcc7.x branch is cut. Thank you, Claudiu gcc/ 2017-03-27 Claudiu Zis

Re: [PATCH 1/5] nvptx: implement SIMT enter/exit insns

2017-03-27 Thread Alexander Monakov
Hello Bernd, Can you have a look at this patch (unchanged from previous posting in January)? The rest of the patches in the set are reviewed. On Wed, 22 Mar 2017, Alexander Monakov wrote: > This patch adds handling of new omp_simt_enter/omp_simt_exit named insns > in the NVPTX backend. > >

[PATCH] Fix PR79776

2017-03-27 Thread Richard Biener
Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-03-27 Richard Biener PR ipa/79776 * tree-ssa-structalias.c (associate_varinfo_to_alias): Skip inlined thunk clones. * g++.dg/ipa/pr79776.C: New testcase. Index: gcc/tree-ssa-structalia

[PATCH] Real fix for AIX exception handling

2017-03-27 Thread Michael Haubenwallner
Hi, as far as I have discovered, the real problem with AIX exception handling is that the exception landing pads are symbols that must not (but still are) exported from shared libraries - even libstdc++. I'm wondering if attached libtool(!)-patch would fix even that GDB problem once applied to ea

Re: [patch] Clarify interaction of -Wnarrowing with -std

2017-03-27 Thread Jonathan Wakely
On 26/03/17 14:32 -0600, Sandra Loosemore wrote: On 03/26/2017 02:13 PM, Gerald Pfeifer wrote: Hi Jonathan, On Tue, 23 Feb 2016, Jonathan Wakely wrote: On 19/02/16 13:17 -0700, Sandra Loosemore wrote: I suppose the patch is OK as it stands, but I was going to suggest restructuring it so that

Re: PATCH for Re: Release notes for GCC 7?

2017-03-27 Thread carl hansen
suggested additions: get and insert the latest libtool, which includes files: libtool.m4 ltgcc.m4 lt~obsolete.m4 ltoptions.m4 ltsugar.m4 ltversion.m4, all way-old currently in gcc-7 get latest autoconf. 2.64 in use, latest is 2.69 get latest texinfo.tex, not one 5 years old GNU is supposed

[PATCH] Fix PR80170

2017-03-27 Thread Richard Biener
The following fixes a latent bug in vect dataref alignment analysis. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk. Richard. 2017-03-27 Richard Biener PR tree-optimization/80170 * tree-vect-data-refs.c (vect_compute_data_ref_alignment): Make s

Re: [PATCH] Fix asan/ubsan bitfield handling in VL structures (PR sanitizer/80168)

2017-03-27 Thread Richard Biener
On Fri, 24 Mar 2017, Jakub Jelinek wrote: > Hi! > > We ICE on the following testcase, because we attempt to use > DECL_BIT_FIELD_REPRESENTATIVE instead of original FIELD_DECL > in a COMPONENT_REF in a VL structure, but DECL_BIT_FIELD_REPRESENTATIVE's > DECL_FIELD_OFFSET is not really gimplified a

[PATCH] Fix PR80171

2017-03-27 Thread Richard Biener
Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-03-27 Richard Biener PR middle-end/80171 * gimple-fold.c (fold_ctor_reference): Properly guard against NULL return value from canonicalize_constructor_val. * g++.dg/torture/pr80171.C: N

Re: [patch, libgfortran] PR78881 [F03] reading from string with DTIO procedure does not work properly

2017-03-27 Thread Christophe Lyon
Hi, On 25 March 2017 at 19:49, Jerry DeLisle wrote: > On 03/25/2017 11:00 AM, Paul Richard Thomas wrote: >> >> Hi Jerry, >> >> This looks fine to me. OK for trunk. >> >> Thanks for the patch. >> >> Paul >> > > Thanks for review Paul. > > A gcc/testsuite/gfortran.dg/dtio_26.f03 >