Re: [PATCH]: Use HOST_WIDE_INT_{,M}1{,U} some more

2016-07-19 Thread Uros Bizjak
On Tue, Jul 19, 2016 at 8:39 PM, Mike Stump wrote: > On Jul 19, 2016, at 5:46 AM, Uros Bizjak wrote: >> >> The result of exercises with sed in gcc/ directory. >> >> 2016-07-19 Uros Bizjak >> >>* builtins.c: Use HOST_WIDE_INT_1

[Patch, testsuite, tentative] Explicitly disable pointer <-> int cast warnings for avr?

2016-07-19 Thread Senthil Kumar Selvaraj
Hi, The patch fixes a couple of testsuite failures that show up for the avr target because it has different sizes for longs and pointers (4 bytes versus 2), by explicitly disabling the warning for avr. Does this make sense? Skipping the test by requiring ptr32plus would have worked,

Re: C++ PATCH for c++/67164 (error with variadic templates)

2016-07-19 Thread Jason Merrill
On Thu, Mar 3, 2016 at 8:41 PM, Jason Merrill wrote: > When we instantiate an element of a pack expansion, we replace the argument > pack in the template argument vec with an ARGUMENT_PACK_SELECT which > indicates the desired element of the vec. If the args have been used to >

[VRP] Use alloc-pool and obstack for value_range and vr->equiv allocations

2016-07-19 Thread kugan
Hi Richard, As discussed in IPA-VRP discussion, this patch makes tree-vrp allocations use alloc-pool and obstack for value_range and vr->equiv respectively. Other allocations are rare and left as it is. Bootstrapped and regression tested on x86-64-linux with no new regressions. Is this OK

Re: [PATCH] Avoid invoking ranlib on libbackend.a

2016-07-19 Thread Andrew Pinski
On Tue, Jul 19, 2016 at 1:20 AM, Richard Biener wrote: > On Tue, Jul 19, 2016 at 2:39 AM, Patrick Palka wrote: >> On Mon, 18 Jul 2016, Segher Boessenkool wrote: >> >>> On Mon, Jul 18, 2016 at 06:35:11AM -0500, Segher Boessenkool wrote: >>> > Or,

Re: [PATCH] Fix unsafe function attributes for special functions (PR 71876)

2016-07-19 Thread Bernd Edlinger
On 07/19/16 19:30, Bernd Edlinger wrote: > On 07/19/16 18:37, Jakub Jelinek wrote: >> On Tue, Jul 19, 2016 at 04:20:55PM +, Bernd Edlinger wrote: >>> As discussed at https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71876, >>> we have a _very_ old hack in gcc, that recognizes certain functions by

Re: [PATCH] libstdc++/71856 Define _GLIBCXX_PARALLEL_ASSERTIONS

2016-07-19 Thread Jonathan Wakely
On 13/07/16 18:26 +0100, Jonathan Wakely wrote: This fixes a conflict between how Parallel Mode has always used the _GLIBCXX_ASSERTIONS macro and the new meaning we gave it for GCC 6 (enabling the lightweight debug checks). It doesn't make sense for Parallel Mode to own that macro, and it might

Re: [patch, Fortran] Fix some string temporaries

2016-07-19 Thread Thomas Koenig
Hi Mikael, Then handle the GFC_DEP_ERROR here. Or initialize fin_dep with GFC_DEP_NODEP at the beginning, as you prefer. OK with either (and the unreachable assertions). Here is the pacth the way I committed it. Thanks for the review and the comments. Regards Thomas 2016-07-19

Re: [RFC][IPA-VRP] Add support for IPA VRP in ipa-cp/ipa-prop

2016-07-19 Thread kugan
Hi Martin, On 19/07/16 18:22, kugan wrote: Hi Martin, Thanks for the review. I have revised the patch based on the review. Please see the comments below. Maybe it is better to separate value range and alignment summary writing/reading to different functions. Here is another updated

Re: [PATCH] Giant concepts patch

2016-07-19 Thread Jason Merrill
On Sun, Jul 10, 2016 at 11:20 AM, Andrew Sutton wrote: > I did find another bug building cmcstl2, hence the attached > disable-opt patch. For some reason, the memoization of concept > satisfaction is giving momoized results for concept + args that have > not yet been

Re: [PATCH, DOC] Enhance documentation of -fipa-ra option.

2016-07-19 Thread Jeff Law
On 07/19/2016 08:26 AM, Martin Liška wrote: On 07/19/2016 03:46 PM, Alexander Monakov wrote: So I decided to also mention this alias. Thoughts? I'd like the new ipa-ra text to go in, but perhaps you should consider leaving out option aliases out of this patch, especially given that it's

Re: [PATCH PR71503/PR71683]Fix ICE in tree-if-conv.c

2016-07-19 Thread Jeff Law
On 07/19/2016 07:39 AM, Bin.Cheng wrote: On Thu, Jul 14, 2016 at 6:49 PM, Jeff Law wrote: On 07/14/2016 10:12 AM, Bin Cheng wrote: Hi, This is a simple patch fixing ICE in tree-if-conv.c. Existing code does not setup a variable (cond) when predicate of basic block is true

