Re: [PATCH] Forbid section anchors for ASan build (PR sanitizer/81697)

2017-08-07 Thread Vyacheslav Barinov
Hello, Andrew Pinski writes: > On Mon, Aug 7, 2017 at 11:15 PM, Slava Barinov wrote: >>gcc/ >>* varasm.c (use_object_blocks_p): Forbid section anchors for ASan >> >>gcc/testsuite/ >>* g++.dg/asan/global-alignment.cc: New test to test global >>variables al

Re: [PATCH] Forbid section anchors for ASan build (PR sanitizer/81697)

2017-08-07 Thread Andrew Pinski
On Mon, Aug 7, 2017 at 11:15 PM, Slava Barinov wrote: >gcc/ >* varasm.c (use_object_blocks_p): Forbid section anchors for ASan > >gcc/testsuite/ >* g++.dg/asan/global-alignment.cc: New test to test global >variables alignment. Can you describe this a littl

[PATCH] Forbid section anchors for ASan build (PR sanitizer/81697)

2017-08-07 Thread Slava Barinov
gcc/ * varasm.c (use_object_blocks_p): Forbid section anchors for ASan gcc/testsuite/ * g++.dg/asan/global-alignment.cc: New test to test global variables alignment. Signed-off-by: Slava Barinov --- gcc/ChangeLog | 6 ++ gc

[PATCH] Switch on *.cc tests for g++ ASan

2017-08-07 Thread Slava Barinov
* g++.dg/asan/asan.exp: Switch on *.cc tests. Signed-off-by: Slava Barinov --- gcc/testsuite/ChangeLog| 4 gcc/testsuite/g++.dg/asan/asan.exp | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index c21

[PATCH][v2] Fix target attribute handling (PR c++/81355).

2017-08-07 Thread Martin Liška
On 08/02/2017 09:56 PM, Martin Sebor wrote: > On 08/02/2017 01:04 PM, Jeff Law wrote: >> On 07/28/2017 05:13 AM, Martin Liška wrote: >>> Hello. >>> >>> Following patch skips empty strings in 'target' attribute. >>> Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. >>> >>> R

Re: [RFC][PATCH] Do refactoring of attribute functions and move them to attribs.[hc].

2017-08-07 Thread Martin Liška
Hello. I'm sending final version that I'm going to install. Compared to the previous version I tested all targets in contrib/config-list.mk. Martin >From 860a6af96c27be95ead1163e7512fdca4cc6a67a Mon Sep 17 00:00:00 2001 From: marxin Date: Wed, 12 Jul 2017 13:39:54 +0200 Subject: [PATCH] Do refa

Re: [1/2] PR 78736: New warning -Wenum-conversion

2017-08-07 Thread Prathamesh Kulkarni
On 1 August 2017 at 00:10, Prathamesh Kulkarni wrote: > On 11 July 2017 at 17:59, Prathamesh Kulkarni > wrote: >> On 13 June 2017 at 01:47, Joseph Myers wrote: >>> This is OK with one fix: >>> +C ObjC Var(warn_enum_conversion) Init(0) Warning LangEnabledBy(C Objc,Wall) >>> >>> I belie

Re: [RFC] propagate malloc attribute in ipa-pure-const pass

2017-08-07 Thread Prathamesh Kulkarni
On 31 July 2017 at 23:53, Prathamesh Kulkarni wrote: > On 23 May 2017 at 19:10, Prathamesh Kulkarni > wrote: >> On 19 May 2017 at 19:02, Jan Hubicka wrote: * LTO and memory management This is a general question about LTO and memory management. IIUC the following sequence take

RE: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Michael Collison
Richard, The pattern will only be matched if the value is positive. More specifically if the constant value is 32 (SImode) or 64 (DImode). -Original Message- From: Richard Kenner [mailto:ken...@vlsi1.ultra.nyu.edu] Sent: Monday, August 7, 2017 6:56 PM To: Michael Collison Cc: gcc-patch

RE: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Richard Kenner
> On Aarc64 SHIFT_COUNT_TRUNCATED is only true if SIMD code generation > is disabled. This is because the simd instructions can be used for > shifting but they do not truncate the shift count. In that case, the change isn't safe! Consider if the value was negative, for example. Yes, it's technic

Re: [PATCH] Output DIEs for outlined OpenMP functions in correct lexical scope

2017-08-07 Thread Kevin Buettner
On Wed, 10 May 2017 17:24:27 +0200 Jakub Jelinek wrote: > What I don't like is that the patch is inconsistent, it sets DECL_CONTEXT > of the child function for all kinds of outlined functions, but then you just > choose one of the many places and add it into the BLOCK tree. Any reason > why the

Re: [PATCH 00/22] RFC: integrated 3rd-party static analysis support

