Re: RFA: PR 68913: Provide weak version of __fread_chk for PR61886 test

2015-12-21 Thread Jeff Law
On 12/18/2015 10:07 AM, Nick Clifton wrote: Hi Guys, PR 68913 notes that the test gcc.dg/lto/pr61886_0.c test fails on targets whose C library does not provide a __fread_chk function. Since the purpose of the test is to show that GCC will correctly discard the invocation of

[PATCH] [graphite] Fix computation of single entry/exit of a region.

2015-12-21 Thread Aditya Kumar
For basic block with two preds, allow (as single entry) only when the other edge is a backedge. Similarly for basic block with two succs, allow (as single exit) only when the other edge is a back edge. 2015-12-21 Aditya Kumar * graphite-scop-detection.c

Re: [PATCH 2/2] PR c++/68819: libcpp fallbacks and -Wmisleading-indentation

2015-12-21 Thread Jeff Law
On 12/18/2015 01:21 PM, David Malcolm wrote: I don't think there's a way to fix -Wmisleading-indentation if we're in this state, so the first part of the following patch detects if this has happened, and effectively turns off -Wmisleading-indentation from that point onwards. To avoid a false

Re: [PATCH 2/2] PR c++/68819: libcpp fallbacks and -Wmisleading-indentation

2015-12-21 Thread Jakub Jelinek
On Mon, Dec 21, 2015 at 02:10:17PM -0700, Jeff Law wrote: > On 12/18/2015 01:21 PM, David Malcolm wrote: > > >I don't think there's a way to fix -Wmisleading-indentation if we're > >in this state, so the first part of the following patch detects if > >this has happened, and effectively turns off

Re: Fix PR67639