Re: [RFC][IPA-VRP] Early VRP Implementation

2016-07-19 Thread Jeff Law
On 07/19/2016 12:35 PM, Richard Biener wrote: I wouldn't mind seeing tree-vrp broken down a little -- it's quite large and there's at least 4 distinct things going on in that file. 1. ASSERT_EXPR handling. 2. Arithmetic on ranges 3. Propagation engine setup, callbacks, etc 4. Range

Re: [PR debug/71855] avoid emitting DW_TAG_unspecified_parameters twice

2016-07-19 Thread Richard Biener
On July 19, 2016 9:01:07 PM GMT+02:00, Aldy Hernandez wrote: >Hi folks. > >Ben brought this bug to my attention which was causing a failure in >libabigail. > >The problem is that varargs functions are getting two >DW_TAG_unspecified_parameters DIEs, because they are being

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Aldy Hernandez
On 07/19/2016 01:47 PM, Jeff Law wrote: On 07/17/2016 09:52 AM, Manuel López-Ibáñez wrote: + if (is_vla) +gcc_assert (warn_vla_limit > 0); + if (!is_vla) +gcc_assert (warn_alloca_limit > 0); if-else ? Or perhaps: Shouldn't really matter, except perhaps in a -O0 compilation. Though

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Aldy Hernandez
On 07/19/2016 01:54 PM, Jeff Law wrote: On 07/19/2016 05:03 AM, Aldy Hernandez wrote: (Same thing with alloca). There should be no warning for VLAs, and for alloca, the warning should say "use of variable-length array within a loop." The VRP dump suggests the range information is available

[PR debug/71855] avoid emitting DW_TAG_unspecified_parameters twice

2016-07-19 Thread Aldy Hernandez
Hi folks. Ben brought this bug to my attention which was causing a failure in libabigail. The problem is that varargs functions are getting two DW_TAG_unspecified_parameters DIEs, because they are being emitted in early debug and again in late debug. This problem appears in GCC 6 and in

Re: [Fortran, Patch] First patch for coarray FAILED IMAGES (TS 18508)

2016-07-19 Thread Mikael Morin
Hello, this is mostly good in general, but is lacking tests. Especially, tests for successfull matching, and tests for every error you are adding in the patch (except maybe the -fcoarray= one). Also tests that the code executes successfullly with -fcoarray=single, and that it produces the

Re: [PATCH] Don't consider zero succs empty blocks as forwarders (PR rtl-optimization/71916)

2016-07-19 Thread Richard Biener
On July 19, 2016 7:27:30 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >Normally empty blocks without successors (result of >__builtin_unreachable () >somewhere in RTL) aren't considered as forwarder_block_p, because they >don't satisfy single_succ_p. But e.g. during cross-jumping

Re: [PATCH]: Use HOST_WIDE_INT_{,M}1{,U} some more

