Re: [committed][PATCH] Change order of processing blocks/threads in tree-ssa-threadupdate.c

2017-11-14 Thread Aldy Hernandez
On 11/14/2017 10:46 PM, Jeff Law wrote: With my local patches to remove jump threading from VRP I was seeing a fairly obvious jump threading path left in the CFG after DOM. This missed jump thread ultimately caused a false positive uninitialized warning. This wouldn't be uninit-pred-[68]*

Re: [patch] backwards threader cleanups

2017-11-14 Thread Aldy Hernandez
On 11/14/2017 02:38 PM, David Malcolm wrote: On Tue, 2017-11-14 at 14:08 -0500, Aldy Hernandez wrote: https://gcc.gnu.org/codingconventions.html#Class_Form says that: "When defining a class, first [...] declare all public member functions, [...] then declare all non-public member

Re: [PATCH][RFC] Instrument function exit with __builtin_unreachable in C++.

2017-11-14 Thread Martin Liška
PING^1 On 11/07/2017 11:08 AM, Martin Liška wrote: > On 11/06/2017 06:33 PM, Jakub Jelinek wrote: >> On Mon, Nov 06, 2017 at 06:23:11PM +0100, Eric Botcazou wrote: Thank you for review, done that. >>> >>> This has enabled -Wreturn-type for Ada, what we don't want since the >>> warning >>>

Re: [PATCH] Fix UBSAN errors in dse.c (PR rtl-optimization/82044).

2017-11-14 Thread Martin Liška
On 11/08/2017 05:31 PM, Jeff Law wrote: > I don't see an updated patch in this thread? THe last message I see is > this one where you indicate you're going to tweak the patch and re-test. > > Jeff Yes, I tweaked and tested following patch. Martin >From a369ac78b887e219a375e17d6817c1f744e71779

[PATCH][Aarch64] v2: Arithmetic overflow tests [Patch 4/4]

2017-11-14 Thread Michael Collison
This is a respin of a AArch64 patch that adds support for builtin arithmetic overflow operations. This update separates the patch into multiple pieces and addresses comments made by Richard Earnshaw here: https://gcc.gnu.org/ml/gcc-patches/2017-07/msg00249.html Original patch and motivation

[PATCH][Aarch64] v2: Arithmetic overflow subv patterns [Patch 3/4]

2017-11-14 Thread Michael Collison
This is a re-spin of a AArch64 patch that adds support for builtin arithmetic overflow operations. This update separates the patch into multiple pieces and addresses comments made by Richard Earnshaw here: https://gcc.gnu.org/ml/gcc-patches/2017-07/msg00249.html Original patch and motivation

[PATCH][Aarch64] v2: Arithmetic overflow addv patterns [Patch 2/4]

2017-11-14 Thread Michael Collison
This is a respin of a AArch64 patch that adds support for builtin arithmetic overflow operations. This update separates the patch into multiple pieces and addresses comments made by Richard Earnshaw here: https://gcc.gnu.org/ml/gcc-patches/2017-07/msg00249.html Original patch and motivation

[PATCH][Aarch64] v2: Arithmetic overflow common functions [Patch 1/4]

2017-11-14 Thread Michael Collison
This is a respin of a AArch64 patch that adds support for builtin arithmetic overflow operations. This update separates the patch into multiple pieces and addresses comments made by Richard Earnshaw here: https://gcc.gnu.org/ml/gcc-patches/2017-07/msg00249.html Original patch and motivation

[PATCH][OBVIOUS] Coverage: remove -fkeep-inline-functions from coverage_flags.

2017-11-14 Thread Martin Liška
Hello. This is partial revert of my commit r254257 because having -fkeep-inline-functions causes many unresolved symbols. And it would force us to add e.g. many objects for libcommon.a. I'm going to install the patch. gcc/ChangeLog: 2017-11-15 Martin Liska *

Re: [PATCH] Fix usage of REG_BR_PROBs (PR target/82927).

2017-11-14 Thread Martin Liška
On 11/14/2017 02:59 PM, Joseph Myers wrote: > On Tue, 14 Nov 2017, Martin Liška wrote: > >> Hello. >> >> Quite obvious fix for SH target. Joseph can you please continue with testing? >> I don't have a machine to test the patch. > > I don't have SH hardware, but can confirm that, in conjunction

[DWARF] mark partial fn versions and OMP frags as partial in dwarf2+ debug info

2017-11-14 Thread Alexandre Oliva
debug info: partial noentry functions: infra This is the first patch of a set that addresses two different but somewhat related issues. On the one hand, after partial inlining, the non-inlined function fragment is output in a way that debug info consumers can't distinguish from the entire

[RFA][PATCH] patch 4/n Refactor bits of vrp_visit_assignment_or_call

2017-11-14 Thread Jeff Law
So the next group of changes is focused on breaking down evrp into an analysis engine and the actual optimization pass. The analysis engine can be embedded into other dom walker passes quite easily. I've done it for the sprintf warnings as well as the main DOM optimizer locally. Separating

[committed][PATCH] Fix probe into the red zone on aarch64