2017-08-07 Thread David Malcolm
On Fri, 2017-08-04 at 21:00 -0400, Eric Gallager wrote: > On 8/4/17, David Malcolm wrote: > > This patch kit clearly isn't ready yet as-is (see e.g. the > > "known unknowns" below), but I'm posting it now in the hope of > > getting early feedback. > > > > Summary > > === > > > > This patch k

RE: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Michael Collison
On Aarc64 SHIFT_COUNT_TRUNCATED is only true if SIMD code generation is disabled. This is because the simd instructions can be used for shifting but they do not truncate the shift count. -Original Message- From: Richard Kenner [mailto:ken...@vlsi1.ultra.nyu.edu] Sent: Monday, August 7,

Re: [PATCH][PR target/81535] Fix tests on Power

2017-08-07 Thread Segher Boessenkool
Hi Yuri, Sorry I missed this. Please cc: me to prevent that from happening. On Fri, Jul 28, 2017 at 05:42:00AM +0100, Yury Gribov wrote: > This patch fixes issues reported in > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81535 > > I removed call to g in pr79439.c because gcc was duplicating t

Re: [PATCH 1/2] simplify-rtx: The truncation of an IOR can have all bits set (PR81423)

2017-08-07 Thread Segher Boessenkool
On Tue, Jul 25, 2017 at 06:25:49AM -0500, Segher Boessenkool wrote: > On Mon, Jul 24, 2017 at 04:06:39PM -0600, Jeff Law wrote: > > > 2017-07-24 Segher Boessenkool > > > > > > gcc/testsuite/ > > > PR rtl-optimization/81423 > > > * gcc.c-torture/execute/pr81423.c: New testcase. > > I think i

Re: [Patch] Testsuite fixes for failures caused by patch for PR 80925 - loop peeling and alignment

2017-08-07 Thread Steve Ellcey
I am not sure why this is failing on Solaris/SPARC, do you have the vector dump file from the test so we can see what it says about the loop it stopped vectorizing?  I don't have a Solaris/SPARC system here, I tried to build an 'initial' gcc for sparc-sun-solaris2.11 but I  could not reproduce the

Re: [PATCH, rs6000] Fix diagnostic fallout for 32-bit

2017-08-07 Thread Segher Boessenkool
On Mon, Aug 07, 2017 at 01:25:51PM -0500, Bill Schmidt wrote: > A previous patch addressed capitalization issues with diagnostics in the > POWER backend. > Unfortunately I failed to test this code on 32-bit targets, and there are > some additional > test cases that run only in 32-bit mode that no

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jonathan Wakely
On 07/08/17 23:02 +0200, Jakub Jelinek wrote: On Mon, Aug 07, 2017 at 09:59:04PM +0100, Jonathan Wakely wrote: > If it is outlined without the first 7 lines, i.e. just the body of if (b), > then it could be duplicate_one_attribute (tree *, tree, const char *); > called like if (b) duplicate_one_

Re: [PATCH], PR target/81593, Optimize PowerPC vector sets coming from a vector extracts

2017-08-07 Thread Segher Boessenkool
On Mon, Aug 07, 2017 at 09:18:30AM -0400, Michael Meissner wrote: > > I don't like using NULL as a magic value at all; it does not simplify > > this interface, it complicates it instead. > > > > Can you move the "which half is high" decision to the callers? > > I rewrote the patch to eliminate th

define VXWORKS_HAVE_TLS for the AE/653/MILS series