2016-07-19 Thread Mike Stump
On Jul 19, 2016, at 5:46 AM, Uros Bizjak wrote: > > The result of exercises with sed in gcc/ directory. > > 2016-07-19 Uros Bizjak > >* builtins.c: Use HOST_WIDE_INT_1 instead of (HOST_WIDE_INT) 1, >HOST_WIDE_INT_1U instead of (unsigned

Re: [RFC][IPA-VRP] Early VRP Implementation

2016-07-19 Thread Richard Biener
On July 19, 2016 6:19:23 PM GMT+02:00, Jeff Law wrote: >On 07/14/2016 10:52 PM, Andrew Pinski wrote: >> On Thu, Jul 14, 2016 at 9:45 PM, kugan >> wrote: >>> >>> Hi, >>> >>> >>> >>> This patch adds a very simple early vrp implementation. This

[v3 PATCH] Implement std::string_view and P0254r2, Integrating std::string_view and std::string.

2016-07-19 Thread Ville Voutilainen
Tested on Linux-x64. I'm quite sure there are cosmetic issues left in this patch, like in the section references of the tests. I will send it out for review now anyway. 2016-07-19 Ville Voutilainen Implement std::string_view and P0254r2, Integrating

[PATCH] nvptx: do not implicitly enable -ftoplevel-reorder

2016-07-19 Thread Alexander Monakov
Hi, I've recently committed a middle-end patch that adds handling of undefined variables (that the nvptx backend needs) under -fno-toplevel-reorder (svn rev. 238371). With that change, it's no longer necessary to implicitly enable -ftoplevel-reorder in the backend, and the following patch

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Manuel López-Ibáñez
On 19 July 2016 at 18:47, Jeff Law wrote: > On 07/17/2016 09:52 AM, Manuel López-Ibáñez wrote: >> >> + if (is_vla) >> +gcc_assert (warn_vla_limit > 0); >> + if (!is_vla) >> +gcc_assert (warn_alloca_limit > 0); >> >> if-else ? Or perhaps: > > Shouldn't really matter,

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Jeff Law
On 07/19/2016 05:03 AM, Aldy Hernandez wrote: (Same thing with alloca). There should be no warning for VLAs, and for alloca, the warning should say "use of variable-length array within a loop." The VRP dump suggests the range information is available within the loop. Is the get_range_info()

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Jeff Law
On 07/17/2016 09:52 AM, Manuel López-Ibáñez wrote: + if (is_vla) +gcc_assert (warn_vla_limit > 0); + if (!is_vla) +gcc_assert (warn_alloca_limit > 0); if-else ? Or perhaps: Shouldn't really matter, except perhaps in a -O0 compilation. Though I think else-if makes it slightly

Re: [PATCH] Fix unsafe function attributes for special functions (PR 71876)

2016-07-19 Thread Bernd Edlinger
On 07/19/16 18:37, Jakub Jelinek wrote: > On Tue, Jul 19, 2016 at 04:20:55PM +, Bernd Edlinger wrote: >> As discussed at https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71876, >> we have a _very_ old hack in gcc, that recognizes certain functions by >> name, and inserts in some cases unsafe

[PATCH] Don't consider zero succs empty blocks as forwarders (PR rtl-optimization/71916)

2016-07-19 Thread Jakub Jelinek
Hi! Normally empty blocks without successors (result of __builtin_unreachable () somewhere in RTL) aren't considered as forwarder_block_p, because they don't satisfy single_succ_p. But e.g. during cross-jumping fake edges to exit are added and then they suddenly satisfy this predicate, which

Re: [PATCH] Fix memmove to memcpy folding (PR middle-end/71874)

2016-07-19 Thread Richard Biener
On July 19, 2016 6:52:55 PM GMT+02:00, Jakub Jelinek wrote: >Hi! > >As mentioned in the PR and discussed on IRC, get_ref_base_and_extent >can return size != maxsize or maxsize -1 and then we really can't trust >the offset for the purposes we want. So this patch instead uses a

Re: [patch,avr] Slightly better memory accesses on avr_tiny

2016-07-19 Thread Denis Chertykov
2016-07-19 13:31 GMT+03:00 Georg-Johann Lay : > This patch tries to improve the bloated code we are currently generating for > AVR_TINY. It's mostly about printing the memory loads and stores and more > usage of reg_unused_after to print shorter instruction sequences in some >

[PATCH] Fix memmove to memcpy folding (PR middle-end/71874)

2016-07-19 Thread Jakub Jelinek
Hi! As mentioned in the PR and discussed on IRC, get_ref_base_and_extent can return size != maxsize or maxsize -1 and then we really can't trust the offset for the purposes we want. So this patch instead uses a different function that just computes the base and offset if the offset is constant;

Re: [PATCH] Fix unsafe function attributes for special functions (PR 71876)

2016-07-19 Thread Jakub Jelinek
On Tue, Jul 19, 2016 at 04:20:55PM +, Bernd Edlinger wrote: > As discussed at https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71876, > we have a _very_ old hack in gcc, that recognizes certain functions by > name, and inserts in some cases unsafe attributes, that don't work for > a freestanding

Re: [PATCH]: Use HOST_WIDE_INT_{,M}1{,U} some more

2016-07-19 Thread Uros Bizjak
On Tue, Jul 19, 2016 at 2:58 PM, Jakub Jelinek wrote: > On Tue, Jul 19, 2016 at 02:46:46PM +0200, Uros Bizjak wrote: >> The result of exercises with sed in gcc/ directory. >> >> 2016-07-19 Uros Bizjak >> >> * builtins.c: Use HOST_WIDE_INT_1 instead of

[PATCH] Fix unsafe function attributes for special functions (PR 71876)

2016-07-19 Thread Bernd Edlinger
Hi! As discussed at https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71876, we have a _very_ old hack in gcc, that recognizes certain functions by name, and inserts in some cases unsafe attributes, that don't work for a freestanding environment. It is unsafe to return ECF_MAY_BE_ALLOCA, ECF_LEAF and

Re: [RFC][IPA-VRP] Early VRP Implementation

2016-07-19 Thread Jeff Law
On 07/14/2016 10:52 PM, Andrew Pinski wrote: On Thu, Jul 14, 2016 at 9:45 PM, kugan wrote: Hi, This patch adds a very simple early vrp implementation. This visits the basic blocks in the dominance order and set the Value Ranges (VR) for SSA_NAMEs in the

Re: [PATCH GCC]Improve no-overflow check in SCEV using value range info.

2016-07-19 Thread Bin.Cheng
On Tue, Jul 19, 2016 at 1:10 PM, Richard Biener wrote: > On Mon, Jul 18, 2016 at 6:27 PM, Bin Cheng wrote: >> Hi, >> Scalar evolution needs to prove no-overflow for source variable when >> handling type conversion. This is important because

Re: [PATCH 1/2] Add sreal to selftests

2016-07-19 Thread Jeff Law
On 07/11/2016 08:34 AM, marxin wrote: gcc/ChangeLog: 2016-07-12 Martin Liska * selftest-run-tests.c (selftest::run_tests): New function. * selftest.h (sreal_c_tests): Declare. * sreal.c (sreal_verify_basics): New function. (verify_aritmetics):

Re: [PATCH 2/2] Add selftests for fibonacci_heap

2016-07-19 Thread Jeff Law
On 07/19/2016 08:31 AM, Martin Liška wrote: Thank you for the nits, sending second version of the patch. M. 0002-Add-selftests-for-fibonacci_heap-v2.patch From be12e60d4a2731cf4f1f68516e08f5bdb6c1ef77 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 12 Jul 2016 15:17:24

Commit: M32R: Build crtinit.o and crtfini.o

2016-07-19 Thread Nick Clifton
Hi Guys, I am applying the patch below to fix a long standing snafu for the m32r target where the files crtinit.o and crtfini.o were not being built along with the rest of libgcc. Tested with no regressions and a lot of test case fixes using an m32r-elf toolchain. Cheers Nick

Re: [PATCH] selftest.c: gracefully handle NULL in assert_streq

2016-07-19 Thread Jeff Law
On 07/19/2016 07:04 AM, David Malcolm wrote: If a NULL is passed in as the expected or actual value for an ASSERT_STREQ, the call to strcmp within selftest::assert_streq can segfault, leading to a failure of -fself-test without indicating which test failed. Handle this more gracefully by

Re: [PATCH 1/3][AArch64] Improve zero extend

2016-07-19 Thread Richard Earnshaw (lists)
On 19/07/16 16:30, Wilco Dijkstra wrote: > This patchset improves zero extend costs and code generation. > > When zero extending a 32-bit register, we emit a "mov", but currently > report the cost of the "mov" incorrectly. > > In terms of speed, we currently say the cost is that of an extend >

Re: [PATCH] simplify-rtx.c: start adding selftests (v2)

2016-07-19 Thread David Malcolm
On Wed, 2016-07-13 at 13:38 -0600, Jeff Law wrote: > On 07/06/2016 01:30 PM, David Malcolm wrote: > > > > > > This might be a bit confusing when more tests are added, since > > > pointer equality is only useful in certain specific cases (e.g. > > > when you know you're dealing with CONST_INTs or

Re: [PATCH 8/9] shrink-wrap: shrink-wrapping for separate concerns

2016-07-19 Thread Segher Boessenkool
On Tue, Jul 19, 2016 at 04:49:26PM +0200, Bernd Schmidt wrote: > >But you need the profile to make even reasonably good decisions. > > I'm not worried about making cost decisions: as far as I'm concerned > it's perfectly fine for that. I'm worried about correctness - you can't > validly save

[PATCH 3/3][AArch64] Improve zero extend

2016-07-19 Thread Wilco Dijkstra
On AArch64 the UXTB and UXTH instructions are aliases of UBFM, which does a shift as part of its operation. An AND immediate is a simpler operation, and might be faster on some implementations, so it is better to emit this this instead of UBFM. Benchmarking showed no difference on implementations

[PATCH 2/3][AArch64] Improve zero extend

2016-07-19 Thread Wilco Dijkstra
When zero extending a 32-bit value to 64 bits, there should always be a SET operation on the outside, according to the patterns in aarch64.md. However, the mid-end can also ask for the cost of a made-up instruction, where the zero-extend is part of another operation, not SET. In this case we

[PATCH 1/3][AArch64] Improve zero extend

2016-07-19 Thread Wilco Dijkstra
This patchset improves zero extend costs and code generation. When zero extending a 32-bit register, we emit a "mov", but currently report the cost of the "mov" incorrectly. In terms of speed, we currently say the cost is that of an extend operation. But the cost of a "mov" is the cost of 1

Re: [PATCH PR71734] Add missed check that reference defined inside loop.

2016-07-19 Thread Renlin Li
Hi Yuri, I saw this test case runs on arm platforms, and maybe other platforms as well. testsuite/g++.dg/vect/pr70729.cc:7:10: fatal error: xmmintrin.h: No such file or directory Before the change here, it's gated by vect_simd_clones target selector, which limit it to i?86/x86_64 platform

Re: [PATCH, DOC] Enhance documentation of -fipa-ra option.

2016-07-19 Thread Martin Liška
On 07/19/2016 03:46 PM, Alexander Monakov wrote: >> So I decided to also mention this alias. >> >> Thoughts? > > I'd like the new ipa-ra text to go in, but perhaps you should consider leaving > out option aliases out of this patch, especially given that it's non-trivial, > as > Andreas' comment

Re: [PATCH 8/9] shrink-wrap: shrink-wrapping for separate concerns

2016-07-19 Thread Bernd Schmidt
On 07/19/2016 04:46 PM, Segher Boessenkool wrote: But you need the profile to make even reasonably good decisions. I'm not worried about making cost decisions: as far as I'm concerned it's perfectly fine for that. I'm worried about correctness - you can't validly save registers inside a

Re: [PATCH 8/9] shrink-wrap: shrink-wrapping for separate concerns

2016-07-19 Thread Segher Boessenkool
On Mon, Jul 18, 2016 at 07:03:04PM +0200, Bernd Schmidt wrote: > >>>+ /* The frequency of executing the prologue for this BB and all BBs > >>>+ dominated by it. */ > >>>+ gcov_type cost; > >> > >>Is this frequency consideration the only thing that attempts to prevent > >>placing prologue

Re: [PATCH 2/2] Add selftests for fibonacci_heap

2016-07-19 Thread Martin Liška
Thank you for the nits, sending second version of the patch. M. >From be12e60d4a2731cf4f1f68516e08f5bdb6c1ef77 Mon Sep 17 00:00:00 2001 From: marxin Date: Tue, 12 Jul 2016 15:17:24 +0200 Subject: [PATCH 2/2] Add selftests for fibonacci_heap gcc/ChangeLog: 2016-07-13 Martin

Implement C _FloatN, _FloatNx types [version 4]

2016-07-19 Thread Joseph Myers
[Version 4 is respun to apply without conflicts to current sources and, as previously discussed, makes the PowerPC logic for selecting machine modes match that used for *q constants.] ISO/IEC TS 18661-3:2015 defines C bindings to IEEE interchange and extended types, in the form of _FloatN and

Re: [PATCH], PR 71493, Fix PowerPC ABI breakage on GCC trunk/6.1

2016-07-19 Thread Segher Boessenkool
On Mon, Jul 18, 2016 at 11:40:03PM -0400, Michael Meissner wrote: > > > +/* { dg-do compile { target { powerpc*-*-linux* && ilp32 } } } */ > > > +/* { dg-options "-O2 -m32 -msvr4-struct-return" } */ > > I think you can drop the ilp32. > > You cannot use -m32 on a 64-bit little endian system, so

Re: [PATCH, DOC] Enhance documentation of -fipa-ra option.

2016-07-19 Thread Alexander Monakov
> So I decided to also mention this alias. > > Thoughts? I'd like the new ipa-ra text to go in, but perhaps you should consider leaving out option aliases out of this patch, especially given that it's non-trivial, as Andreas' comment has shown. (I'd say it's rather confusing that -fprofile is

Re: [PATCH PR71503/PR71683]Fix ICE in tree-if-conv.c

2016-07-19 Thread Bin.Cheng
On Thu, Jul 14, 2016 at 6:49 PM, Jeff Law wrote: > On 07/14/2016 10:12 AM, Bin Cheng wrote: >> >> Hi, >> This is a simple patch fixing ICE in tree-if-conv.c. Existing code does >> not setup a variable (cond) when predicate of basic block is true and it >> asserts on the

Re: [PATCH] Add qsort comparator consistency checking (PR71702)

2016-07-19 Thread Alexander Monakov
On Tue, 19 Jul 2016, Richard Biener wrote: > Yes. The other option is to enable this checking not with ENABLE_CHECKING > but some new checking option, say ENABLE_CHECKING_ALGORITHMS, and > do full checking in that case. Thanks - I'm going to fold in this idea when redoing the patch (i.e. check a

[Patch, testsuite, committed] Fix gcc.dg/params/blocksort-part.c for non 32-bit int targets

2016-07-19 Thread Senthil Kumar Selvaraj
Hi, The below patch conditionally defines Int32 and UInt32 to accomodate targets with sizeof(int) != 4. Regtested with x86_64 and avr. Committed as obvious. Regards Senthil 2016-07-19 Senthil Kumar Selvaraj * gcc.dg/params/blocksort-part.c:

Re: [PATCH] Fix test problem for pr70729.

2016-07-19 Thread Yuri Rumyantsev
Thanks Jakub for your comments. I changed the test as you proposed. Yuri. 2016-07-19 15:50 GMT+03:00 Jakub Jelinek : > On Tue, Jul 19, 2016 at 03:40:47PM +0300, Yuri Rumyantsev wrote: >> Hi All, >> >> I was informed that the test pr70729.cc from g++.dg/vect is failed on >>

Re: [PATCH v2] S/390: Add splitter for "and" with complement.

2016-07-19 Thread Dominik Vogt
On Wed, Apr 27, 2016 at 08:58:44AM +0100, Dominik Vogt wrote: > The attached patch provides some improved patterns for "and with > complement" to the s390 machine description. Bootstrapped and > regression tested on s390 and s390x. Version 2 of the patch, reduced to the bare patterns.

[committed] Fix copy bug in function-tests.c

2016-07-19 Thread David Malcolm
I made a copy error when writing selftest::verify_three_block_rtl_cfg, forgetting to update the basic block ptr when asserting the value of "flags". Fixed thusly. Successfully bootstrapped on x86_64-pc-linux-gnu. Verified -fself-test of stage1 on powerpc-ibm-aix7.1.3.0. Committed to trunk

Re: [PATCH, DOC] Enhance documentation of -fipa-ra option.

2016-07-19 Thread Andreas Schwab
Martin Liška writes: > Thank you very much for the suggestions, I've basically followed all nits you > spotted. I also noticed that there is actually one more alias of -p and that's > -profile. That comes from >20 years old commit: -profile is not the same as -p, as the former

Re: [PATCH]: Use HOST_WIDE_INT_{,M}1{,U} some more

2016-07-19 Thread Jakub Jelinek
On Tue, Jul 19, 2016 at 02:46:46PM +0200, Uros Bizjak wrote: > The result of exercises with sed in gcc/ directory. > > 2016-07-19 Uros Bizjak > > * builtins.c: Use HOST_WIDE_INT_1 instead of (HOST_WIDE_INT) 1, > HOST_WIDE_INT_1U instead of (unsigned HOST_WIDE_INT)

Re: [PATCH] Fix test problem for pr70729.

2016-07-19 Thread Jakub Jelinek
On Tue, Jul 19, 2016 at 03:40:47PM +0300, Yuri Rumyantsev wrote: > Hi All, > > I was informed that the test pr70729.cc from g++.dg/vect is failed on > non-x86 targets. > I did minor changes to delete target specific stuff like xmmintrin.h. > > Is it OK for trunk? This is still wrong,

[PATCH]: Use HOST_WIDE_INT_{,M}1{,U} some more

2016-07-19 Thread Uros Bizjak
The result of exercises with sed in gcc/ directory. 2016-07-19 Uros Bizjak * builtins.c: Use HOST_WIDE_INT_1 instead of (HOST_WIDE_INT) 1, HOST_WIDE_INT_1U instead of (unsigned HOST_WIDE_INT) 1, HOST_WIDE_INT_M1 instead of (HOST_WIDE_INT) -1 and

Re: [PATCH, DOC] Enhance documentation of -fipa-ra option.

2016-07-19 Thread Martin Liška
On 07/13/2016 07:04 PM, Alexander Monakov wrote: >> --- a/gcc/doc/invoke.texi >> +++ b/gcc/doc/invoke.texi >> @@ -7260,7 +7260,9 @@ any called function. In that case it is not necessary >> to save and restore >> them around calls. This is only possible if called functions are part of >> same

[PATCH] Fix test problem for pr70729.

2016-07-19 Thread Yuri Rumyantsev
Hi All, I was informed that the test pr70729.cc from g++.dg/vect is failed on non-x86 targets. I did minor changes to delete target specific stuff like xmmintrin.h. Is it OK for trunk? Changelog: 2016-07-19 Yuri Rumyantsev PR tree-optimization/71734

[PATCH] selftest.c: gracefully handle NULL in assert_streq

2016-07-19 Thread David Malcolm
If a NULL is passed in as the expected or actual value for an ASSERT_STREQ, the call to strcmp within selftest::assert_streq can segfault, leading to a failure of -fself-test without indicating which test failed. Handle this more gracefully by checking for NULL, so that information on the failing

Re: [PATCH 2/2] Add selftests for fibonacci_heap

2016-07-19 Thread David Malcolm
On Tue, 2016-07-12 at 15:17 +0200, marxin wrote: Thanks for writing selftests! FWIW, some spelling nits below (I'm not a reviewer, and not familiar with our fibonacci heap implementation). > gcc/ChangeLog: > > 2016-07-13 Martin Liska > > * Makefile.in: Include

Re: [PATCH GCC]Improve no-overflow check in SCEV using value range info.

2016-07-19 Thread Richard Biener
On Mon, Jul 18, 2016 at 6:27 PM, Bin Cheng wrote: > Hi, > Scalar evolution needs to prove no-overflow for source variable when handling > type conversion. This is important because otherwise we would fail to > recognize result of the conversion as SCEV, resulting in missing

[PATCH] S/390: Xfail some tests in insv-[12].c.

2016-07-19 Thread Dominik Vogt
The attached patch XFAILs some of the "insv" testcases as discussed internally. Tested on s390x biarch and s390. Ciao Dominik ^_^ ^_^ -- Dominik Vogt IBM Germany gcc/testsuite/ChangeLog * gcc.target/s390/insv-1.c: Xfail some tests. * gcc.target/s390/insv-2.c: Likewise.

Re: [PATCH, vec-tails 10/10] Tests

2016-07-19 Thread Kirill Yukhin
Hi! On 15 Jul 12:39, Ilya Enkovich wrote: > 2016-07-14 20:32 GMT+03:00 Jeff Law : > > On 07/05/2016 09:44 AM, Ilya Enkovich wrote: > >> > >> Hi, > >> > >> This patch adds several tests to check tails vectorization functionality. > >> > >> Thanks, > >> Ilya > >> -- > >>

[PATCH] Fix missed constant propagation

2016-07-19 Thread Richard Biener
The following patch fixes missing constant propagation in SSA propagators and FRE. Noticed this when working on sth else. Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2016-07-19 Richard Biener * gimple-fold.c (get_base_constructor):

Re: Implement C _FloatN, _FloatNx types [version 3]

2016-07-19 Thread James Greenhalgh
On Thu, Jun 23, 2016 at 02:19:52PM +, Joseph Myers wrote: > No GCC port supports a floating-point format suitable for _Float128x. > Although there is HFmode support for ARM and AArch64, use of that for > _Float16 is not enabled. Supporting _Float16 would require additional > work on the

Re: [PATCH GCC]Remove support for -funsafe-loop-optimizations

2016-07-19 Thread Bin.Cheng
On Tue, Jul 19, 2016 at 9:00 AM, Richard Biener wrote: > On Mon, Jul 18, 2016 at 5:36 PM, Bin.Cheng wrote: >> On Mon, Jul 18, 2016 at 4:28 PM, NightStrike wrote: >>> On Mon, Jul 18, 2016 at 3:55 AM, Bin.Cheng

Re: [BACKPORT 4.9/5] Fix compiling large files

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 1:19 PM, Martin Liška wrote: > Hello. > > As mentioned in PR71920, I would like to backport the change to GCC 4.9 and 5. > > May I install the patch after proper testing? Yes, it's pretty obvious. Richard. > Thanks, > Martin

[BACKPORT 4.9/5] Fix compiling large files

2016-07-19 Thread Martin Liška
Hello. As mentioned in PR71920, I would like to backport the change to GCC 4.9 and 5. May I install the patch after proper testing? Thanks, Martin

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 1:07 PM, Bernd Schmidt wrote: > On 07/19/2016 12:35 PM, Richard Biener wrote: > >> I think that start/end_recording_case_labels also merged adjacent labels >> via group_case_labels_stmt. Not sure why you need to stop recording >> case labels during

Do not ICE in resolve.c (PR fortran/71799)

2016-07-19 Thread Martin Liška
Hi. Suggested patch was just grabbed from the PR. Patch can bootstrap on x86_64-linux-gnu and survives regression tests. Ready to be installed? Martin >From e6c55da822bc5a7464edc9cedb9b08f56e310885 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 18 Jul 2016 16:47:27 +0200

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Bernd Schmidt
On 07/19/2016 12:35 PM, Richard Biener wrote: I think that start/end_recording_case_labels also merged adjacent labels via group_case_labels_stmt. Not sure why you need to stop recording case labels during the transform. Is this because you are building a new switch stmt? It's because the

Re: [PATCH v2] S/390: Add splitter for "and" with complement.

2016-07-19 Thread Andreas Krebbel
On 07/19/2016 11:37 AM, Dominik Vogt wrote: > ; > +; And with complement > +; > +; c = ~b & a = (b & a) ^ a > + > +(define_insn_and_split "*andc_split" Please append here to make the insn name unique. > + [(set (match_operand:GPR 0 "nonimmediate_operand" "") > + (and:GPR (not:GPR

Re: RFA: new pass to warn on questionable uses of alloca() and VLAs

2016-07-19 Thread Aldy Hernandez
On 07/18/2016 11:14 PM, Martin Sebor wrote: How does this look? I think it's 99% there. You've addressed all of my comments so far -- thanks for that and for being so patient. I realize it would be a lot more efficient to get all the feedback (or as much of it as possible) up front.

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 12:25 PM, Bernd Schmidt wrote: > On 07/19/2016 12:22 PM, Marc Glisse wrote: >> >> On Tue, 19 Jul 2016, Bernd Schmidt wrote: >> >>> On 07/19/2016 12:09 PM, Richard Biener wrote: >>> I saw walks over stmts of a BB. IMHO that's a no-go. >>> >>> >>>

[patch,avr] Slightly better memory accesses on avr_tiny

2016-07-19 Thread Georg-Johann Lay
This patch tries to improve the bloated code we are currently generating for AVR_TINY. It's mostly about printing the memory loads and stores and more usage of reg_unused_after to print shorter instruction sequences in some cases. Ok for trunk? I also played around with PLUS in

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Bernd Schmidt
On 07/19/2016 12:22 PM, Marc Glisse wrote: On Tue, 19 Jul 2016, Bernd Schmidt wrote: On 07/19/2016 12:09 PM, Richard Biener wrote: I saw walks over stmts of a BB. IMHO that's a no-go. Only to find the first or last nondebug one. Is that unacceptable? Does

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Marc Glisse
On Tue, 19 Jul 2016, Bernd Schmidt wrote: On 07/19/2016 12:09 PM, Richard Biener wrote: I saw walks over stmts of a BB. IMHO that's a no-go. Only to find the first or last nondebug one. Is that unacceptable? Does gsi_start_nondebug_after_labels_bb not fit? -- Marc Glisse

[PATCH 2/2] Add selftests for fibonacci_heap

2016-07-19 Thread marxin
gcc/ChangeLog: 2016-07-13 Martin Liska * Makefile.in: Include fibonacci_heap.c * fibonacci_heap.c: New file. * fibonacci_heap.h (fibonacci_heap::insert): Use insert_node. (fibonacci_heap::union_with): Fix deletion of the second heap. *

[PATCH 1/2] Add sreal to selftests

2016-07-19 Thread marxin
gcc/ChangeLog: 2016-07-12 Martin Liska * selftest-run-tests.c (selftest::run_tests): New function. * selftest.h (sreal_c_tests): Declare. * sreal.c (sreal_verify_basics): New function. (verify_aritmetics): Likewise.

[PATCH 0/2] New selftests: sreal and fibonacci_heap

2016-07-19 Thread marxin
Hello. Following small patch set adds selftests for sreal and fibonacci_heap. I basically transformed the existing tests (for sreal) which were implemented as a GCC plugin. Current implementation of the fibonacci heap corrupts memory in union_with and another usability change was applied to

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Bernd Schmidt
On 07/19/2016 12:09 PM, Richard Biener wrote: I saw walks over stmts of a BB. IMHO that's a no-go. Only to find the first or last nondebug one. Is that unacceptable? I'm thinking of switch (a) { ... case n: do-stuff; default: switch (a) { case n:

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 11:52 AM, Bernd Schmidt wrote: > On 07/19/2016 10:07 AM, Richard Biener wrote: >> >> >> This is not appropriate for CFG cleanup due to its complexity not >> being O(# bbs + # edges). >> I tried hard in the past to make it so (at least when no transform

Re: [patch, fortran] PR66310 Problems with intrinsic repeat for large number of copies

2016-07-19 Thread Dominique d'Humières
> Le 18 juil. 2016 à 02:02, Jerry DeLisle a écrit : > > Please test this revised patch. See my comments in the PR. > > I think we should commit this one. > > Jerry Jerry, As said on IRC I think the limit should be documented and a TODO comment added to

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Bernd Schmidt
On 07/19/2016 10:07 AM, Richard Biener wrote: This is not appropriate for CFG cleanup due to its complexity not being O(# bbs + # edges). I tried hard in the past to make it so (at least when no transform is done). Why wouldn't it be, if no transform is done? Assuming we visit each bb once,

Re: [PATCH GCC]Remove support for -funsafe-loop-optimizations

2016-07-19 Thread Martin Jambor
Hi, On Mon, Jul 18, 2016 at 11:28:48AM -0400, NightStrike wrote: > Well, one thing to note is that the warning is an easy way to get a > notice of a possible missed optimization (and I have many more > occurrences of it in a particular code base that I use). If the > warning is highlighted

Re: [PATCH] c++/58796 Make nullptr match exception handlers of pointer type

2016-07-19 Thread Jonathan Wakely
On 18/07/16 12:49 -0400, Jason Merrill wrote: Perhaps the right answer is to drop support for catching nullptr as a pointers to member from the language. Yes, I've been drafting a ballot comment along those lines.

Re: [RFC][IPA-VRP] Add support for IPA VRP in ipa-cp/ipa-prop

2016-07-19 Thread kugan
Hi Martin, Thanks for the review. I have revised the patch based on the review. Please see the comments below. On 15/07/16 22:23, Martin Jambor wrote: Hi, thanks for working on extending IPA-CP in this way. I do have a few comments though: On Fri, Jul 15, 2016 at 02:46:50PM +1000, kugan

Re: [PATCH] Avoid invoking ranlib on libbackend.a

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 2:39 AM, Patrick Palka wrote: > On Mon, 18 Jul 2016, Segher Boessenkool wrote: > >> On Mon, Jul 18, 2016 at 06:35:11AM -0500, Segher Boessenkool wrote: >> > Or, if using GNU ar, you can even use -S, if that helps (after testing >> > for it in

Re: [patch] Add new hook to diagnose address space usage (take #2)

2016-07-19 Thread Georg-Johann Lay
On 18.07.2016 16:13, Bernd Schmidt wrote: On 07/14/2016 05:11 PM, Georg-Johann Lay wrote: The hook allows better diagnostics: The address spaces are registered with c_register_addr_space and if the parser comes across an address space it provides the hook with the needed information, in

Re: [PATCH] Add qsort comparator consistency checking (PR71702)

2016-07-19 Thread Richard Biener
On Mon, Jul 18, 2016 at 7:36 PM, Alexander Monakov wrote: > On Mon, 18 Jul 2016, Richard Biener wrote: >> Ugh. What impact does this have on stage2 compile-time? > > It doesn't seem to be high enough to be measured reliably. I've made a trial > run with -time=time.log in

Re: Merge switch statements in tree-cfgcleanup

2016-07-19 Thread Richard Biener
On Mon, Jul 18, 2016 at 6:07 PM, Bernd Schmidt wrote: > The motivating example for this patch was a change that was submitted for > genattrtab last year, which would have made us generate > > switch (type = get_attr_type (insn)) > { >... some cases ... >default: >

Re: [PATCH GCC]Remove support for -funsafe-loop-optimizations

2016-07-19 Thread Richard Biener
On Tue, Jul 19, 2016 at 10:00 AM, Richard Biener wrote: > On Mon, Jul 18, 2016 at 5:36 PM, Bin.Cheng wrote: >> On Mon, Jul 18, 2016 at 4:28 PM, NightStrike wrote: >>> On Mon, Jul 18, 2016 at 3:55 AM, Bin.Cheng

  1   2   >