Re: [PATCH 1/2] Untangle stddef.h a little

2018-02-28 Thread Kamil Rytarowski
On 01.03.2018 03:43, co...@sdf.org wrote: > hi gcc-patches, > > as part of pinging, i'll explain the story of this patch. > > I want to make sure all netbsd archs work with upstream gcc. > in this case, netbsd/arm's EABI support. > I try to break up my changes into digestible chunks that are

Re: [PATCH, rs6000] Fix PR84534: several powerpc test cases fail starting with r257915

2018-02-28 Thread Peter Bergner
On 2/28/18 5:01 PM, Segher Boessenkool wrote: > On Wed, Feb 28, 2018 at 04:51:27PM -0600, Peter Bergner wrote: >> Doh! I was going to say "why?" since we're xfailing it everywhere, but I > > Because you can use a few more words in changelog entries ;-) > > "Add xfail." is fine, too. Just

Re: [PATCH 1/2] Untangle stddef.h a little

2018-02-28 Thread coypu
hi gcc-patches, as part of pinging, i'll explain the story of this patch. I want to make sure all netbsd archs work with upstream gcc. in this case, netbsd/arm's EABI support. I try to break up my changes into digestible chunks that are rational, which is why this change came first. building

Re: [PATCH] Fix -fcompare-debug failure on pr84146.c (PR target/84146)

2018-02-28 Thread Paul Hua
Hi Jakub: It's introduce a regression on mips target. see https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84623. Paul hua On Thu, Feb 8, 2018 at 6:36 AM, Jakub Jelinek wrote: > Hi! > > Unfortunately, seems my rest_of_insert_endbranch fix doesn't fix > -fcompare-debug on the

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Segher Boessenkool
On Wed, Feb 28, 2018 at 04:43:56PM -0800, Kees Cook wrote: > On Wed, Feb 28, 2018 at 4:39 PM, Segher Boessenkool > wrote: > > On Wed, Feb 28, 2018 at 04:15:23PM -0800, Kees Cook wrote: > >> On Wed, Feb 28, 2018 at 3:23 PM, Segher Boessenkool > >>

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Kees Cook via gcc-patches
On Wed, Feb 28, 2018 at 4:39 PM, Segher Boessenkool wrote: > On Wed, Feb 28, 2018 at 04:15:23PM -0800, Kees Cook wrote: >> On Wed, Feb 28, 2018 at 3:23 PM, Segher Boessenkool >> wrote: >> > I'm trying to figure out how to get that file to

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Segher Boessenkool
On Wed, Feb 28, 2018 at 04:15:23PM -0800, Kees Cook wrote: > On Wed, Feb 28, 2018 at 3:23 PM, Segher Boessenkool > wrote: > > I'm trying to figure out how to get that file to build at all :-) > $ CROSS_COMPILE=powerpc-linux-gnu- ARCH=powerpc make wii_defconfig > $ for

Re: [PATCH PR other/77609] Let the assembler choose ELF section types for miscellaneous named sections