2017-11-14 Thread Jeff Law
Testing within Red Hat of the aarch64 stack clash bits turned up an additional problem, one I probably should have expected. aarch64 is a bit odd in that we may need to emit a probe in the residual alloca space to enforce certain probing rules related to the outgoing argument space. When the

Re: [PATCH] Move bswap pass into gimple-ssa-store-merging.c

2017-11-14 Thread Richard Biener
On November 14, 2017 10:25:28 PM GMT+01:00, Jakub Jelinek wrote: >Hi! > >I'll be working on further store-merging improvements next two days >and hope to use some of the bswap pass APIs to handle stuff like: >void foo (char *__restrict p, char *__restrict q) >{ > p[0] = q[3];

Re: [PATCH 02/14] Support for adding and stripping location_t wrapper nodes

2017-11-14 Thread Trevor Saunders
On Fri, Nov 10, 2017 at 04:45:17PM -0500, David Malcolm wrote: > This patch provides a mechanism in tree.c for adding a wrapper node > for expressing a location_t, for those nodes for which > !CAN_HAVE_LOCATION_P, along with a new method of cp_expr. > > It's called in later patches in the kit via

Re: [PATCH v2] [libcc1] Rename C{,P}_COMPILER_NAME and remove triplet from them

2017-11-14 Thread Alexandre Oliva
On Nov 13, 2017, Sergio Durigan Junior wrote: > On Tuesday, September 26 2017, I wrote: >> Ping^2. > Ping^3. > I'm sending the updated ChangeLog/patch. I'm also removing gdb-patches > from the Cc list. > libcc1/ChangeLog: > 2017-09-01 Sergio Durigan Junior

Re: [SFN+LVU+IEPM v4 7/9] [LVU] Introduce location views

2017-11-14 Thread Alexandre Oliva
On Nov 13, 2017, Richard Biener wrote: > What does final.c need langhooks for? Thanks for catching this. At some point I had a check on whether there could be being stmt markers emitted by the language, but that's long gone, in part because of LTO; that's now

[committed][PATCH] Change order of processing blocks/threads in tree-ssa-threadupdate.c

2017-11-14 Thread Jeff Law
With my local patches to remove jump threading from VRP I was seeing a fairly obvious jump threading path left in the CFG after DOM. This missed jump thread ultimately caused a false positive uninitialized warning. Interestingly enough when I looked at the dumps it appeared DOM was finding the

Re: [PATCH, AArch64] Adjust tuning parameters for Falkor