2017-08-07 Thread Olivier Hainque
Hello, After the changes introduced to take advantage of the recent TLS support in VxWorks 7 https://gcc.gnu.org/ml/gcc-patches/2017-06/msg01991.html The attached patch is needed to allow builds for the AE/653/MILS series of VxWorks targets. Committing to mainline, fixing PR target/81755 (tes

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jakub Jelinek
On Mon, Aug 07, 2017 at 09:59:04PM +0100, Jonathan Wakely wrote: > > If it is outlined without the first 7 lines, i.e. just the body of if (b), > > then it could be duplicate_one_attribute (tree *, tree, const char *); > > called like if (b) duplicate_one_attribute (&DECL_ATTRIBUTES (b), s, "omp >

Re: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Richard Kenner
> That is simplify: > (SHIFT A (32 - B)) -> (SHIFT A (AND (NEG B) 31)) > etc. I think you need SHIFT_COUNT_TRUNCATED to be true for this to be valid, but this is exactly what I was getting at in my last message.

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jonathan Wakely
On 07/08/17 17:27 +0200, Jakub Jelinek wrote: On Mon, Aug 07, 2017 at 10:54:18AM -0400, Jason Merrill wrote: On 08/07/2017 05:08 AM, Jakub Jelinek wrote: > +tree s = lookup_attribute ("omp declare simd", > + DECL_ATTRIBUTES (newdecl)); > +

Re: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Richard Kenner
> This patch improves code generation for shifts with subtract > instructions where the first operand to the subtract is equal to the > bit-size of the operation. I would suspect that this will work on lots of targets. Is doing it in combine an option?

Re: [Patch][aarch64] Use IFUNCs to enable LSE instructions in libatomic on aarch64

2017-08-07 Thread Steve Ellcey
It would probably help if I included the patch. Steve Ellcey sell...@cavium.com 2017-08-07  Steve Ellcey   * Makefile.am (ARCH_AARCH64_LINUX_LSE): Add IFUNC_OPTIONS and libatomic_la_LIBADD. * config/linux/aarch64/host-config.h: New file. * config/linux/aarch64/ini

Re: [PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Andrew Pinski
On Mon, Aug 7, 2017 at 1:36 PM, Michael Collison wrote: > This patch improves code generation for shifts with subtract instructions > where the first operand to the subtract is equal to the bit-size of the > operation. > > > long f1(long x, int i) > { > return x >> (64 - i); > } > > int f2(int

[Patch][aarch64] Use IFUNCs to enable LSE instructions in libatomic on aarch64

2017-08-07 Thread Steve Ellcey
This patch uses the libatomic IFUNC infrastructure so that aarch64 machines that support the LSE instructions can use them.  Note that aarch64 still isn't enabling IFUNC support by default though I have submitted a patch to do that.  You can enable IFUNC support by configuring with --enable-gnu-ind

[PATCH] [Aarch64] Optimize subtract in shift counts

2017-08-07 Thread Michael Collison
This patch improves code generation for shifts with subtract instructions where the first operand to the subtract is equal to the bit-size of the operation. long f1(long x, int i) { return x >> (64 - i); } int f2(int x, int i) { return x << (32 - i); } With trunk at -O2 we generate: f1:

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Richard Sandiford
Arjan van de Ven writes: > On 8/7/2017 8:43 AM, Jakub Jelinek wrote: >> On Mon, Aug 07, 2017 at 08:39:24AM -0700, H.J. Lu wrote: >>> When Linux/x86-64 kernel is compiled with -fno-omit-frame-pointer. >>> this optimization removes more than 730 >>> >>> pushq %rbp >>> movq %rsp, %rbp >>> popq %rbp >

[patch, fortran] Fix PR 81116, missing dependency handling for allocatable character

2017-08-07 Thread Thomas Koenig
Hello world, the attached patch fixes the PR by adding a dependency check for the case of concatenation operators. Regression-tested. OK for trunk? Regards Thomas 2017-08-07 Thomas Koenig PR fortran/81116 * frontend-passes.c (realloc_string_callback): If expressio

[PATCH] Fix PR81354 (SLSR, insert on edges)

2017-08-07 Thread Bill Schmidt
Hi, PR81354 describes an ICE in SLSR that occurs when a GIMPLE PHI statement changes address during the SLSR pass. SLSR contains a mapping table from GIMPLE statements to entries in the candidate table that relies on this address remaining constant. The address change occurs during gimple_spli

Re: [PATCH] [PR79542][Ada] Fix ICE in dwarf2out.c with nested func. inlining

2017-08-07 Thread Jason Merrill
On 05/26/2017 10:12 AM, Pierre-Marie de Rodat wrote: On 05/08/2017 06:27 PM, Jason Merrill wrote: That seems like a bug; if gen_typedef_die is going to generate a DIE for a cloned typedef, it needs to associate the type with the DIE. Hm… gen_typedef_die generates a DIE for a DECL node, but mo

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Uros Bizjak
On Mon, Aug 7, 2017 at 3:48 PM, Michael Matz wrote: > Hi, > > On Mon, 7 Aug 2017, H.J. Lu wrote: > >> >> [hjl@gnu-tools-1 pr81736]$ >> >> >> >> Does it mean clang is broken? >> > >> > In my book, yes. >> >> Does GCC do this for all targets or just x86? > > No idea. If so I'd say those other targe

[committed] Add support for OpenMP atomics on bitfields (PR c/69389)

2017-08-07 Thread Jakub Jelinek
Hi! Apparently there is no restriction on #pragma omp atomic not being done on a bitfield, so this patch handles it by performing atomics on DECL_BIT_FIELD_REPRESENTATIVE instead. Bootstrapped/regtested on x86_64-linux and i686-linux, committed to trunk. 2017-08-07 Jakub Jelinek PR c

Re: C++ PATCH to fix ICE with bit-fields and ?: (PR c++/81607)

2017-08-07 Thread Jason Merrill
OK.

[PATCH, rs6000] Fix diagnostic fallout for 32-bit

2017-08-07 Thread Bill Schmidt
Hi, A previous patch addressed capitalization issues with diagnostics in the POWER backend. Unfortunately I failed to test this code on 32-bit targets, and there are some additional test cases that run only in 32-bit mode that now fail. This patch cleans those up. Tested on powerpc64-linux-gn

Re: [PATCH 3/3] matching tokens: C++ parts (v2)

2017-08-07 Thread Jason Merrill
On 08/01/2017 04:21 PM, David Malcolm wrote: @@ -27632,6 +27769,9 @@ cp_parser_sizeof_operand (cp_parser* parser, enum rid keyword) { tree type = NULL_TREE; + matching_parens parens; + parens.peek_open (parser); I was puzzled by this until I found that cp_parser_compou

[openacc, PR78266, committed] Fix diff_type in expand_oacc_for char iter_type

2017-08-07 Thread Tom de Vries
Hi, this fixes PR78266, an openacc PR. When compiling a gang loop with an iteration variable of type 'unsigned char' and 256 gangs: ... #pragma acc parallel loop num_gangs (256) for (unsigned char j = 0; j < 5; j++) .. we run into trouble. The 'diff_type' in expand_oacc_for is set to 'signed

[PATCH][OBVIOUS] Add missing header file attribs.h to couple of targets.

2017-08-07 Thread Martin Liška
I've been building cross compilers and this is part 2. Martin >From 924e6a075cfef0418a67eba5415fc96b841ea019 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 7 Aug 2017 19:08:38 +0200 Subject: [PATCH] Add missing header file attribs.h to couple of targets. gcc/ChangeLog: 2017-08-07 Martin Lisk

[PATCH][OBVIOUS] Fix missing include of header file in mips.c.

2017-08-07 Thread Martin Liška
Hi. This is small fallout of the patch. Installed as obvious. Martin >From ee45f39052dcd2efe468f3e6efc6608b77ab6054 Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 7 Aug 2017 18:42:38 +0200 Subject: [PATCH] Fix missing include of header file in mips.c. gcc/ChangeLog: 2017-08-07 Martin Liska

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Michael Matz
Hi, On Mon, 7 Aug 2017, Arjan van de Ven wrote: > I'm not surprised to see one. > I'm surprised to see a useless one. > > The "perf" benefit is real, and that's why I asked for one... but the reorder > made it an expensive 3 instruction nop for all intents and purposes. > If the pop was just bef

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread H.J. Lu
On Mon, Aug 7, 2017 at 9:19 AM, Arjan van de Ven wrote: > On 8/7/2017 9:16 AM, Michael Matz wrote: >> >> Hi, >> >> On Mon, 7 Aug 2017, Arjan van de Ven wrote: >> >>> wanting a framepointer is very nice and desired... >>> ... but if the optimizer/ins scheduler moves instructions outside of the >>>

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Arjan van de Ven
On 8/7/2017 9:16 AM, Michael Matz wrote: Hi, On Mon, 7 Aug 2017, Arjan van de Ven wrote: wanting a framepointer is very nice and desired... ... but if the optimizer/ins scheduler moves instructions outside of the frame'd portion, (it does it for cases like below as well), the value is already

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Michael Matz
Hi, On Mon, 7 Aug 2017, Arjan van de Ven wrote: > wanting a framepointer is very nice and desired... > ... but if the optimizer/ins scheduler moves instructions outside of the > frame'd portion, > (it does it for cases like below as well), the value is already negative for > these > functions tha

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Arjan van de Ven
On 8/7/2017 8:43 AM, Jakub Jelinek wrote: On Mon, Aug 07, 2017 at 08:39:24AM -0700, H.J. Lu wrote: When Linux/x86-64 kernel is compiled with -fno-omit-frame-pointer. this optimization removes more than 730 pushq %rbp movq %rsp, %rbp popq %rbp If you don't want the frame pointer, why are you c

PING^2: [PATCH] PR driver/81523: Make -static override -pie

2017-08-07 Thread H.J. Lu
On Mon, Jul 31, 2017 at 7:04 PM, H.J. Lu wrote: > On Mon, Jul 31, 2017 at 5:37 PM, Alan Modra wrote: >> On Mon, Jul 31, 2017 at 08:04:13AM -0700, H.J. Lu wrote: >>> On Mon, Jul 24, 2017 at 10:24 AM, H.J. Lu wrote: >>> > On Sun, Jul 23, 2017 at 8:14 AM, H.J. Lu wrote: >>> >> -static and -pie tog

PING^2: [PATCH] i386: Avoid stack realignment if possible

2017-08-07 Thread H.J. Lu
On Tue, Jul 25, 2017 at 7:54 AM, Uros Bizjak wrote: > On Tue, Jul 25, 2017 at 3:52 PM, H.J. Lu wrote: >> On Fri, Jul 14, 2017 at 4:46 AM, H.J. Lu wrote: >>> On Fri, Jul 7, 2017 at 5:56 PM, H.J. Lu wrote: On Fri, Jul 07, 2017 at 09:58:42AM -0700, H.J. Lu wrote: > On Fri, Dec 20, 2013 at

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Jakub Jelinek
On Mon, Aug 07, 2017 at 08:39:24AM -0700, H.J. Lu wrote: > When Linux/x86-64 kernel is compiled with -fno-omit-frame-pointer. > this optimization removes more than 730 > > pushq %rbp > movq %rsp, %rbp > popq %rbp If you don't want the frame pointer, why are you compiling with -fno-omit-frame-poin

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread H.J. Lu
On Mon, Aug 7, 2017 at 7:06 AM, Alexander Monakov wrote: > On Mon, 7 Aug 2017, Michael Matz wrote: >> > I am looking for a run-time test which breaks unwinder. >> >> I don't have one handy. Idea: make two threads, one endlessly looping in >> the "frame-less" function, the other causing a signal t

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jakub Jelinek
On Mon, Aug 07, 2017 at 10:54:18AM -0400, Jason Merrill wrote: > On 08/07/2017 05:08 AM, Jakub Jelinek wrote: > > + tree s = lookup_attribute ("omp declare simd", > > +DECL_ATTRIBUTES (newdecl)); > > + if (s) > > + { > >

[PING][PATCH][PR sanitizer/77631] Support separate debug info in libbacktrace

2017-08-07 Thread Denis Khalikov
Hello, this a ping for that patch https://gcc.gnu.org/ml/gcc-patches/2017-07/msg01958.html Thanks.

Re: Restore proper operation of -fdump-ada-spec in C++

2017-08-07 Thread Eric Botcazou
> It was broken by the recent removal of TYPE_METHODS. Hopefully last tweak... Tested on x86_64-suse-linux, applied on the mainline. 2017-08-07 Eric Botcazou c-family/ * c-ada-spec.c (has_nontrivial_methods): Test for FUNCTION_DECL. (print_ada_methods): Likewise. (pr

Re: [PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jason Merrill
On 08/07/2017 05:08 AM, Jakub Jelinek wrote: + tree s = lookup_attribute ("omp declare simd", +DECL_ATTRIBUTES (newdecl)); + if (s) + { + tree b + = builtin_decl

Re: [COMMITTED] PR46932: Fix unresolved in testsuite

2017-08-07 Thread Richard Earnshaw (lists)
On 07/08/17 15:42, Wilco Dijkstra wrote: > Richard Earnshaw wrote: >> >> Except that I think this would be better done as an 'effective target' >> test; something like >> >> dg-require-effective-target autoincdec >> >> that way new ports will be more likely to pick up relevant tests like this. > >

Re: [COMMITTED] PR46932: Fix unresolved in testsuite

2017-08-07 Thread Wilco Dijkstra
Richard Earnshaw wrote: > > Except that I think this would be better done as an 'effective target' > test; something like > > dg-require-effective-target autoincdec > > that way new ports will be more likely to pick up relevant tests like this. Sure but what would be a correct implementation of

Re: [COMMITTED] PR46932: Fix unresolved in testsuite

2017-08-07 Thread Richard Earnshaw (lists)
On 07/08/17 14:59, Wilco Dijkstra wrote: > Build only if pre-increment is supported. Given there is no config test, > add a list of targets which have HAVE_PRE_INCREMENT set. > > Committed as obvious. > Except that I think this would be better done as an 'effective target' test; something like

[PATCH][AArch64] Simplify aarch64_can_eliminate

2017-08-07 Thread Wilco Dijkstra
Simplify aarch64_can_eliminate - if we need a frame pointer, we must eliminate to HARD_FRAME_POINTER_REGNUM. Rather than hardcoding all combinations from the ELIMINABLE_REGS list, just do the correct check. ChangeLog: 2017-08-07 Wilco Dijkstra gcc/ * config/aarch64/aarch64.c (aarc

Re: [PATCH] Fix middle-end/81737

2017-08-07 Thread Richard Biener
On August 7, 2017 11:09:59 AM GMT+02:00, Marek Polacek wrote: >On Mon, Aug 07, 2017 at 10:58:09AM +0200, Jakub Jelinek wrote: >> On Mon, Aug 07, 2017 at 10:47:51AM +0200, Marek Polacek wrote: >> > In my recent change I failed to check whether the type domain >> > of a type is non-NULL and this go

Re: [PATCH 6/6] qsort comparator consistency checking

2017-08-07 Thread Pedro Alves
On 08/03/2017 05:23 PM, Alexander Monakov wrote: > Note that with vec::qsort -> vec::sort renaming (which should be less > controversial, STL also has std::vector::sort), the argument counting > trick won't be needed, the redirection will simply be: OTOH, std::sort's comparison function callback h

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Alexander Monakov
On Mon, 7 Aug 2017, Michael Matz wrote: > > I am looking for a run-time test which breaks unwinder. > > I don't have one handy. Idea: make two threads, one endlessly looping in > the "frame-less" function, the other causing a signal to the first thread, > and the signal handler checking that un

[COMMITTED] PR46932: Fix unresolved in testsuite

2017-08-07 Thread Wilco Dijkstra
Build only if pre-increment is supported. Given there is no config test, add a list of targets which have HAVE_PRE_INCREMENT set. Committed as obvious. 2017-08-07 Wilco Dijkstra PR middle-end/46932 * gcc.dg/pr46932.c: Compile on targets with pre-increment. -- diff --git a/gc

Re: [PATCH][AArch64] Add BIC-imm and ORR-imm SIMD pattern

2017-08-07 Thread Sudi Das
Hi Richard I have updated the patch according to your comments. Thanks for pointing it out and sorry for the delay! Sudi 2017-08-07 Sudakshina Das * config/aarch64/aarch64-protos.h (enum simd_immediate_check): New check type for aarch64_simd_valid_immediate. (aarch6

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Michael Matz
Hi, On Mon, 7 Aug 2017, H.J. Lu wrote: > >> [hjl@gnu-tools-1 pr81736]$ > >> > >> Does it mean clang is broken? > > > > In my book, yes. > > Does GCC do this for all targets or just x86? No idea. If so I'd say those other targets are broken as well (as long as the concept of frame pointer make

Re: [PATCH][AArch64] Use gen_frame_mem for callee-saves

2017-08-07 Thread Richard Earnshaw (lists)
On 04/08/17 13:24, Wilco Dijkstra wrote: > The frame code uses a mixture of gen_rtx_MEM and gen_frame_mem for > callee-saves. Callee-saves never alias with local variables, so using > gen_frame_mem is correct. Minor cleanup - no change in code. > > OK for commit? OK. R. > > ChangeLog: > 2017-

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread H.J. Lu
On Mon, Aug 7, 2017 at 6:32 AM, Michael Matz wrote: > Hi, > > On Mon, 7 Aug 2017, H.J. Lu wrote: > >> >> This will break unwinders relying on frame pointers to exist on all >> >> functions, for which projects conciously forced a frame pointer with this >> >> option. I don't think we can simply ov

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Andreas Schwab
On Aug 07 2017, Michael Matz wrote: > +/* { dg-final { scan-assembler "%\[re\]bp" } } */ Please use {} for regexps. Andreas. -- Andreas Schwab, SUSE Labs, sch...@suse.de GPG Key fingerprint = 0196 BAD8 1CE9 1970 F4BE 1748 E4D4 88E3 0EEA B9D7 "And now for something completely different."

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Michael Matz
Hi, On Mon, 7 Aug 2017, H.J. Lu wrote: > >> This will break unwinders relying on frame pointers to exist on all > >> functions, for which projects conciously forced a frame pointer with this > >> option. I don't think we can simply override user specified explicit > >> wishes in this way, presum

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread H.J. Lu
On Mon, Aug 7, 2017 at 6:21 AM, Uros Bizjak wrote: > On Mon, Aug 7, 2017 at 3:15 PM, Michael Matz wrote: >> Hi, >> >> On Mon, 7 Aug 2017, Uros Bizjak wrote: >> >>> On Sun, Aug 6, 2017 at 9:40 PM, H.J. Lu wrote: >>> > When there is no stack access, there is no need to use frame pointer >>> > even

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Uros Bizjak
On Mon, Aug 7, 2017 at 3:15 PM, Michael Matz wrote: > Hi, > > On Mon, 7 Aug 2017, Uros Bizjak wrote: > >> On Sun, Aug 6, 2017 at 9:40 PM, H.J. Lu wrote: >> > When there is no stack access, there is no need to use frame pointer >> > even if -fno-omit-frame-pointer is used. >> > >> > Tested on i686

Re: [PATCH, AArch64] Add falkor pipeline description.

2017-08-07 Thread Richard Earnshaw (lists)
On 02/08/17 22:54, Jim Wilson wrote: > This adds a pipeline description for the Qualcomm Falkor core. This was > tested with a bootstrap and make check. There were no regressions. This > gives about 0.5% performance gain on SPEC CPU2006 on our internal tree, which > has a few other patches that

Re: [PATCH], PR target/81593, Optimize PowerPC vector sets coming from a vector extracts

2017-08-07 Thread Michael Meissner
On Thu, Aug 03, 2017 at 10:01:41AM -0500, Segher Boessenkool wrote: > Hi Mike, > > On Wed, Aug 02, 2017 at 10:28:55AM -0400, Michael Meissner wrote: > > On Fri, Jul 28, 2017 at 04:08:50PM -0500, Segher Boessenkool wrote: > > > I think calling this with the rtx elementN args makes this only more >

Re: [PATCH] Add -std=c++2a

2017-08-07 Thread Pedro Alves
On 07/20/2017 02:33 PM, Andrew Sutton wrote: > This adds a new C++ dialect, enabled by -std=c++2a. Hi Andrew, I happened to skim this patch and notice a couple issues. See below. > +/* Set the C++ 202a draft standard (without GNU extensions if ISO). */ > +static void > +set_std_cxx2a (int iso)

Re: [PATCH] i386: Don't use frame pointer without stack access

2017-08-07 Thread Michael Matz
Hi, On Mon, 7 Aug 2017, Uros Bizjak wrote: > On Sun, Aug 6, 2017 at 9:40 PM, H.J. Lu wrote: > > When there is no stack access, there is no need to use frame pointer > > even if -fno-omit-frame-pointer is used. > > > > Tested on i686 and x86-64. OK for trunk? > > LGTM. This will break unwinder

Re: [PATCH] Verify edge probability consistency in verify_flow_info

2017-08-07 Thread Jan Hubicka
> On 08/04/2017 11:15 AM, Jan Hubicka wrote: > >>>OK for trunk if bootstrap and reg-test on x86_64 succeeds? > >>Yea, but I'd like to see ongoing work towards full checking. > > > >I have full checking in my tree for some time. At x86-64 bootstrap there > >is one remaining offender in simd_clone_a

Re: [PATCH 0/2] add unique_ptr class

2017-08-07 Thread Jonathan Wakely
On 05/08/17 01:36 -0400, Trevor Saunders wrote: On Fri, Aug 04, 2017 at 07:52:18PM +0100, Jonathan Wakely wrote: On 31/07/17 19:46 -0400, tbsaunde+...@tbsaunde.org wrote: > I've been saying I'd do this for a long time, but I'm finally getting to > importing the C++98 compatable unique_ptr class

Re: [PATCH][Arm] Test suite failures resulting from deprecation of -mstructure-size-boundary

2017-08-07 Thread Richard Earnshaw (lists)
On 06/08/17 00:25, Michael Collison wrote: > This patch fixes test case failures on arm targets due to > '-mstructure-size-boundary' being deprecated. The test cases were failing > because a warning was being issued and due to the fact that the size of > packed and unpacked structures is the sam

Re: [PATCH #4, cleanup, committed] Remove PowerPC -mvsx-small-integer

2017-08-07 Thread Segher Boessenkool
On Sun, Aug 06, 2017 at 04:05:44PM +0200, Andreas Schwab wrote: > On BE/-m64: > > FAIL: gcc.target/powerpc/loop_align.c scan-assembler .p2align 5,,31 Ah, see https://gcc.gnu.org/ml/gcc-testresults/2017-08/msg00382.html (also for your earlier message). So this happens on all BE. Segher

RE: [libgomp] Doc update - TASKLOOP/GOMP_doacross_ description

2017-08-07 Thread Venevtsev, Igor
Gentle ping;) Could someone please have a glance? Regards, Igor -Original Message- From: Venevtsev, Igor Sent: Friday, July 21, 2017 2:04 PM To: gcc-patches@gcc.gnu.org Cc: Jakub Jelinek Subject: [libgomp] Doc update - TASKLOOP/GOMP_doacross_ description Hi! This patch adds an Impleme

[PATCH][cygming] Share mingw fset-stack-executable with cygwin

2017-08-07 Thread JonY
This patch is in use by Cygwin for years, upstream to GCC. Committed to trunk. * gcc/config/i386/mingw.opt (fset-stack-executable): Removed. * gcc/config/i386/cygming.opt (fset-stack-executable): Moved from mingw.opt. * gcc/config/i386/cygwin.h: Define CHECK_EXECUT

Re: [PATCH, rs6000] Clean up capitalized diagnostic messages

2017-08-07 Thread Segher Boessenkool
Hi Andreas, On Sun, Aug 06, 2017 at 10:08:23AM +0200, Andreas Schwab wrote: > FAIL: gcc.target/powerpc/bfp/scalar-extract-exp-2.c (test for errors, line > 18) > FAIL: gcc.target/powerpc/bfp/scalar-extract-exp-2.c (test for excess errors) > FAIL: gcc.target/powerpc/bfp/scalar-extract-exp-5.c (te

[PATCH] print-rtl: NOT is ~, not !

2017-08-07 Thread Segher Boessenkool
Slim RTL dumps print the RTL code NOT as !, but that is misleading: its semantics are like the C operator ~. This fixes it. Committing as obvious. Segher 2017-08-07 Segher Boessenkool * print-rtl.c (print_exp): Print NOT as "~" instead of as "!". --- gcc/print-rtl.c | 2 +- 1 fi

RE: [GCC][PATCH][mid-end][Version 3] Optimize x * copysign (1.0, y) [Patch (1/2)]

2017-08-07 Thread Tamar Christina
Hi Richard, > switch (code) > { > case MULT_EXPR: > if (!convert_mult_to_widen (stmt, &gsi) > && !convert_expand_mult_copysign (stmt, &gsi) > && convert_mult_to_fma (stmt, >

Re: [PATCH] Fold (int *)&a + 4 to a[1] using offset_int (PR middle-end/81695)

2017-08-07 Thread Marek Polacek
On Sat, Aug 05, 2017 at 08:13:20PM -0700, H.J. Lu wrote: > This caused: > > https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81737 Fixed in r250912, sorry. Marek

Re: [PATCH GCC][5/5]Enable tree loop distribution at -O3 and above optimization levels.

2017-08-07 Thread Bin.Cheng
On Fri, Jun 23, 2017 at 12:04 PM, Richard Biener wrote: > On Fri, Jun 23, 2017 at 10:47 AM, Bin.Cheng wrote: >> On Fri, Jun 23, 2017 at 6:04 AM, Jeff Law wrote: >>> On 06/07/2017 02:07 AM, Bin.Cheng wrote: On Tue, Jun 6, 2017 at 6:47 PM, Jeff Law wrote: > On 06/02/2017 05:52 AM, Bin Ch

Re: [PATCH] Fix middle-end/81737

2017-08-07 Thread Marek Polacek
On Mon, Aug 07, 2017 at 10:58:09AM +0200, Jakub Jelinek wrote: > On Mon, Aug 07, 2017 at 10:47:51AM +0200, Marek Polacek wrote: > > In my recent change I failed to check whether the type domain > > of a type is non-NULL and this goof causes crashing on this > > testcase. > > > > Bootstrapped/regte

[PATCH] Improve -Ofast vectorization of std::sin etc. (PR libstdc++/81706)

2017-08-07 Thread Jakub Jelinek
Hi! glibc for -ffast-math annotates a couple of math functions with simd attribute, so that one can use vectorized versions with 4/8/16 vectorization factor. If one uses ::cos or ::cosf or std::cos(double), this works just fine, but not when using std::cos(float). This is because the libstdc++ h

Re: [PATCH] Fix middle-end/81737

2017-08-07 Thread Jakub Jelinek
On Mon, Aug 07, 2017 at 10:47:51AM +0200, Marek Polacek wrote: > In my recent change I failed to check whether the type domain > of a type is non-NULL and this goof causes crashing on this > testcase. > > Bootstrapped/regtested on x86_64-linux, ok for trunk? > > 2017-08-07 Marek Polacek > >

[PATCH] Fix middle-end/81737

2017-08-07 Thread Marek Polacek
In my recent change I failed to check whether the type domain of a type is non-NULL and this goof causes crashing on this testcase. Bootstrapped/regtested on x86_64-linux, ok for trunk? 2017-08-07 Marek Polacek PR middle-end/81737 * fold-const.c (fold_indirect_ref_1): Check ty

Re: [patch,avr] Fix PR20296 / PR81268: Better ISR prologues / epilogues

2017-08-07 Thread Martin Liška
Hello. After this revision I see: $ ../configure --target=avr-elf --enable-languages=c,c++ --disable-bootstrap $ make ../../gcc/config/avr/avr.c: In function ‘void avr_option_override()’: ../../gcc/config/avr/avr.c:778:29: error: lvalue required as left operand of assignment TARGET_GASISR_P

Re: [PATCH 1/3] optabs: ensure mem_thread_fence is a compiler barrier

2017-08-07 Thread Alexander Monakov
On Sat, 5 Aug 2017, Richard Sandiford wrote: > It would be simpler to test whether targetm.gen_mem_thread_fence > returns NULL. > > This feels a bit hacky though. Checking whether a generator produced no > instructions is usually the test for whether the generator FAILed, which > should normally

[PATCH] Fix s390x-linux bootstrap against glibc 2.12

2017-08-07 Thread Jakub Jelinek
Hi! GCC 7 and trunk apparently doesn't bootstrap on s390x-linux against old glibc like 2.12 (in RHEL 6), the problem is that before https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=cbff0d9689c4d68578b6a4f0a17807232506ea27 PTRACE_GETREGSET etc. wasn't defined in . Fixed thusly, bootstrapped/