2018-02-28 Thread Roland McGrath via gcc-patches
OK. I'll come back in stage 1. Thanks, Roland

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Kees Cook via gcc-patches
On Wed, Feb 28, 2018 at 3:23 PM, Segher Boessenkool wrote: > On Wed, Feb 28, 2018 at 01:46:33PM -0800, Kees Cook wrote: >> On Tue, Feb 27, 2018 at 2:01 PM, Segher Boessenkool >> wrote: >> > This adds a new option -mreadonly-in-sdata (on by

Re: [PATCH PR other/77609] Let the assembler choose ELF section types for miscellaneous named sections

2018-02-28 Thread Ian Lance Taylor via gcc-patches
On Wed, Feb 28, 2018 at 3:56 PM, Roland McGrath wrote: > On Tue, Feb 27, 2018 at 8:14 PM, Ian Lance Taylor wrote: >> Still OK, but it should wait until after the tree is back in stage 1. > > I've been hoping to get this fixed on stable branches (6, 7). > Are

Re: [PATCH PR other/77609] Let the assembler choose ELF section types for miscellaneous named sections

2018-02-28 Thread Roland McGrath via gcc-patches
On Tue, Feb 27, 2018 at 8:14 PM, Ian Lance Taylor wrote: > Still OK, but it should wait until after the tree is back in stage 1. I've been hoping to get this fixed on stable branches (6, 7). Are you saying that this bug can only be fixed in 9? Or will it be OK to backport to 6,

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Segher Boessenkool
On Wed, Feb 28, 2018 at 01:46:33PM -0800, Kees Cook wrote: > On Tue, Feb 27, 2018 at 2:01 PM, Segher Boessenkool > wrote: > > This adds a new option -mreadonly-in-sdata (on by default) that > > controls whether readonly data can be put in sdata. (For EABI this > >

Re: [PATCH] expand description of poly_int conversions

2018-02-28 Thread Jeff Law
On 02/26/2018 02:09 PM, Richard Sandiford wrote: > Martin Sebor writes: >> On 02/26/2018 12:45 PM, Richard Sandiford wrote: >>> Martin Sebor writes: Richard, If you agree, I'd like to update the conversion section of the poly_int manual to

Re: Tighten use of HARD_FRAME_POINTER_REGNUM in alias.c (PR 84538)

2018-02-28 Thread Jeff Law
On 02/28/2018 10:51 AM, Richard Sandiford wrote: > RTL code needs to be consistent about whether it uses the stack > pointer, the frame pointer or the argument pointer to access a > given part of the frame. alias.c used this to divide accesses > into three independent areas. > > The problem in

Re: [PATCH, rs6000] Fix PR84534: several powerpc test cases fail starting with r257915

2018-02-28 Thread Segher Boessenkool
On Wed, Feb 28, 2018 at 04:51:27PM -0600, Peter Bergner wrote: > On 2/28/18 4:36 PM, Segher Boessenkool wrote: > >>* gcc.target/powerpc/vec-setup-be-long.c: xfail. > > > > "Add xfail for powerpc64le" or similar? > > Doh! I was going to say "why?" since we're xfailing it everywhere, but I

Re: [PATCH, rs6000] Fix PR84534: several powerpc test cases fail starting with r257915

2018-02-28 Thread Peter Bergner
On 2/28/18 4:36 PM, Segher Boessenkool wrote: >> * gcc.target/powerpc/vec-setup-be-long.c: xfail. > > "Add xfail for powerpc64le" or similar? Doh! I was going to say "why?" since we're xfailing it everywhere, but I see I messed up that hunk, which should be "xfail {*-*-*}". The test case

[PATCH] merge attributes from function template redeclarations (PR 84294)

2018-02-28 Thread Martin Sebor
Attached is a patch for the failure to merge a subset of attributes specified on redeclarations of a function template with those of the first declaration (const, malloc, pure, noinline, noreturn, and nothrow). This was uncovered this morning while debugging failures in tests I added just

Re: [PATCH, rs6000] Fix PR84534: several powerpc test cases fail starting with r257915

2018-02-28 Thread Segher Boessenkool
Hi! On Wed, Feb 28, 2018 at 09:39:14AM -0600, Peter Bergner wrote: > This patch fixes PR84534 by XFAILing one test because we are deprecating > -maltivec=be when run on LE. The other tests are fixed by not counting > xxlor insns. We cannot rely on stable counts of xxlor insns, because we >

RE: [PATCH, PR83327] Fix liveness analysis in lra for spilled-into hard regs

2018-02-28 Thread Matthew Fortune
Tom de Vries writes: > On 02/26/2018 12:00 PM, Matthew Fortune wrote: > > Tom de Vries writes: > >> On 01/08/2018 05:32 PM, Tom de Vries wrote: > >>> On 12/18/2017 05:57 PM, Vladimir Makarov wrote: > > > On 12/15/2017 06:25 AM, Tom

Re: [PATCH, rs6000] (v2) Update altivec-7 testcase(s).

2018-02-28 Thread Segher Boessenkool
Hi Will, On Tue, Feb 27, 2018 at 09:23:12AM -0600, Will Schmidt wrote: > Move the vsx related content from the altivec-7-be test into > a new vsx-7-be test. Split out the VSX specific bits into a vsx-7.h > header file, and include that when appropriate. > *

Re: C++ PATCH to fix static init with () in a template (PR c++/84582)

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 4:19 PM, Marek Polacek wrote: > On Wed, Feb 28, 2018 at 10:51:17AM -0500, Jason Merrill wrote: >> On Wed, Feb 28, 2018 at 9:32 AM, Marek Polacek wrote: >> > On Tue, Feb 27, 2018 at 04:16:31PM -0500, Jason Merrill wrote: >> >> On

Re: [PATCH] Fix aarch64_simd_reg_or_zero predicate (PR fortran/84565)

2018-02-28 Thread Jakub Jelinek
On Tue, Feb 27, 2018 at 02:22:22PM +, Richard Sandiford wrote: > > Bootstrapped/regtested on aarch64-linux (scratch Fedora gcc 8 package build > > with the patch applied), ok for trunk? > > > > 2018-02-27 Jakub Jelinek > > > > PR fortran/84565 > > *

Re: [PATCH] [RFC] rs6000: -mreadonly-in-sdata (PR82411)

2018-02-28 Thread Kees Cook via gcc-patches
On Tue, Feb 27, 2018 at 2:01 PM, Segher Boessenkool wrote: > This adds a new option -mreadonly-in-sdata (on by default) that > controls whether readonly data can be put in sdata. (For EABI this > does nothing, readonly data is put in sdata2 as usual). Cool! Thanks

C++ PATCH for c++/71784, ICE with explicit specialization and ref-qualifier

2018-02-28 Thread Jason Merrill
determine_specialization hadn't been taught about ref-qualifiers yet. Tested x86_64-pc-linux-gnu, applying to trunk/7/6. commit f69972ff3fa2b33609e1952c0936f13e98161e5f Author: Jason Merrill Date: Wed Feb 28 15:17:08 2018 -0500 PR c++/71784 - ICE with

Re: C++ PATCH to fix static init with () in a template (PR c++/84582)

2018-02-28 Thread Marek Polacek
On Wed, Feb 28, 2018 at 10:51:17AM -0500, Jason Merrill wrote: > On Wed, Feb 28, 2018 at 9:32 AM, Marek Polacek wrote: > > On Tue, Feb 27, 2018 at 04:16:31PM -0500, Jason Merrill wrote: > >> On 02/27/2018 02:13 PM, Marek Polacek wrote: > >> > My recent change introducing

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Paolo Carlini
Hi, On 28/02/2018 20:20, Jason Merrill wrote: Hmm, the test seems wrong; the diagnostic talks about specializing the arguments, but the actual test is checking whether the enclosing scope is fully specialized. It looks like you'll give the same error for template struct A { template

[PATCH] AIX 7.1 and 7.2 configure support

2018-02-28 Thread David Edelsohn
AIX 7.1 continues to support Power4 as the minimum ISA level, so this reverts the recent patch to aix71.h. AIX 7.2 requires Power7 as the minimum ISA level. The second part of this patch adds a new aix72.h file and updates config.gcc. Thanks, David * config.gcc (powerpc-ibm-aix7.1.*): New

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 1:42 PM, Paolo Carlini wrote: > Hi, > > On 28/02/2018 17:24, Jason Merrill wrote: >>> >>> What do you think, should we do something similar? >> >> Sounds good. >> >>> (by the way, yesterday >>> got a bit confused because in other vaguely related

Re: [PR c++/84596] implicit conv in static assert

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 8:57 AM, Marek Polacek wrote: > On Wed, Feb 28, 2018 at 09:11:24AM -0300, Alexandre Oliva wrote: >> Evaluation of constant expressions, such as those passed to >> static_assert, ICEd when encountering IMPLICIT_CONV_EXPRs. >> >> Handle them like

Re: [PR c++/84593] ice on braced init with uninit ref field

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 7:08 AM, Alexandre Oliva wrote: > Don't allow the initializer expr to be NULL in a ctor initializer > list, make it error_marker_node instead. I don't want error_mark_nodes in a CONSTRUCTOR, either. When there isn't an NSDMI to worry about, we

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Paolo Carlini
Hi, On 28/02/2018 17:24, Jason Merrill wrote: What do you think, should we do something similar? Sounds good. (by the way, yesterday got a bit confused because in other vaguely related cases clang also has this kind of two-part error message and we don't. Eg, I cooked up: template class

Re: [PATCH] Use warning_n instead of warning_at in gimple-ssa-warn-restrict.c

2018-02-28 Thread Joseph Myers
On Wed, 28 Feb 2018, Jakub Jelinek wrote: > Hi! > > This patch should fix most of the translation issues with plural forms > in gimple-ssa-warn-restrict.c, now that warning_n accepts UHWI, we can and > should just use warning_n in those cases. > > I haven't touched the first set of warning_at

[PATCH] pr84014 testcase fix

2018-02-28 Thread David Edelsohn
The powerpc-specific testcase should test ilp32 and not invoke -m32 explicitly. Thanks, David Index: pr84014.c === --- pr84014.c (revision 258076) +++ pr84014.c (working copy) @@ -1,5 +1,5 @@ -/* { dg-do compile { target

Tighten use of HARD_FRAME_POINTER_REGNUM in alias.c (PR 84538)

2018-02-28 Thread Richard Sandiford
RTL code needs to be consistent about whether it uses the stack pointer, the frame pointer or the argument pointer to access a given part of the frame. alias.c used this to divide accesses into three independent areas. The problem in the PR is that we did this for HARD_FRAME_POINTER_REGNUM even

Re: [PR c++/84492] return stmt expr ending with overload

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 7:06 AM, Alexandre Oliva wrote: > We ICEd when returning a stmt expr that ends with an overloaded > function. It's ill-formed when we can't convert the function name to > the return type, but we should say that, not ICE. Hmm, what about the case where

Re: [Patch, fortran] PR83901 - [8 Regression] ICE in fold_convert_loc, at fold-const.c:2402

2018-02-28 Thread Paul Richard Thomas
Committed as revision 258076. Paul On 27 February 2018 at 19:35, Paul Richard Thomas wrote: > Hi All, > > I will commit this patch as obvious tomorrow night unless there are > objections in the meantime. > > Bootstraps and regtests on FC27/x86_64 - OK? > > Paul >

Re: [RFA][PATCH][PR middle-end/61118] Improve tree CFG accuracy for setjmp/longjmp

2018-02-28 Thread Jeff Law
On 02/28/2018 03:43 AM, Richard Biener wrote: > On Wed, Feb 28, 2018 at 1:16 AM, Jeff Law wrote: [ ... snip ...] >> >> Anyway, I'd already been looking at 21161 and was aware that the CFG's >> we're building in presence of setjmp/longjmp were slightly inaccurate. >> >> In

Re: [PATCH] handle fallout from attributes patch (PR 84617)

2018-02-28 Thread Jason Merrill
OK if testing passes. On Wed, Feb 28, 2018 at 12:09 PM, Martin Sebor wrote: > The attached patch fixes the regressions in merging attributes > on ordinary functions introduced by yesterday's commit to fix > bug 83871. I've also added a new test to exercise the malloc > bit

[PATCH] handle fallout from attributes patch (PR 84617)

2018-02-28 Thread Martin Sebor
The attached patch fixes the regressions in merging attributes on ordinary functions introduced by yesterday's commit to fix bug 83871. I've also added a new test to exercise the malloc bit even better (this is test #3 for a single bit). I have xfailed for now the remaining failures that expose

Re: Don't vectorise zero-step rmw operations (PR 84485)

2018-02-28 Thread Richard Sandiford
Jakub Jelinek writes: > On Wed, Feb 28, 2018 at 02:20:27PM +, Richard Sandiford wrote: >> GCC 6 and 7 would vectorise: >> >> void >> f (unsigned long incx, unsigned long incy, >>float *restrict dx, float *restrict dy) >> { >> unsigned long ix = 0, iy = 0; >> for

Re: [C++] [PR84231] overload on cond_expr in template

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 12:24 AM, Alexandre Oliva wrote: > + if (processing_template_decl) > +result_type = cp_build_reference_type (result_type, !is_lvalue); If !is_lvalue, we don't want a reference type at all, as the result is a prvalue. is_lvalue should probably

[Aarch64] Fix couple of formatting issues

2018-02-28 Thread Eric Botcazou
Superfluous parentheses plus trailing spaces introduced last June. Tested on AArch64/Linux, applied on the mainline as obvious. 2018-02-28 Eric Botcazou * config/aarch64/aarch64.c (aarch64_emit_probe_stack_range): Remove superfluous parentheses and

Re: [PATCH] Fix i18n in warn_spec_missing_attributes (PR 83871)

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 5:26 AM, Jakub Jelinek wrote: > On Tue, Feb 27, 2018 at 05:52:03PM -0700, Martin Sebor wrote: >> > This is broken for multiple reasons: >> > 1) it should be inform_n rather than inform >> > 2) you really can't do what you're doing for translations; >> >

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 11:18 AM, Paolo Carlini wrote: > On 28/02/2018 16:53, Jason Merrill wrote: >> On Wed, Feb 28, 2018 at 9:36 AM, Paolo Carlini >> wrote: >>> >>> in this P2 ICE on invalid we fail to diagnose an ill-formed variable >>>

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Paolo Carlini
Hi, On 28/02/2018 16:53, Jason Merrill wrote: On Wed, Feb 28, 2018 at 9:36 AM, Paolo Carlini wrote: in this P2 ICE on invalid we fail to diagnose an ill-formed variable template partial specialization and the assert at the beginning of determine_specialization

Re: [RFC PATCH] avoid applying attributes to explicit specializations (PR 83871)

2018-02-28 Thread Jason Merrill
On Tue, Feb 27, 2018 at 7:52 PM, Martin Sebor wrote: > There are many places in the C++ front-end where a string > enclosed in G_() is assigned to a pointer and later used > in a diagnostic call. Is there something different about > the usage I introduced that makes it

Re: [RFC PATCH] avoid applying attributes to explicit specializations (PR 83871)

2018-02-28 Thread Martin Sebor
On 02/28/2018 02:51 AM, Jakub Jelinek wrote: On Mon, Feb 26, 2018 at 09:19:56PM -0700, Martin Sebor wrote: PR c++/83871 PR c++/83503 * g++.dg/ext/attr-const.C: New test. * g++.dg/ext/attr-pure.C: New test. I've tried to fix these 2 tests with following patch,

Re: PING: [PATCH] i386: Add TARGET_INDIRECT_BRANCH_REGISTER

2018-02-28 Thread Jeff Law
On 02/28/2018 02:39 AM, Steve Beattie wrote: > Hi Jeff, > > On Thu, Feb 22, 2018 at 10:10:13AM -0700, Jeff Law wrote: >> A few notes. >> >> 1. It's not even clear at this time that retpolining user space binaries >> makes any sense at all. SO before doing anything to make this easier >> I'd

Re: [C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 9:36 AM, Paolo Carlini wrote: > in this P2 ICE on invalid we fail to diagnose an ill-formed variable > template partial specialization and the assert at the beginning of > determine_specialization triggers. Indeed, we didn't diagnose the problem >

Re: C++ PATCH to fix static init with () in a template (PR c++/84582)

2018-02-28 Thread Jason Merrill
On Wed, Feb 28, 2018 at 9:32 AM, Marek Polacek wrote: > On Tue, Feb 27, 2018 at 04:16:31PM -0500, Jason Merrill wrote: >> On 02/27/2018 02:13 PM, Marek Polacek wrote: >> > My recent change introducing cxx_constant_init caused this code >> > >> > template class A { >> >

Re: Don't vectorise zero-step rmw operations (PR 84485)

2018-02-28 Thread Jakub Jelinek
On Wed, Feb 28, 2018 at 02:20:27PM +, Richard Sandiford wrote: > GCC 6 and 7 would vectorise: > > void > f (unsigned long incx, unsigned long incy, >float *restrict dx, float *restrict dy) > { > unsigned long ix = 0, iy = 0; > for (unsigned long i = 0; i < 512; ++i) > { >

Re: [PATCH, rs6000] Fix PR83399, ICE During LRA with 2-op rtl pattern for lvx instruction

2018-02-28 Thread Peter Bergner
On 1/10/18 3:10 PM, Peter Bergner wrote: > gcc/ > PR target/83399 > * config/rs6000/rs6000.c (print_operand) <'y'>: Use > VECTOR_MEM_ALTIVEC_OR_VSX_P. > * config/rs6000/vsx.md (*vsx_le_perm_load_ for VSX_D): Use > indexed_or_indirect_operand predicate. >

Re: [RFA][PATCH][PR middle-end/61118] Improve tree CFG accuracy for setjmp/longjmp

2018-02-28 Thread Jeff Law
On 02/28/2018 03:48 AM, Richard Biener wrote: > On Wed, Feb 28, 2018 at 11:43 AM, Richard Biener > wrote: >> On Wed, Feb 28, 2018 at 1:16 AM, Jeff Law wrote: >>> Richi, you worked on 57147 which touches on the issues here. Your >>> thoughts would be

[PATCH, rs6000] Fix PR84534: several powerpc test cases fail starting with r257915

2018-02-28 Thread Peter Bergner
This patch fixes PR84534 by XFAILing one test because we are deprecating -maltivec=be when run on LE. The other tests are fixed by not counting xxlor insns. We cannot rely on stable counts of xxlor insns, because we generate them not only when using __builtin_vec_or(), but also whenever we need

[PATCH] Fix i18n in warn_spec_missing_attributes (PR 83871)

2018-02-28 Thread Jakub Jelinek
On Tue, Feb 27, 2018 at 05:52:03PM -0700, Martin Sebor wrote: > > This is broken for multiple reasons: > > 1) it should be inform_n rather than inform > > 2) you really can't do what you're doing for translations; > >G_(...) marks the string for translations, but what actually is > >

[C++ Patch/RFC] PR 71569 ("[6/7/8 regression] Crash: External definition of template member from template struct")

2018-02-28 Thread Paolo Carlini
Hi, in this P2 ICE on invalid we fail to diagnose an ill-formed variable template partial specialization and the assert at the beginning of determine_specialization triggers. Indeed, we didn't diagnose the problem via check_specialization_scope (there are no template <>, thus

Re: C++ PATCH to fix static init with () in a template (PR c++/84582)

2018-02-28 Thread Marek Polacek
On Tue, Feb 27, 2018 at 04:16:31PM -0500, Jason Merrill wrote: > On 02/27/2018 02:13 PM, Marek Polacek wrote: > > My recent change introducing cxx_constant_init caused this code > > > > template class A { > >static const long b = 0; > >static const unsigned c = (b); > > }; > > > > to be

[Ada] Generate minimally correct C/C++ binding for stddef.h

2018-02-28 Thread Eric Botcazou
This was broken when the default was changed to C11/C++11. Tested on x86_64-suse-linux, applied on the mainline. 2018-02-28 Eric Botcazou ada/ * libgnat/i-cexten.ads (Float_128): New type. c-family/ * c-ada-spec.c (dump_ada_node) : New case. :

Don't vectorise zero-step rmw operations (PR 84485)

2018-02-28 Thread Richard Sandiford
GCC 6 and 7 would vectorise: void f (unsigned long incx, unsigned long incy, float *restrict dx, float *restrict dy) { unsigned long ix = 0, iy = 0; for (unsigned long i = 0; i < 512; ++i) { dy[iy] += dx[ix]; ix += incx; iy += incy; } } without first proving that

[Ada] Fix handling of nested enum types with -fdump-ada-spec

2018-02-28 Thread Eric Botcazou
They simply have been ignored up to now. Tested on x86_64-suse-linux, applied on the mainline. 2018-02-28 Eric Botcazou c-family/ * c-ada-spec.c (dump_ada_double_name) : New case. (is_char_array): Take a type instead of a declaration.

[Ada] Fix handling of incomplete types with -fdump-ada-spec (2/2)

2018-02-28 Thread Eric Botcazou
This extends the previous change to "opaque" types, i.e. types that are still incomplete at the end of the translation unit. Tested on x86_64-suse-linux, applied on the mainline. 2018-02-28 Eric Botcazou c-family/ * c-ada-spec.c (dump_ada_node) : Do not use

Re: [PR c++/84596] implicit conv in static assert

2018-02-28 Thread Marek Polacek
On Wed, Feb 28, 2018 at 09:11:24AM -0300, Alexandre Oliva wrote: > Evaluation of constant expressions, such as those passed to > static_assert, ICEd when encountering IMPLICIT_CONV_EXPRs. > > Handle them like CONVERT_EXPR and NOP_EXPR. > > Regstrapped on x86_64- and i686-linux-gnu. Ok to

[Ada] Fix handling of incomplete types with -fdump-ada-spec (1/2)

2018-02-28 Thread Eric Botcazou
In some cases, when a type is still incomplete, a pointer to this type will be translated as System.Address by -fdump-ada-spec, which is slightly annoying. This fixes most of these cases and generates proper access types instead. Tested on x86_64-suse-linux, applied on the mainline. 2018-02-28

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

2018-02-28 Thread Ville Voutilainen
On 28 February 2018 at 14:27, Ville Voutilainen wrote: > Partially tested on Linux-x64, will run full suite on Linux-PPC64. Which didn't reveal anything I didn't know, but reminded me to adjust the negative tests. :) 2018-02-28 Ville Voutilainen

[PR c++/84602] ICE with anon-struct

2018-02-28 Thread Nathan Sidwell
This fixes an ICE with anon-struct. When reimplementing this bit of name lookup, I relied on what the standard said and the completeness of the testsuite WRT extensions. Silly me. Anyway, we can just have the anon-struct lookup recurse to get_class_binding_direct, so simpler! nathan --

[v3 PATCH] PR libstdc++/84601

2018-02-28 Thread Ville Voutilainen
Partially tested on Linux-x64, will run full suite on Linux-PPC64. 2018-02-28 Ville Voutilainen PR libstdc++/84601 * include/std/optional (_Optional_payload): Split into multiple specializations that can handle different cases of trivial or

[PR c++/84596] implicit conv in static assert

2018-02-28 Thread Alexandre Oliva
Evaluation of constant expressions, such as those passed to static_assert, ICEd when encountering IMPLICIT_CONV_EXPRs. Handle them like CONVERT_EXPR and NOP_EXPR. Regstrapped on x86_64- and i686-linux-gnu. Ok to install? for gcc/cp/ChangeLog PR c++/84596 * constexpr.c

[PATCH] Fix PR84607

2018-02-28 Thread Richard Biener
genmatch was fooled by singelton expression leafs so it omitted the required TREE_SIDE_EFFECTS check and building a COMPOUND_EXPR for the side-effects. Bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2018-02-28 Richard Biener PR

[PR c++/84593] ice on braced init with uninit ref field

2018-02-28 Thread Alexandre Oliva
Don't allow the initializer expr to be NULL in a ctor initializer list, make it error_marker_node instead. Regstrapped on x86_64- and i686-linux-gnu. Ok to install? for gcc/cp/ChangeLog PR c++/84593 * typeck2.c (process_init_constructor_record): Set NULL next to

[PATCH] Fix PR84584

2018-02-28 Thread Richard Biener
The following fixes this PR. Bootstrap & regtest running on x86_64-unknown-linux-gnu. Richard. 2018-02-28 Richard Biener PR tree-optimization/84584 * graphite-scop-detection.c (scop_detection::add_scop): Discard SCoPs with fake exit edge.

[PR c++/84492] return stmt expr ending with overload

2018-02-28 Thread Alexandre Oliva
We ICEd when returning a stmt expr that ends with an overloaded function. It's ill-formed when we can't convert the function name to the return type, but we should say that, not ICE. The problem was that instantiate_type did not know what to do with STMT_EXPRs. Regstrapped on x86_64- and

Re: [PATCH] Fix timevar format and fix tests (PR testsuite/84597).

2018-02-28 Thread Richard Biener
On Wed, Feb 28, 2018 at 11:07 AM, Martin Liška wrote: > Hi. > > It's fix of 2 tests that I forgot to adjust. Apart from that I'm slightly > adjust > printf patterns in order to support '100%' values. > > Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. >

Re: [Aarch64] Fix conditional branches with target far away.

2018-02-28 Thread Sameera Deshpande
On 27 February 2018 at 18:25, Ramana Radhakrishnan wrote: > On Wed, Feb 14, 2018 at 8:30 AM, Sameera Deshpande > wrote: >> Hi! >> >> Please find attached the patch to fix bug in branches with offsets over 1MiB. >> There has been an attempt

Re: [RFA][PATCH][PR middle-end/61118] Improve tree CFG accuracy for setjmp/longjmp

2018-02-28 Thread Richard Biener
On Wed, Feb 28, 2018 at 11:43 AM, Richard Biener wrote: > On Wed, Feb 28, 2018 at 1:16 AM, Jeff Law wrote: >> Richi, you worked on 57147 which touches on the issues here. Your >> thoughts would be greatly appreciated. >> >> >> So 61118 is one of

Re: [RFA][PATCH][PR middle-end/61118] Improve tree CFG accuracy for setjmp/longjmp

2018-02-28 Thread Richard Biener
On Wed, Feb 28, 2018 at 1:16 AM, Jeff Law wrote: > Richi, you worked on 57147 which touches on the issues here. Your > thoughts would be greatly appreciated. > > > So 61118 is one of several bugs related to the clobbered-by-longjmp warning. > > In 61118 is we are unable to

Re: [PATCH] Fix pt.c bootstrap breakage

2018-02-28 Thread Richard Biener
On Wed, Feb 28, 2018 at 12:27 AM, David Edelsohn wrote: > The recent change to pt.c broke bootstrap by including C++ header file > directly and including it first. This patch changes to the > necessary method which includes the header file via system.h. > > Okay? Ok. But in

Re: [PATCH] Fix ms_struct/-mms-bitfields structure layout (PR target/52991)

2018-02-28 Thread JonY
On 02/28/2018 12:26 AM, Jakub Jelinek wrote: > Hi! > > The following patch fixes the reported ms_struct/-mms-bitfields structure > layout issues from PR52991. > > There are multiple issues, two of them introduced by the > https://gcc.gnu.org/ml/gcc-patches/2006-04/msg01064.html -mms-bitfields >

[PATCH] Fix timevar format and fix tests (PR testsuite/84597).

2018-02-28 Thread Martin Liška
Hi. It's fix of 2 tests that I forgot to adjust. Apart from that I'm slightly adjust printf patterns in order to support '100%' values. Patch can bootstrap on ppc64le-redhat-linux and survives regression tests. Ready to be installed? Martin gcc/ChangeLog: 2018-02-28 Martin Liska

Re: [RFC PATCH] avoid applying attributes to explicit specializations (PR 83871)

2018-02-28 Thread Jakub Jelinek
On Mon, Feb 26, 2018 at 09:19:56PM -0700, Martin Sebor wrote: > PR c++/83871 > PR c++/83503 > * g++.dg/ext/attr-const.C: New test. > * g++.dg/ext/attr-pure.C: New test. I've tried to fix these 2 tests with following patch, without -fdump-tree-optimized all the

[PATCH] Use warning_n instead of warning_at in gimple-ssa-warn-restrict.c

2018-02-28 Thread Jakub Jelinek
Hi! This patch should fix most of the translation issues with plural forms in gimple-ssa-warn-restrict.c, now that warning_n accepts UHWI, we can and should just use warning_n in those cases. I haven't touched the first set of warning_at calls, because the current wording requires two plural

Re: [RFC PATCH] avoid applying attributes to explicit specializations (PR 83871)

2018-02-28 Thread Jakub Jelinek
On Mon, Feb 26, 2018 at 09:19:56PM -0700, Martin Sebor wrote: > PR c++/83871 > PR c++/83503 > * g++.dg/Wmissing-attributes.C: New test. > * g++.dg/ext/attr-const-pure.C: New test. > * g++.dg/ext/attr-const.C: New test. > * g++.dg/ext/attr-deprecated-2.C: New

Re: [PATCH] adjust warning_n() to take uhwi (PR 84207)

2018-02-28 Thread Jakub Jelinek
On Tue, Feb 27, 2018 at 03:06:53PM -0700, Martin Sebor wrote: > On 02/22/2018 02:15 PM, Joseph Myers wrote: > > On Thu, 22 Feb 2018, Martin Sebor wrote: > > > > > Ping: https://gcc.gnu.org/ml/gcc-patches/2018-02/msg00858.html > > > > > > This is just a tweak to fix a translation bug introduced

Re: PING: [PATCH] i386: Add TARGET_INDIRECT_BRANCH_REGISTER

2018-02-28 Thread Steve Beattie
Hi Jeff, On Thu, Feb 22, 2018 at 10:10:13AM -0700, Jeff Law wrote: > A few notes. > > 1. It's not even clear at this time that retpolining user space binaries > makes any sense at all. SO before doing anything to make this easier > I'd like to see a justification for why it's really needed.

[Patch] test_summary: handle single quotes

2018-02-28 Thread Christophe Lyon
Hi, We happen to build GCC with '~' in the src and build dirs, leading to single quotes around the configure path in config.status. For example: [...]

Re: [PATCH] Fix ms_struct/-mms-bitfields structure layout (PR target/52991)

2018-02-28 Thread Kai Tietz
Hello Jakub, I can't approve this patch, but I can confirm that changes are sensible. I verified the structure layout - as far as possible - also with MS' compiler, and can confirm the adjustments. Cheers, Ka 2018-02-28 1:26 GMT+01:00 Jakub Jelinek : > Hi! > > The following