2015-12-21 Thread Jeff Law
On 12/18/2015 11:38 AM, Bernd Schmidt wrote: In an earlier fix, the following change was made in varasm.c for invalid register variables: --- trunk/gcc/varasm.c2014/08/26 14:59:59214525 +++ trunk/gcc/varasm.c2014/08/26 17:06:31214526 @@ -1371,6 +1371,11 @@ make_decl_rtl (tree

Re: [PATCH 1/2] libcpp: Avoid unnecessary ad-hoc uses for large source files

2015-12-21 Thread Jeff Law
On 12/18/2015 01:21 PM, David Malcolm wrote: When debugging PR c++/68819 I noticed an inefficiency during the handling of locations > LINE_MAP_MAX_LOCATION_WITH_COLS. When combining ranges for locations with start == caret == finish (with a NULL data ptr) get_combined_adhoc_loc was always

Re: varpool/constpool bug

2015-12-21 Thread Jeff Law
On 12/19/2015 09:47 AM, Nathan Sidwell wrote: Either build_constant_desc (varasm.c) should put constants into the varpool or decl_in_symtab_p should ignore constant pool VAR_DECLS. It appears to me that the latter is the right choice, as constant pool entries can't be related to regular

Re: Fix PR66206

2015-12-21 Thread Jeff Law
On 12/17/2015 06:00 PM, Bernd Schmidt wrote: This is a small problem found by a static analyzer, a function in bt-load can in theory return the address of a local variable. Bootstrapped and tested on x86_64-linux, ok? OK. jeff

Re: [PATCH] [PR rtl-optimization/49847] Fix ICE in CSE due to cc0-setter and cc0-user in different blocks

2015-12-21 Thread Jeff Law
On 12/18/2015 10:17 AM, Jeff Law wrote: This patch handles that return value in the caller. I've verified the reduced testcase and original testcase now compile without problems with a cross compiler. I've also done an x86_64-linux-gnu bootstrap & regression test (though we know that's of

Re: [patch] Fix PR debug/60756

2015-12-21 Thread Jeff Law
On 12/21/2015 08:46 AM, Eric Botcazou wrote: Hi, it's the failure of gcc.dg/guality/param-3.c on Aarch64. The strategy to make it pass is to selectively disable -fvar-tracking-assignments for parameters so that the location instead of the value is tracked; this was already working for most

Re: [Patch testsuite] Skip gcc.dg/ifcvt-4.c for targets on which it may not work

2015-12-21 Thread Jeff Law
On 12/18/2015 02:55 AM, James Greenhalgh wrote: This is a multi-part message in MIME format. --2.2.0.1.gd394abb.dirty Content-Type: text/plain; charset=UTF-8; format=fixed Content-Transfer-Encoding: 8bit Hi, PR68232 is a testsuite failure for targets with very low branch costs. As

Re: [PATCH] [C++] Fix read of uninitialized value in make_pack_expansion()

2015-12-21 Thread Jason Merrill
OK, thanks. Jason

Re: Go patch committed: Fix passing zero-sized global variable to function

2015-12-21 Thread Andrew Pinski
On Mon, Dec 21, 2015 at 4:10 PM, Ian Lance Taylor wrote: > The GNU linker doesn't support a zero-sized global variable that is > dynamically exported, so gccgo generates those global variables with a > size of 1 byte. Unfortunately, that means that passing a global > variable to

Go patch committed: Fix passing zero-sized global variable to function

2015-12-21 Thread Ian Lance Taylor
The GNU linker doesn't support a zero-sized global variable that is dynamically exported, so gccgo generates those global variables with a size of 1 byte. Unfortunately, that means that passing a global variable to a function that takes an argument of a zero-sized type will actually pass 1 byte,

[RFA] [PATCH][PR tree-optimization/64910] Fix reassociation of binary bitwise operations with 3 operands

2015-12-21 Thread Jeff Law
As outlined in the BZ, given (x & y) & C reassociation will turn that into (x & C) & y Which inhibits bit operations on various targets. Associating as (x & y) & C is what we want. My original patch did this for all binary operations. However, reviewing the assembly code & dump files

[PATCH] Fix constexpr evaluation of comparisons involving pointer-to-members

2015-12-21 Thread Patrick Palka
We are currently failing to fold equality comparisons involving PTRMEM_CSTs since (I think) r229018 thus making this a GCC 6 regression. This regression shows up in the boost testsuite. Fixed in a straightforward way. OK to commit after bootstrap + regtest? gcc/cp/ChangeLog: *

Re: Go patch committed: Fix passing zero-sized global variable to function

2015-12-21 Thread Ian Lance Taylor
On Mon, Dec 21, 2015 at 4:19 PM, Andrew Pinski wrote: > On Mon, Dec 21, 2015 at 4:10 PM, Ian Lance Taylor wrote: >> The GNU linker doesn't support a zero-sized global variable that is >> dynamically exported, so gccgo generates those global variables with a >>

[PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread Alan Lawrence
...the test passes with --param sra-max-scalarization-size-Ospeed. Verified on aarch64 and with stage1 compiler for hppa, powerpc, sparc, s390. On alpha, tree-optimized is: MEM[(int[8] *)] = { 0, 1 }; MEM[(int[8] *) + 8B] = { 2, 3 }; MEM[(int[8] *) + 16B] = { 4, 5 }; MEM[(int[8] *) +

Re: [PATCH/AARCH64] Fix -mcpu/arch=native support for LSE

2015-12-21 Thread Richard Earnshaw (lists)
On 11/12/15 19:54, Andrew Pinski wrote: > Hi, > The Linux kernel calls lse as atomics in /proc/cpuinfo. We should > change aarch64-option-extensions.def to take that into account. > > OK? Bootstrapped and tested on aarch64-linux-gnu with no regressions > and tested with -mcpu=native on

Re: [PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread David Edelsohn
On Mon, Dec 21, 2015 at 8:13 AM, Alan Lawrence wrote: > ...the test passes with --param sra-max-scalarization-size-Ospeed. > > Verified on aarch64 and with stage1 compiler for hppa, powerpc, sparc, s390. > > On alpha, tree-optimized is: > > MEM[(int[8] *)] = { 0, 1 }; >

RE: [BUILDROBOT] "error: null argument where non-null required" on multiple targets

2015-12-21 Thread Moore, Catherine
> -Original Message- > From: Jeff Law [mailto:l...@redhat.com] > Sent: Thursday, December 17, 2015 1:06 PM > To: Jan-Benedict Glaw > Cc: Moore, Catherine; Denis Chertykov; Eric Christopher; Matthew Fortune; > David Edelsohn; Alexandre Oliva; Kaz Kojima; Oleg Endo; Jonathan Wakely; >

Re: Fix lto-symtab ICE during Ada LTO bootstrap

2015-12-21 Thread Jan Hubicka
H.J., also once we get to bootstrapland with Ada and LTO, would be possible to enable it on the LTO bootstrap tester, so we won't break it again? Thanks, Honza

Re: Fix lto-symtab ICE during Ada LTO bootstrap

2015-12-21 Thread Jan Hubicka
Hi, the change in my patch was intentional, I forgot to send the email. Sorry for that. The reason is that labels/predictions/debug statements now go specially though DCE and are marked as neecessary, but not really handled so (i.e. we can remove conditional controlling only debug statements).

RE: [RFA] Compact EH Patch [Ping]

2015-12-21 Thread Moore, Catherine
> -Original Message- > From: gcc-patches-ow...@gcc.gnu.org [mailto:gcc-patches- > ow...@gcc.gnu.org] On Behalf Of Moore, Catherine > Sent: Sunday, December 13, 2015 5:12 PM > To: Richard Henderson; gcc-patches@gcc.gnu.org > Cc: ja...@redhat.com; Matthew Fortune > Subject: RE: [RFA]

Re: [PATCHES, PING*5] Enhance standard DWARF for Ada

2015-12-21 Thread Pierre-Marie de Rodat
On 12/18/2015 09:23 PM, Pierre-Marie de Rodat wrote: On 12/18/2015 06:56 PM, Jason Merrill wrote: These broke a lot of tests in the GDB C++ testsuite. Specifically, the commit DWARF: handle variable-length records and variant parts Arg, sad to hear that! I did testing at some point

New debug counter for unreachable edges found in DOM

2015-12-21 Thread Jeff Law
I used this recently to help reduce an aarch64 bug. No sense in not pushing it into the trunk. Bootstrapped and regression tested on x86_64-linux-gnu. It may have been in an aarch64 bootstrap as well, I'm not entirely sure about that. Installed on the trunk. Jeff commit

Re: Fix lto-symtab ICE during Ada LTO bootstrap

2015-12-21 Thread Eric Botcazou
> It's apparently another bug in the DCE pass. But it comes from a stalled ABNORMAL flag after the FRE3 pass so: Index: tree-ssa-pre.c === --- tree-ssa-pre.c (revision 231856) +++ tree-ssa-pre.c (working copy) @@ -4128,6

Re: [v3 PATCH] PR libstdc++/66693

2015-12-21 Thread Jonathan Wakely
On 19/12/15 16:50 +0200, Ville Voutilainen wrote: PR libstdc++/66693 * include/std/tuple (tuple_element, tuple_size, tuple_element_t, __tuple_element_t): Move to... * include/std/utility: ...here. * testsuite/20_util/pair/astuple/astuple.cc: Adjust. *

Re: [PATCH][RTL-ifcvt] PR rtl-optimization/68841: Make sure one basic block doesn't clobber CC reg usage of the other

2015-12-21 Thread Kyrill Tkachov
On 18/12/15 13:16, Bernd Schmidt wrote: On 12/18/2015 02:07 PM, Kyrill Tkachov wrote: In this PR we have a THEN and an ELSE block where one uses the condition reg from the preceeding comparison but the other block has an arithmetic operation that clobbers the CC reg. ifcvt emits the latter

Re: [ARM] Fix ICE on Ada code with -mbig-endian -mhard-float

2015-12-21 Thread Eric Botcazou
> the attached Ada testcase triggers an ICE with -mbig-endian -mhard-float: And here it is. -- Eric Botcazoupackage body P is procedure Split (R : Rec; A, B, C, D : out Long_Float) is begin A := R.A; B := R.B; C := R.C; D := R.D; end; end P; package P is type Rec is

Re: Go patch committed: Fix passing zero-sized global variable to function

2015-12-21 Thread Ian Lance Taylor
On Mon, Dec 21, 2015 at 4:19 PM, Andrew Pinski wrote: > On Mon, Dec 21, 2015 at 4:10 PM, Ian Lance Taylor wrote: >> The GNU linker doesn't support a zero-sized global variable that is >> dynamically exported, so gccgo generates those global variables with a >>

[AArch32][NEON] Implementing vmaxnmQ_ST and vminnmQ_ST intrinsincs.

2015-12-21 Thread Bilyan Borisov
This patch implements the vmaxnmQ_ST and vminnmQ_ST intrinsincs. It also implements the __ARM_FEATURE_NUMERIC_MAXMIN macro, which is defined when __ARM_ARCH >= 8, and which enables the intrinsincs. Tested on arm-none-eabi, armeb-none-eabi, arm-none-linux-gnueabihf. --- gcc/ 2015-XX-XX Bilyan

Re: [patch] libstdc++/68276 and libstdc++68995 qualification in

2015-12-21 Thread Jonathan Wakely
On 21/12/15 13:02 +, Jonathan Wakely wrote: Two patches to add missing std:: qualification to prevent ADL problems. Both are regressions, 68276 only on trunk, but 68995 has Oops, I meant 68982 not 68276. Thanks, Ville. I'll rename the test.

Re: [PATCH] S/390: Allow to use r2 to r4 as literal pool base.

2015-12-21 Thread Jakub Jelinek
On Fri, Dec 18, 2015 at 11:21:38AM +0100, Dominik Vogt wrote: > Latest patch for r2 to r4, including a test case. > diff --git a/gcc/config/s390/s390.c b/gcc/config/s390/s390.c > index ed684af..cba88bb 100644 > --- a/gcc/config/s390/s390.c > +++ b/gcc/config/s390/s390.c > @@ -9584,10 +9584,17 @@

[patch] libstdc++/68276 and libstdc++68995 qualification in

2015-12-21 Thread Jonathan Wakely
Two patches to add missing std:: qualification to prevent ADL problems. Both are regressions, 68276 only on trunk, but 68995 has been broken since 4.8.0 (but only affects people mixing TR1 with C++11, and I was already rude about them in Bugzilla so won't do it again here ;-) Tested

[PATCH 2/4] Equate MEM_REFs and ARRAY_REFs in tree-ssa-scopedtables.c

2015-12-21 Thread Alan Lawrence
This is a respin of patches https://gcc.gnu.org/ml/gcc-patches/2015-10/msg03266.html and https://gcc.gnu.org/ml/gcc-patches/2015-10/msg03267.html, which were "too quickly" approved before concerns with efficiency were pointed out. I tried to change the hashing just in tree-ssa-dom.c using C++

[PATCH 3/4] Add a pass_copy_prop following pass_ch_vect

2015-12-21 Thread Alan Lawrence
This fixes the missed vectorization of gcc.dg/vect/pr65947-2.c following the previous patch, by cleaning up: i_49 = 1; ... goto ; : : <--- LOOP HEADER # i_53 = PHI into: : # i_53 = PHI Allowing scalar evolution and vectorization to proceed.

[PATCH 1/4] Make SRA scalarize constant-pool loads

2015-12-21 Thread Alan Lawrence
This is the same as the version conditionally approved near the end of stage 1 https://gcc.gnu.org/ml/gcc-patches/2015-11/msg01948.html, plus the requested comment and a couple of testcases for platforms where the constants are pushed into the constant pool. (I didn't commit this at the time

[PATCH 0/4 v3] Fix PR/63679 when --param sra-max-scalarization-size specified

2015-12-21 Thread Alan Lawrence
This is a respin of previous patch series: https://gcc.gnu.org/ml/gcc-patches/2015-10/msg03271.html Minus three of the smaller patches having already been committed; with the updated version of the main patch to SRA; and the patches to DOM reworked to avoid constructing gimple stmt's. IMHO this

Re: [Patch, libstdc++/68877] Reimplement __is_[nothrow_]swappable

2015-12-21 Thread Daniel Krügler
2015-12-14 21:48 GMT+01:00 Daniel Krügler : > This is a reimplementation of __is_swappable and > __is_nothrow_swappable according to > > http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/n4511.html > > and also adds a missing usage of __is_nothrow_swappable in the

[ARM] Fix ICE on Ada code with -mbig-endian -mhard-float

2015-12-21 Thread Eric Botcazou
Hi, the attached Ada testcase triggers an ICE with -mbig-endian -mhard-float: eric@polaris:~/build/gcc/arm-linux-gnueabi> gcc/xgcc -Bgcc -S p.adb -I gcc/ada/rts -mbig-endian -mhard-float +===GNAT BUG DETECTED==+ | 6.0.0 20151220 (experimental)

Re: C PATCH to add __atomic_fetch_* optimization for _Atomics (PR c/68908) (v2)

2015-12-21 Thread Marek Polacek
On Fri, Dec 18, 2015 at 09:10:13PM +, Joseph Myers wrote: > On Fri, 18 Dec 2015, Marek Polacek wrote: > > > + tree sz = TYPE_SIZE_UNIT (TREE_TYPE (lhs_type)); > > + rhs = fold_build2_loc (loc, MULT_EXPR, rhs_type, rhs, > > +convert (rhs_type, sz)); > >

Re: [PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread Bill Schmidt
On Mon, 2015-12-21 at 15:22 +, Alan Lawrence wrote: > On 21/12/15 14:59, Bill Schmidt wrote: > >>> > >>> On powerpc64, the test passes with -mcpu=power8 (the loop is vectorized > >>> as a > >>> reduction); however, without that, similar code is generated to Alpha (the > >>> vectorizer decides

Re: [PATCHES, PING*5] Enhance standard DWARF for Ada

2015-12-21 Thread Pierre-Marie de Rodat
On 12/21/2015 04:39 PM, Jason Merrill wrote: OK, thanks. Committed. Thank you again! -- Pierre-Marie de Rodat

Re: [PATCHES, PING*5] Enhance standard DWARF for Ada

2015-12-21 Thread Jason Merrill
OK, thanks. Jason

[patch] Fix PR debug/60756

2015-12-21 Thread Eric Botcazou
Hi, it's the failure of gcc.dg/guality/param-3.c on Aarch64. The strategy to make it pass is to selectively disable -fvar-tracking-assignments for parameters so that the location instead of the value is tracked; this was already working for most architectures but the calling convention of

[PATCH] [C++] Fix read of uninitialized value in make_pack_expansion()

2015-12-21 Thread Patrick Palka
Here we have forgotten to set the type_pack_expansion_p field of the local variable "ppd" before handing it over to cp_walk_tree / find_parameter_packs_r, which can then read this uninitialized field. This error was spotted when compiling boost under valgrind. >From what I can tell by the

Re: [PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread Bill Schmidt
On Mon, 2015-12-21 at 09:10 -0500, David Edelsohn wrote: > On Mon, Dec 21, 2015 at 8:13 AM, Alan Lawrence wrote: > > ...the test passes with --param sra-max-scalarization-size-Ospeed. > > > > Verified on aarch64 and with stage1 compiler for hppa, powerpc, sparc, s390. > > >

Re: [RFA] Transparent alias suport part 10: Fix base+offset alias analysis oracle WRT aliases

2015-12-21 Thread Uros Bizjak
Hello! > Re-testing shows ICE in Ada build. In general the symtabnodes are produced > transparently > on demand, so I do not see big problem in predicate using get_create, but > perhaps we could > think of changing this decision and manually adding symbols into symbol table > at a time > they

Re: Fix lto-symtab ICE during Ada LTO bootstrap

2015-12-21 Thread Eric Botcazou
> I suppose the CFG verifier should also catch this. I wonder how this can > lead to wrong code as opossed to infinite loop? > I can imagine DCE being confused about non-control-flow stmt and conclude > the abnormal path as the path leaving the loop. I will look into the > testcase more. :

Re: [PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread Alan Lawrence
On 21/12/15 14:59, Bill Schmidt wrote: On powerpc64, the test passes with -mcpu=power8 (the loop is vectorized as a reduction); however, without that, similar code is generated to Alpha (the vectorizer decides the reduction is not worthwhile without SIMD support), and the test fails; hence,

Re: [PATCH 4/4] Un-XFAIL ssa-dom-cse-2.c for most platforms

2015-12-21 Thread Alan Lawrence
On 21/12/15 14:59, Bill Schmidt wrote: On powerpc64, the test passes with -mcpu=power8 (the loop is vectorized as a reduction); however, without that, similar code is generated to Alpha (the vectorizer decides the reduction is not worthwhile without SIMD support), and the test fails; hence,