2017-11-14 Thread Luis Machado
> I think the best thing is to leave this tuning structure in place and > just change default_opt_level to -1 to disable it at -O3. > > Thanks, > Andrew > Indeed that seems to be more appropriate if re-enabling prefetches in the future is a possibility. How about the following? Thanks, Luis

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Jeff Law
On 11/14/2017 02:30 PM, Jakub Jelinek wrote: > On Tue, Nov 14, 2017 at 02:24:28PM -0700, Martin Sebor wrote: >> On 11/14/2017 02:04 PM, Jakub Jelinek wrote: >>> Hi! >>> >>> strlen_to_stridx.get (rhs1) returns an address into the hash_map, and >>> strlen_to_stridx.put (lhs, *ps); (in order to be

Re: [PATCH, AArch64] Adjust tuning parameters for Falkor

2017-11-14 Thread Andrew Pinski
On Tue, Nov 14, 2017 at 6:00 PM, Luis Machado wrote: > Disabling software prefetching and switching the autoprefetcher to weak > improves > CPU2017 rate and speed benchmarks for both int and fp sets on Falkor. > > SPECrate 2017 fp is up 0.38% > SPECspeed 2017 fp is up

[PATCH, AArch64] Adjust tuning parameters for Falkor

2017-11-14 Thread Luis Machado
Disabling software prefetching and switching the autoprefetcher to weak improves CPU2017 rate and speed benchmarks for both int and fp sets on Falkor. SPECrate 2017 fp is up 0.38% SPECspeed 2017 fp is up 0.54% SPECrate 2017 int is up 3.02% SPECspeed 2017 int is up 3.16% There are only a couple

Add __builtin_tgmath for better tgmath.h implementation (bug 81156)

2017-11-14 Thread Joseph Myers
Various implementations of C99/C11 have the property that their macro expansions contain many copies of the macro arguments, so resulting in exponential blowup of the size of macro expansions where a call to such a macro contains other such calls in the macro arguments. This patch adds a

Go patch committed: Remove LHS/RHS setting for variables

2017-11-14 Thread Ian Lance Taylor
This patch to the Go frontend by Than McIntosh removes the LHS/RHS context determination for variable references. It used to be needed for a different backend but it's no longer necessary. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 2017-11-14 Than

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-11-14 Thread Jeff Law
On 11/13/2017 06:21 PM, Martin Sebor wrote: > I have a different concern with the general idea of moving these > kinds of warnings into passes of their own.  It would unavoidably > result in duplicating some code from the optimization passes (at > a minimum, the GIMPLE traversal, but likely more

Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455)

2017-11-14 Thread Jeff Law
On 11/14/2017 01:42 AM, Richard Biener wrote: > > I suspect once you're dealing with C++ code you run into the issue > that even early inlining exposes code with forwprop run on it > before running forwprop again on the inlined-into body. > > So the IPA issues start very early. Of course if

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Jeff Law
On 11/14/2017 02:30 PM, Martin Sebor wrote: > On 11/14/2017 02:10 PM, Jeff Law wrote: >> On 11/14/2017 02:04 PM, Jakub Jelinek wrote: >>> Hi! >>> >>> strlen_to_stridx.get (rhs1) returns an address into the hash_map, and >>> strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't >>>

Re: [AARCH64] implements neon vld1_*_x2 intrinsics

2017-11-14 Thread Kugan Vivekanandarajah
Ping? Thanks, Kugan On 7 November 2017 at 15:10, Kugan Vivekanandarajah wrote: > Hi, > > Attached patch implements the vld1_*_x2 intrinsics as defined by the > neon document. > > Bootstrap for the latest patch is ongoing on aarch64-linux-gnu. Is > this OK for

Re: libstdc++ PATCH to harmonize noexcept

2017-11-14 Thread Jonathan Wakely
On 14/11/17 13:56 -0500, Jason Merrill wrote: While working on an unrelated issue I noticed that the compiler didn't like some of these declarations after preprocessing, when they aren't protected by system-header permissiveness. I thought about limiting the permissiveness to only extern "C"

[C++ Patch] PR 82235 (Copy ctor is not found for copying array of an object when it's marked explicit)

2017-11-14 Thread Mukesh Kapoor
Hi, This patch fixes https://gcc.gnu.org/bugzilla/show_bug.cgi?id=82235 For the following test case struct Foo {     Foo() {}     explicit Foo(const Foo& aOther) {} }; struct Bar {     Foo m[1]; }; void test() {     Bar a;     Bar b = a; } the compiler issues an error when the compiler

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Martin Sebor
On 11/14/2017 02:30 PM, Jakub Jelinek wrote: On Tue, Nov 14, 2017 at 02:24:28PM -0700, Martin Sebor wrote: On 11/14/2017 02:04 PM, Jakub Jelinek wrote: Hi! strlen_to_stridx.get (rhs1) returns an address into the hash_map, and strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't

Re: [Patch] Don't call linker when creating pre-compiled header just because you saw a linker option

2017-11-14 Thread Steve Ellcey
On Tue, 2017-11-14 at 20:04 +0100, Richard Biener wrote: >  > I think the intent is to link even for just - lfoo while it makes > sense to ignore -L/path - Wl,... Certainly counts as possible input.  > > It seems you even break - lfoo.  > > Richard.  Good point.  I guess I need to take a

[Ping] [C++ Patch/RFC] PR 82593 ("Internal compiler error: in process_init_constructor_array, at cp/typeck2.c:1294")

2017-11-14 Thread Paolo Carlini
Hi, any feedback about this - apparently rather simple - issue? On 03/11/2017 18:33, Paolo Carlini wrote: Hi, this ICE on valid (given GNU's designated initializers) is rather simple to analyze: for the testcase, the gcc_assert in process_init_constructor_array triggers because at that time

Re: [PATCH] PR fortran/78240 -- kludge of the day

2017-11-14 Thread Steve Kargl
On Tue, Nov 14, 2017 at 05:21:41PM -0500, Fritz Reese wrote: > On Tue, Nov 14, 2017 at 4:58 PM, Janus Weil wrote: > > Error: The module or main program array ‘x’ at (1) must have constant shape > > pr78240.f90:11:19: > > > >integer x(n)/1/ ! { dg-error "Nonconstant

Re: [PATCH] PR fortran/78240 -- kludge of the day

2017-11-14 Thread Janus Weil
2017-11-14 23:21 GMT+01:00 Fritz Reese : > On Tue, Nov 14, 2017 at 4:58 PM, Janus Weil wrote: >> Hi guys, >> >> I see this new test case failing on x86_64-linux-gnu: >> >> FAIL: gfortran.dg/pr78240.f90 -O (test for excess errors) >> >> >> $ gfortran-8

Re: [PATCH] PR fortran/78240 -- kludge of the day

2017-11-14 Thread Fritz Reese
On Tue, Nov 14, 2017 at 4:58 PM, Janus Weil wrote: > Hi guys, > > I see this new test case failing on x86_64-linux-gnu: > > FAIL: gfortran.dg/pr78240.f90 -O (test for excess errors) > > > $ gfortran-8 pr78240.f90 > pr78240.f90:11:12: > >integer x(n)/1/ ! { dg-error

[PATCH, rs6000] (v2) GIMPLE folding for vector compares

2017-11-14 Thread Will Schmidt
Hi, Add support for gimple folding of vec_cmp_{eq,ge,gt,le,ne} for the integer data types. As part of this change, several define_insn stanzas have been added/updated in vsx.md that specify the "ne: -> not: + eq: " combinations to allow for the generation of the desired vcmpne[bhw]

Re: [PATCH] Fixes for PR68356, PR81210, and PR81693

2017-11-14 Thread Mike Stump
On Nov 14, 2017, at 3:33 AM, Dominique d'Humières wrote: > >> Le 13 nov. 2017 à 18:40, Mike Stump a écrit : >> On Nov 12, 2017, at 6:58 AM, H.J. Lu wrote: >>> >>> On Sun, Nov 12, 2017 at 6:22 AM, Dominique d'Humières >>>

Re: [PATCH] PR fortran/78240 -- kludge of the day

2017-11-14 Thread Janus Weil
Hi guys, I see this new test case failing on x86_64-linux-gnu: FAIL: gfortran.dg/pr78240.f90 -O (test for excess errors) $ gfortran-8 pr78240.f90 pr78240.f90:11:12: integer x(n)/1/ ! { dg-error "Nonconstant array" } 1 Error: Variable ‘n’ cannot appear in the expression

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Martin Sebor
On 11/14/2017 02:10 PM, Jeff Law wrote: On 11/14/2017 02:04 PM, Jakub Jelinek wrote: Hi! strlen_to_stridx.get (rhs1) returns an address into the hash_map, and strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't make a copy of the argument just in case, first inserts the slot

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Jakub Jelinek
On Tue, Nov 14, 2017 at 02:24:28PM -0700, Martin Sebor wrote: > On 11/14/2017 02:04 PM, Jakub Jelinek wrote: > > Hi! > > > > strlen_to_stridx.get (rhs1) returns an address into the hash_map, and > > strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't make a > > copy of the

[PATCH] Move bswap pass into gimple-ssa-store-merging.c

2017-11-14 Thread Jakub Jelinek
Hi! I'll be working on further store-merging improvements next two days and hope to use some of the bswap pass APIs to handle stuff like: void foo (char *__restrict p, char *__restrict q) { p[0] = q[3]; p[1] = q[2]; p[2] = q[1]; p[3] = q[0]; } or p[4] = data >> 8; p[5] = data; etc.

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Martin Sebor
On 11/14/2017 02:04 PM, Jakub Jelinek wrote: Hi! strlen_to_stridx.get (rhs1) returns an address into the hash_map, and strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't make a copy of the argument just in case, first inserts the slot into it which may cause reallocation, and

[PATCH] Small expand_mul_overflow improvement (PR target/82981)

2017-11-14 Thread Jakub Jelinek
Hi! For targets that don't have {,u}mulv4 insn we try 3 different expansions of the basic signed * signed -> signed or unsigned * unsigned -> unsigned overflow computation. The first one is done if if (GET_MODE_2XWIDER_MODE (mode).exists () && targetm.scalar_mode_supported_p

Re: [PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Jeff Law
On 11/14/2017 02:04 PM, Jakub Jelinek wrote: > Hi! > > strlen_to_stridx.get (rhs1) returns an address into the hash_map, and > strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't make a > copy of the argument just in case, first inserts the slot into it which > may cause

[PATCH] Fix use-after-free in the strlen pass (PR tree-optimization/82977)

2017-11-14 Thread Jakub Jelinek
Hi! strlen_to_stridx.get (rhs1) returns an address into the hash_map, and strlen_to_stridx.put (lhs, *ps); (in order to be efficient) doesn't make a copy of the argument just in case, first inserts the slot into it which may cause reallocation, and only afterwards runs the copy ctor to assign the

Re: [PATCH, rs6000] Repair vec_xl, vec_xst, vec_xl_be, vec_xst_be built-in functions

2017-11-14 Thread Bill Schmidt
Hi, I had a pasto in the function prototype for vec_xst_be. Fixed patch is below. Thanks, Bill On 11/14/17 8:11 AM, Bill Schmidt wrote: > Please hold review on this until I investigate something that Carl brought > up. Thanks, > and sorry for the noise! > > -- Bill >> On Nov 13, 2017, at

[PR c++/82878] pass-by-invisiref in lambda

2017-11-14 Thread Nathan Sidwell
This patch fixes 82878, which turned out to be a problem in genericizing the call inside a __closure::_FUN () that we synthesize when we're providing a non-member fn pointer for a non-capturing lambda. That call is marked as CALL_FROM_THUNK_P, but I elided the check for that when fixing

Re: [patch] backwards threader cleanups

2017-11-14 Thread David Malcolm
On Tue, 2017-11-14 at 14:08 -0500, Aldy Hernandez wrote: > Howdy! > > For some upcoming work I need some pass local data that I don't want > to > be passing around as an argument. We have enough of those in the > threader as it is. So I moved the current pass local data into its > own >

Remove computation of path_in_freq in tree-ssa-threadupdate

2017-11-14 Thread Jan Hubicka
Hi, this patch removes now unused variable. Bootstrapped/regtested x86_64-linux, comitted. Honza * tree-ssa-threadupdate.c (compute_path_counts): Remove unused path_in_freq_ptr parameter. (ssa_fix_duplicate_block_edges): Do not pass around path_in_freq Index:

Re: [PATCH, i386] Refactor -mprefer-avx[128|256] options into common -mprefer-vector-width=[none|128|256|512]

2017-11-14 Thread Sandra Loosemore
On 11/13/2017 10:25 AM, Shalnov, Sergey wrote: diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 4427328..bc9eb85 100644 --- a/gcc/doc/invoke.texi +++ b/gcc/doc/invoke.texi @@ -26087,15 +26087,24 @@ before a transfer of control flow out of the function to minimize the AVX to SSE

PING: [PATCH] Use rcrt1.o%s/grcrt1.o%s to relocate static PIE

2017-11-14 Thread H.J. Lu
On Fri, Nov 3, 2017 at 10:48 AM, H.J. Lu wrote: > On Wed, Nov 1, 2017 at 9:39 AM, H.J. Lu wrote: >> On Wed, Nov 1, 2017 at 9:32 AM, Rich Felker wrote: >>> On Sun, Oct 15, 2017 at 06:16:57AM -0700, H.J. Lu wrote: crt1.o is used to

Fix accounting of call edges in inliner

2017-11-14 Thread Jan Hubicka
Hi, this patch makes call time computations consistent again. Bootstrapped/regtested x86_64-linux, comitted. Honza * ipa-inline.c (edge_badness): Dump sreal frequency. (compute_inlined_call_time): Match natural implementaiton ... * ipa-fnsummary.c

[patch] backwards threader cleanups

2017-11-14 Thread Aldy Hernandez
Howdy! For some upcoming work I need some pass local data that I don't want to be passing around as an argument. We have enough of those in the threader as it is. So I moved the current pass local data into its own class, and basically classified the entire pass, thus avoiding a lot of

Re: [Patch] Don't call linker when creating pre-compiled header just because you saw a linker option

2017-11-14 Thread Richard Biener
On November 14, 2017 7:59:18 PM GMT+01:00, Steve Ellcey wrote: >I am building GCC (and binutils) with --with-sysroot and I build glibc >in >that sysroot too.  I want to test GCC using the glibc libraries I just >built, but by default GCC uses the dynamic linker that is in

[Patch] Don't call linker when creating pre-compiled header just because you saw a linker option

2017-11-14 Thread Steve Ellcey
I am building GCC (and binutils) with --with-sysroot and I build glibc in that sysroot too.  I want to test GCC using the glibc libraries I just built, but by default GCC uses the dynamic linker that is in /lib and that is loading the "normal" libraries from /lib or /lib64 at runtime and not the

libstdc++ PATCH to harmonize noexcept

2017-11-14 Thread Jason Merrill
While working on an unrelated issue I noticed that the compiler didn't like some of these declarations after preprocessing, when they aren't protected by system-header permissiveness. I thought about limiting the permissiveness to only extern "C" functions, but I believe that system headers are

Re: [PATCH][GCC][AARCH64]Bad code-gen for structure/block/unaligned memory access

2017-11-14 Thread Tamar Christina
Th 11/14/2017 17:48, James Greenhalgh wrote: > On Tue, Nov 14, 2017 at 04:05:12PM +, Tamar Christina wrote: > > Hi James, > > > > I have split off the aarch64 bit off from the generic parts and processed > > your feedback. > > > > Attached is the reworked patch. > > > > Ok for Tunk? > >

Re: [PATCH libquadmath, pr68686] tgammaq(x) is always negative for noninteger x < 0

2017-11-14 Thread Steve Kargl
Ed, gfortran uses libquadmath for support of its REAL(16) intrinsic subprograms. I checked the list of intrinsics and tgamma is current not in the list. I don't have time to try Fortran's C interop feature to see if an ordinary user can access __float128. While your patch is probably useful

Re: [v3 PATCH] Implement LWG 2733 and LWG 2759

2017-11-14 Thread Jonathan Wakely
On 14/11/17 19:51 +0200, Ville Voutilainen wrote: On 14 November 2017 at 19:06, Jonathan Wakely wrote: Both files can use remove_cv_t instead of remove_cv::type (and there's no need to std-qualify it in std::gcd). They could also use is_integral_v and is_same_v but that's

Re: potential bug in libstc++ ?

2017-11-14 Thread Jonathan Wakely
On 14/11/17 15:04 +, Jonathan Wakely wrote: On 14 November 2017 at 14:35, Sergey Nenakhov wrote: Hello. Excuse me if I'm posting to the wrong mailing list. libstdc++ has its own mailing list (which Richard CC'd). I've grabbed gcc-7.2.0 sources and noticed strange statement in the file

Re: [v3 PATCH] Implement LWG 2733 and LWG 2759

2017-11-14 Thread Ville Voutilainen
On 14 November 2017 at 19:06, Jonathan Wakely wrote: > Both files can use remove_cv_t instead of remove_cv::type (and there's > no need to std-qualify it in std::gcd). > > They could also use is_integral_v and is_same_v but that's > pre-existing, and less important because

Re: [PATCH][GCC][AARCH64]Bad code-gen for structure/block/unaligned memory access

2017-11-14 Thread James Greenhalgh
On Tue, Nov 14, 2017 at 04:05:12PM +, Tamar Christina wrote: > Hi James, > > I have split off the aarch64 bit off from the generic parts and processed > your feedback. > > Attached is the reworked patch. > > Ok for Tunk? Thanks for the respin, I'm a bit confused by this comment. > diff

Re: [PATCH] enhance -Warray-bounds to handle strings and excessive indices

2017-11-14 Thread Martin Sebor
On 11/14/2017 05:28 AM, Richard Biener wrote: On Mon, Nov 13, 2017 at 6:37 PM, Martin Sebor wrote: Richard, this thread may have been conflated with the one Re: [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets (PR 82455) They are about different things. I'm

Re: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread Uros Bizjak
On Tue, Nov 14, 2017 at 3:26 PM, Peryt, Sebastian wrote: > Attached is fixed patch. > > Sebastian > > >> -Original Message- >> From: H.J. Lu [mailto:hjl.to...@gmail.com] >> Sent: Tuesday, November 14, 2017 1:18 PM >> To: Peryt, Sebastian

Re: Tweak vector::_M_realloc_insert for code size

2017-11-14 Thread Jonathan Wakely
On 11/11/17 19:14 +0100, Marc Glisse wrote: Hello, operator new can clobber memory, it is hard to teach the compiler otherwise since it is replaceable. Here I cache a couple values before the call to the allocator. I checked the result on this simple example: #include void f(std::vector){

Re: [v3 PATCH] Implement LWG 2733 and LWG 2759

2017-11-14 Thread Jonathan Wakely
On 14/11/17 18:14 +0200, Ville Voutilainen wrote: Implement LWG 2733 and LWG 2759 * include/experimental/numeric (gcd): Reject cv-qualified bool. (lcm): Likewise. * include/std/numeric (gcd): Likewise. (lcm): Likewise. * testsuite/26_numerics/gcd/gcd_neg.cc: Add tests and

Re: [PATCH], make Float128 built-in functions work with -mabi=ieeelongdouble

2017-11-14 Thread Segher Boessenkool
Hi! On Fri, Nov 10, 2017 at 06:13:19PM -0500, Michael Meissner wrote: > This patch updates the float128 built-in functions that get/set exponents, get > mantissa, and do tests to work with _Float128 on the current system, and with > long double when -mabi=ieeelongdouble is used. > > The issue is

Patch ping^2

2017-11-14 Thread Jakub Jelinek
On Mon, Nov 06, 2017 at 05:22:36PM +0100, Jakub Jelinek wrote: > I'd like to ping the: > > http://gcc.gnu.org/ml/gcc-patches/2017-10/msg01895.html > PR debug/82718 > Fix DWARF5 .debug_loclist handling with hot/cold partitioning > > patch. Thanks Ping^2. Jakub

Re: [PATCH] Zero vptr in dtor for -fsanitize=vptr.

2017-11-14 Thread Jason Merrill
OK. On Mon, Nov 6, 2017 at 3:27 AM, Martin Liška wrote: > On 11/03/2017 04:21 PM, Jason Merrill wrote: >> On Fri, Nov 3, 2017 at 10:25 AM, Martin Liška wrote: >>> On 10/27/2017 09:44 PM, Nathan Sidwell wrote: On 10/27/2017 02:34 PM, Jakub Jelinek wrote:

[v3 PATCH] Implement LWG 2733 and LWG 2759

2017-11-14 Thread Ville Voutilainen
Tested on Linux-x64. 2017-11-14 Ville Voutilainen Implement LWG 2733 and LWG 2759 * include/experimental/numeric (gcd): Reject cv-qualified bool. (lcm): Likewise. * include/std/numeric (gcd): Likewise. (lcm): Likewise. *

Re: [PATCH] Zero vptr in dtor for -fsanitize=vptr.

2017-11-14 Thread Martin Liška
PING^1 On 11/06/2017 09:27 AM, Martin Liška wrote: On 11/03/2017 04:21 PM, Jason Merrill wrote: On Fri, Nov 3, 2017 at 10:25 AM, Martin Liška wrote: On 10/27/2017 09:44 PM, Nathan Sidwell wrote: On 10/27/2017 02:34 PM, Jakub Jelinek wrote: But when singly inheriting a

Re: Cleanup predict.c

2017-11-14 Thread Martin Liška
On 11/14/2017 10:20 AM, Jan Hubicka wrote: @@ -4670,11 +4671,12 @@ expand_call_inline (basic_block bb, gimp if (dump_file && (dump_flags & TDF_DETAILS)) { - fprintf (dump_file, "Inlining "); - print_generic_expr (dump_file, id->src_fn); - fprintf (dump_file, " to ");

RE: [PATCH][GCC][AARCH64]Bad code-gen for structure/block/unaligned memory access

2017-11-14 Thread Tamar Christina
Hi James, I have split off the aarch64 bit off from the generic parts and processed your feedback. Attached is the reworked patch. Ok for Tunk? Thanks, Tamar Thanks, Tamar gcc/ 2017-11-14 Tamar Christina * config/aarch64/aarch64.c

[PATCH][GCC][mid-end] Allow larger copies when target supports unaligned access [Patch (1/2)]

2017-11-14 Thread Tamar Christina
Hi All, This patch allows larger bitsizes to be used as copy size when the target does not have SLOW_UNALIGNED_ACCESS. fun3: adrpx2, .LANCHOR0 add x2, x2, :lo12:.LANCHOR0 mov x0, 0 sub sp, sp, #16 ldrhw1, [x2, 16] ldrbw2,

[GCC][PATCH][AArch64] Add negative tests for dotprod and set minimum version to v8.2 in the target bit.

2017-11-14 Thread Tamar Christina
Hi All, Dot Product is intended to only be available for Armv8.2-a and newer. While this restriction is reflected in the intrinsics, the patterns themselves were missing the Armv8.2-a bit. This means that using -march=armv8.1-a+dotprod incorrectly got the auto-vectorizer to generate dot product

[PATCH][GCC][ARM] Add Armv8.3-a to AArch32.

2017-11-14 Thread Tamar Christina
Hi All, This patch adds Armv8.3-a as an architecture to the compiler with the feature set inherited from Armv8.2-a. Bootstrapped regtested on arm-none-linux-gnueabihf and no issues. gcc/ 2017-11-14 Tamar Christina * config/arm/arm-cpus.in (armv8_3, ARMv8_3a,

[PATCH][GCC][ARM] Restrict TARGET_DOTPROD to baseline Armv8.2-a.

2017-11-14 Thread Tamar Christina
Hi All, Dot Product is intended to only be available for Armv8.2-a and newer. While this restriction is reflected in the intrinsics, the patterns themselves were missing the Armv8.2-a bit. While GCC would prevent invalid options e.g. `-march=armv8.1-a+dotprod` we should prevent the pattern from

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-11-14 Thread Jakub Jelinek
On Tue, Nov 14, 2017 at 06:40:32PM +0300, Maxim Ostapenko wrote: > > But on the upstream sanitizer repo, > > sanitizer_common/sanitizer_syscall_linux_arm.inc was added on Nov 8th, > > and also checks for retval >= -4095, hence handling the clone() error > > gracefully. So... can we merge again our

Re: [RFC PATCH] Merge libsanitizer from upstream

2017-11-14 Thread Maxim Ostapenko
Hi, On 13/11/17 15:47, Christophe Lyon wrote: On 30 October 2017 at 16:21, Maxim Ostapenko wrote: On 30/10/17 17:08, Christophe Lyon wrote: On 30/10/2017 11:12, Maxim Ostapenko wrote: Hi, sorry for the late response. On 20/10/17 13:45, Christophe Lyon wrote: Hi,

Re: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread H.J. Lu
On Tue, Nov 14, 2017 at 6:20 AM, Jakub Jelinek wrote: > On Tue, Nov 14, 2017 at 06:14:10AM -0800, H.J. Lu wrote: >> Just a thought, should we have a separate patch to add -mprefer-vzeroupper >> to cover all bases in the future, like >> >> /* opt_pass methods: */ >> virtual

Re: [build, libgcc, libgo] Adapt Solaris 12 references

2017-11-14 Thread Ian Lance Taylor via gcc-patches
On Tue, Nov 14, 2017 at 2:09 AM, Rainer Orth wrote: > >> With the change in the Solaris release model (no more major releases >> like Solaris 12 but only minor ones like 11.4), the Solaris 12 >> references in GCC need to be adapted. >> >> The following patch does

RE: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread Peryt, Sebastian
Attached is fixed patch. Sebastian > -Original Message- > From: H.J. Lu [mailto:hjl.to...@gmail.com] > Sent: Tuesday, November 14, 2017 1:18 PM > To: Peryt, Sebastian > Cc: Jakub Jelinek ; gcc-patches@gcc.gnu.org; Uros Bizjak >

Re: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread Jakub Jelinek
On Tue, Nov 14, 2017 at 06:14:10AM -0800, H.J. Lu wrote: > Just a thought, should we have a separate patch to add -mprefer-vzeroupper > to cover all bases in the future, like > > /* opt_pass methods: */ > virtual bool gate (function *) > { > return TARGET_AVX && (!TARGET_AVX512ER ||

Re: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread H.J. Lu
On Tue, Nov 14, 2017 at 4:17 AM, H.J. Lu wrote: > On Tue, Nov 14, 2017 at 3:18 AM, Peryt, Sebastian > wrote: >> I have updated tests and changelog according to Jakub's suggestions. >> Please find attached v2 of my patch. >> >> >> 14.11.2017

Re: [Patch AArch64] Stop generating BSL for simple integer code

2017-11-14 Thread James Greenhalgh
On Wed, Oct 04, 2017 at 05:44:07PM +0100, James Greenhalgh wrote: > > On Thu, Jul 27, 2017 at 06:49:01PM +0100, James Greenhalgh wrote: > > > > On Mon, Jun 12, 2017 at 02:44:40PM +0100, James Greenhalgh wrote: > > > [Sorry for the re-send. I spotted that the attributes were not right for > > >

Re: [PATCH, rs6000] Repair vec_xl, vec_xst, vec_xl_be, vec_xst_be built-in functions

2017-11-14 Thread Bill Schmidt
Please hold review on this until I investigate something that Carl brought up. Thanks, and sorry for the noise! -- Bill > On Nov 13, 2017, at 10:30 AM, Bill Schmidt > wrote: > > Hi, > > Some previous patches to add support for vec_xl_be and fill in gaps in

Re: [PATCH] Fix usage of REG_BR_PROBs (PR target/82927).

2017-11-14 Thread Joseph Myers
On Tue, 14 Nov 2017, Martin Liška wrote: > Hello. > > Quite obvious fix for SH target. Joseph can you please continue with testing? > I don't have a machine to test the patch. I don't have SH hardware, but can confirm that, in conjunction with Martin's glibc patch to work around strncpy

[PATCH] Fix usage of REG_BR_PROBs (PR target/82927).

2017-11-14 Thread Martin Liška
Hello. Quite obvious fix for SH target. Joseph can you please continue with testing? I don't have a machine to test the patch. Ready for trunk? Thanks, Martin gcc/ChangeLog: 2017-11-14 Martin Liska PR target/82927 * config/sh/sh-mem.cc: Initialize

Re: [libsanitizer] Fix Mac OS X 10.7 bootstrap (PR sanitizer/82824)

2017-11-14 Thread Jakub Jelinek
On Tue, Nov 14, 2017 at 01:57:21PM +0100, Rainer Orth wrote: > >> --- a/libsanitizer/configure.ac > >> +++ b/libsanitizer/configure.ac > >> @@ -140,6 +140,24 @@ case "$host" in > >> esac > >> AM_CONDITIONAL(USING_MAC_INTERPOSE, $MAC_INTERPOSE) > >> > >> +# lsan_common_mac.cc needs

[PATCH] Fix CFG cleanup iteration order

2017-11-14 Thread Richard Biener
This fixes a latent bug I ran into with RPO value-numbering work which similar to all SSA propagators and existing FRE/PRE do not perform elimination in unreachable code-regions. Those unreachable code-regions are controlled by if (0 != 0) style conditions and CFG cleanup is supposed to deal

Re: [libsanitizer] Fix Mac OS X 10.7 bootstrap (PR sanitizer/82824)

2017-11-14 Thread Rainer Orth
Hi Jakub, >> --- a/libsanitizer/configure.ac >> +++ b/libsanitizer/configure.ac >> @@ -140,6 +140,24 @@ case "$host" in >> esac >> AM_CONDITIONAL(USING_MAC_INTERPOSE, $MAC_INTERPOSE) >> >> +# lsan_common_mac.cc needs VM_MEMORY_OS_ALLOC_ONCE which was only >> +# introduced in Mac OS X

Re: [RFA][PATCH] 3/n Refactoring tree-vrp.c, step #3 introduce vr-values.c

2017-11-14 Thread Richard Biener
On Fri, Nov 10, 2017 at 11:57 PM, Jeff Law wrote: > > And here's the monster that pulls the vr_values class out of tree-vrp.c. > I've also pulled out the transitive closure of free routines that are > used strictly by vr-values.c. > > Like the gimple-ssa-evrp.c change, this

Re: PR82808

2017-11-14 Thread Richard Biener
On Tue, Nov 14, 2017 at 10:31 AM, Prathamesh Kulkarni wrote: > On 3 November 2017 at 15:38, Richard Biener > wrote: >> On Fri, Nov 3, 2017 at 6:15 AM, Prathamesh Kulkarni >> wrote: >>> Hi Martin, >>> As

Re: RFA (hash-map): PATCH to support GTY((cache)) with hash_map

2017-11-14 Thread Richard Biener
On Fri, Sep 15, 2017 at 11:45 PM, Jason Merrill wrote: > The hash_map interface is a lot more convenient than that of > hash_table for cases where it makes sense, but there hasn't been a way > to get the ggc_cache_remove behavior with a hash_map. In other words, > not marking

[PATCH] New lang hook

2017-11-14 Thread Nathan Sidwell
This patch addresses c++/82836 & c++/82737. The root cause was a bad assumption I made when moving the mangling alias machinery to its own hash table. I had thought that once we SET_DECL_ASSEMBLER_NAME, it never becomes unset (or changed). That is false. There are paths in the compiler

Re: [PATCH] enhance -Warray-bounds to handle strings and excessive indices

2017-11-14 Thread Richard Biener
On Mon, Nov 13, 2017 at 6:37 PM, Martin Sebor wrote: > Richard, this thread may have been conflated with the one Re: > [PATCH] enhance -Warray-bounds to detect out-of-bounds offsets > (PR 82455) They are about different things. > > I'm still looking for approval of: > >

Re: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread H.J. Lu
On Tue, Nov 14, 2017 at 3:18 AM, Peryt, Sebastian wrote: > I have updated tests and changelog according to Jakub's suggestions. > Please find attached v2 of my patch. > > > 14.11.2017 Sebastian Peryt > > gcc/ > > PR target/82941 >

Re: [PATCH] Fixes for PR68356, PR81210, and PR81693

2017-11-14 Thread Dominique d'Humières
> Le 13 nov. 2017 à 18:40, Mike Stump a écrit : > > On Nov 12, 2017, at 6:58 AM, H.J. Lu wrote: >> >> On Sun, Nov 12, 2017 at 6:22 AM, Dominique d'Humières >> wrote: >>> The following patch fixes PR68356, PR81210, and PR81693

RE: [PATCH][i386] PR82941/PR82942 - Adding vzeroupper generation for SKX

2017-11-14 Thread Peryt, Sebastian
I have updated tests and changelog according to Jakub's suggestions. Please find attached v2 of my patch. 14.11.2017 Sebastian Peryt gcc/ PR target/82941 PR target/82942 * config/i386/i386.c (pass_insert_vzeroupper): Modify gate condition

  1   2   >