Re: libgo patch committed: netinet/icmp6.h require netinet/in.h on AIX

2017-08-31 Thread Rainer Orth
Hi Ian, > This patch from Tony Reix fixes the libgo configure script to > correctly decide whether netinet/icmp6.h exists on AIX. Bootstrapped > and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. unfortunately, this patch broke Solaris bootstrap (seen on Solaris 11.4, but the h

Re: [PATCH] Fix ancient wrong-code with ?: (PR middle-end/81814)

2017-08-31 Thread Eric Botcazou
> So you should be able to extract a C testcase? I suspect sth like > > long foo (long x, int y) > { > return y > x ? y : x; > } > > to no longer be folded to return MAX_EXPR (x, (long) y). > > That would be a shame btw. Any news on this? We're having regressions in Ada because of t

Re: [PATCH] Fix ancient wrong-code with ?: (PR middle-end/81814)

2017-08-31 Thread Richard Biener
On Thu, 31 Aug 2017, Eric Botcazou wrote: > > So you should be able to extract a C testcase? I suspect sth like > > > > long foo (long x, int y) > > { > > return y > x ? y : x; > > } > > > > to no longer be folded to return MAX_EXPR (x, (long) y). > > > > That would be a shame btw.

Re: [AArch64], patch] PR71727 fix -mstrict-align

2017-08-31 Thread Christophe Lyon
ping^2 ? On 21 August 2017 at 15:04, Christophe Lyon wrote: > ping ? > https://gcc.gnu.org/ml/gcc-patches/2017-07/msg01063.html > > Christophe > > > On 18 July 2017 at 14:50, Christophe Lyon wrote: >> Hello, >> >> I've received a complaint that GCC for AArch64 would generate >> vectorized code

[PATCH] Fix PR82054

2017-08-31 Thread Richard Biener
I am testing the following patch to fix another fallout of the assert that we dont' add duplicated dwarf attributes. LTO bootstrapped / bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2017-08-31 Richard Biener PR middle-end/82054 * dwarf2out.c (dwarf2

[PATCH] Fix PR81968 some more

2017-08-31 Thread Richard Biener
I am testing the following to silence more of Solaris ld warnings about early debug objects. LTO bootstrapped on x86_64-unknown-linux-gnu, testing in progress. Richard. 2017-08-31 Richard Biener PR lto/81968 * simple-object-elf.c (simple_object_elf_copy_lto_debug_section):

Re: [AArch64] Tweak aarch64_classify_address interface

2017-08-31 Thread Richard Sandiford
James Greenhalgh writes: > On Tue, Aug 22, 2017 at 10:23:47AM +0100, Richard Sandiford wrote: >> Previously aarch64_classify_address used an rtx code to distinguish >> LDP/STP addresses from normal addresses; the code was PARALLEL >> to select LDP/STP and anything else to select normal addresses.

[PATCH][GCC][AArch64][Committed] Actually reserve room for null terminator when mangling buildins.

2017-08-31 Thread Tamar Christina
Hi All, When mangling the builtin names and type signatures we create a buffer to hold SIMD_MAX_BUILTIN_ARGS arguments, but don't account for the null terminator for the string. Which means when you actually do use up to SIMD_MAX_BUILTIN_ARGS arguments you'll end up with garbage at the end of your

C++ PATCH to fix ICE with -Wbool-operation (PR c++/82040)

2017-08-31 Thread Marek Polacek
Here we got into re-entering the error reporting routines because the warning_at call wasn't guarded with "complain", and crash ensued. Bootstrapped/regtested on x86_64-linux, ok for trunk/7? 2017-08-31 Marek Polacek PR c++/82040 * typeck.c (cp_build_unary_op): Avoid re-enteri

[PATCH] Early LTO debug TODO

2017-08-31 Thread Richard Biener
As suspected during review the DECL_ABSTRACT_P handling in gen_formal_parameter_die is no longer necessary so the following patch removes it. [LTO] bootstrapped on x86_64-unknown-linux-gnu, testing in progress. The gdb testsuite shows no regression. Will apply after testing finished. Richard.

Re: C++ PATCH for c++/80767, unnecessary instantiation of generic lambda

2017-08-31 Thread David Edelsohn
Jason, The recent patch for 82030 PR c++/82030 - ICE inheriting from multiple lambdas PR c++/80767 * call.c (compare_ics): Handle null candidate. causes bootstrap to fail for AIX due to a segfault ICE building libstdc++ with stage1 compiler. - David

RE: [PATCH 1/7] [ARC] Improves and fixes for small data support.

2017-08-31 Thread Claudiu Zissulescu
> Remember to add both new testsuite files in the ChangeLog, but > otherwise looks good. > > Thanks, > Andrew > Done. Thank you for your review, Claudiu

Re: [PATCH] Early LTO debug TODO

2017-08-31 Thread Richard Biener
On Thu, 31 Aug 2017, Richard Biener wrote: > > As suspected during review the DECL_ABSTRACT_P handling in > gen_formal_parameter_die is no longer necessary so the following > patch removes it. > > [LTO] bootstrapped on x86_64-unknown-linux-gnu, testing in progress. > The gdb testsuite shows no r

Re: [PATCH] Fix ancient wrong-code with ?: (PR middle-end/81814)

2017-08-31 Thread Eric Botcazou
> Can you file a bugreport and include a testcase for gnat.dg so that > we can reproduce? Bonus points if you manage to create a C testcase > of course ;) How can I collect them exactly? ;-) unsigned long foo (int x) { return x > 0 ? (unsigned long) x : 0UL; } On x86-64/Linux with GCC 7.2.1,

RE: [PATCH 2/7] [ARC] Use -G option to control sdata behavior

2017-08-31 Thread Claudiu Zissulescu
> From looking at other targets, I think that we need to add > documentation for -G into the ARC Options section of of > gcc/doc/invoke.texi. Added to invoke.texi as suggested. > Is it critical that we rely on default types here? I know it's > legitimate, but it just makes me sad to see new cod

RE: [PATCH 3/7] [ARC] Update can_follow_jump hook helper.

2017-08-31 Thread Claudiu Zissulescu
> This looks fine. > Committed. Thank you for your review, Claudiu

C++ PATCH for c++/82029, ICE with __func__ in lambda in template

2017-08-31 Thread Jason Merrill
When tsubst_decl creates a new local static variable, it checks to see if it belongs to current_function_decl. It has done this by tsubsting the old DECL_CONTEXT, but that doesn't work with the new lambda model, where we can't get to the new lambda op() by tsubsting the old one. So this patch intr

C/C++ PATCH to add __remove_qualifiers (PR c/65455, c/39985)

2017-08-31 Thread Marek Polacek
After a long time, I'm finally sending the revisited patch dealing with these two PRs. To quickly recap, users were looking for a typeof variant that strips type qualifiers. I sent a path adding __typeof_noqual, but a discussion ensued and it's been concluded that we'd rather go a different way,

[AArch64 obvious] Fix register constraints for aarch64_ml[as]_elt_merge

2017-08-31 Thread James Greenhalgh
Hi, The MLA by-element instructions have the same restriction as other by-element instructions whereby the forms operating on vectors of 16-bit integer data may only use registers v0-v15. We have an iterator for that, applied to the other patterns generating this instruction, so use that. Bootst

Re: C/C++ PATCH to add __remove_qualifiers (PR c/65455, c/39985)

2017-08-31 Thread Joseph Myers
I think the documentation needs to say (and the tests need to test) that this produces a non-atomic type (like lvalue-to-rvalue conversion), if that's the intent for how it handles atomic types, since _Atomic is syntactically a qualifier but largely not treated like one in the standard. -- Jo

[PATCH] PR c++/82039 suppress -Wzero-as-null-pointer-constant warning

2017-08-31 Thread Jonathan Wakely
This avoids an unhelpful warning from a system header. Users can't change the code to avoid the warning, and we don't want to change it (because it needs to work for C++98 as well as later versions). PR c++/82039 * include/ext/new_allocator.h (__gnu_cxx::new_allocator::allocate):

Re: [RFC][AARCH64]Add 'r' integer register operand modifier. Document the common asm modifier for aarch64 target.

2017-08-31 Thread Renlin Li
Hi all, This is a split patch from a discussion here: https://gcc.gnu.org/ml/gcc-patches/2017-06/msg00289.html It contains the document part only. It clarify the behavior when no modifier is used for register operand. https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63359 'H' modifier is added for

Re: C++ PATCH for c++/80767, unnecessary instantiation of generic lambda

2017-08-31 Thread Jason Merrill
On Thu, Aug 31, 2017 at 9:37 AM, David Edelsohn wrote: > Jason, > > The recent patch for 82030 > > PR c++/82030 - ICE inheriting from multiple lambdas > > PR c++/80767 > * call.c (compare_ics): Handle null candidate. > > causes bootstrap to fail for AIX due to a

Re: [RFC][AARCH64]Add 'r' integer register operand modifier. Document the common asm modifier for aarch64 target.

2017-08-31 Thread Andrew Pinski
On Thu, Aug 31, 2017 at 9:59 AM, Renlin Li wrote: > Hi all, > > This is a split patch from a discussion here: > https://gcc.gnu.org/ml/gcc-patches/2017-06/msg00289.html > > It contains the document part only. > It clarify the behavior when no modifier is used for register operand. > https://gcc.gn

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

2017-08-31 Thread Steve Ellcey
On Tue, 2017-08-29 at 12:25 +0100, Szabolcs Nagy wrote: >  > in glibc the hwcap is not used, because it has accesses to > cached dispatch info, but in libatomic using the hwcap > argument is the right way. Here is an updated version of the patch to allow aarch64 to use ifuncs in libatomic. The ma

Re: C++ PATCH to fix ICE with -Wbool-operation (PR c++/82040)

2017-08-31 Thread Jason Merrill
On Thu, Aug 31, 2017 at 8:17 AM, Marek Polacek wrote: > + && (complain & tf_error) This should be tf_warning. OK with that change. Jason

Re: [PATCH] Fix PR82054

2017-08-31 Thread Jason Merrill
OK. On Thu, Aug 31, 2017 at 6:15 AM, Richard Biener wrote: > > I am testing the following patch to fix another fallout of the > assert that we dont' add duplicated dwarf attributes. > > LTO bootstrapped / bootstrapped on x86_64-unknown-linux-gnu, testing > in progress. > > Richard. > > 2017-08-31

[PATCH, Makefile] improve default cpu selection for e500v2

2017-08-31 Thread Olivier Hainque
Hello, gcc can be configured with an "e500v2" cpu target name, conveying SPE with double precision floats. config.gcc already has a provision for a good default cpu selection for SPE with double precision floats when the latter is explicitly requested with an explicit --enable command line option

Re: [PATCH 4/7] [ARC] Use TARGET_USE_ANCHORS_FOR_SYMBOL_P.

2017-08-31 Thread Andrew Burgess
* Claudiu Zissulescu [2017-07-24 10:42:56 +0200]: > From: Claudiu Zissulescu > > We don't want to use anchors for small data: the GP register acts as an > anchor in that > case. We also don't want to use them for PC-relative accesses, > where the PC acts as an anchor. TLS symbols require sp

Re: [PATCH 5/7] [ARC] Update various patterns

2017-08-31 Thread Andrew Burgess
* Claudiu Zissulescu [2017-07-24 10:42:57 +0200]: > From: claziss > > gcc/ > 2017-04-25 Claudiu Zissulescu > > * config/arc/arc.md (movqi_insn): Add stores to save constant long > immediates. > (movhi_insn): Update store instruction constraint which are saving > 6-b

Re: [PATCH 7/7] [ARC] Fix errors in arc_ifcvt.

2017-08-31 Thread Andrew Burgess
* Claudiu Zissulescu [2017-07-24 10:42:59 +0200]: > From: claziss > > The arc_ifcvt procedure is removing a label even when it is used by > another jump. This patch fixes dg.exp/pr31507-1.c. > > gcc/ > 2017-07-10 Claudiu Zissulescu > > * config/arc/arc.c (arc_ifcvt): Remove use of

Re: [PATCH 6/7] [ARC] Reimplement ZOL support.

2017-08-31 Thread Andrew Burgess
* Claudiu Zissulescu [2017-07-24 10:42:58 +0200]: > From: claziss > > 2017-05-22 Claudiu Zissulescu > > * config/arc/arc-c.c (__ARC_LPC_WIDTH__): Add builtin define. > * config/arc/arc.c (ARC_MAX_LOOP_LENGTH): Define. > (arc_conditional_register_usage): Remove ARC600 lp_co

[PATCH, vxworks] simplify configuration selection for powerpc vxworks variants

2017-08-31 Thread Olivier Hainque
Hello, All the currently supported VxWorks variants for powerpc (regular, ae/653 and mils) are handled by common sections in config.gcc + libgcc/config.host, with case selectors like: powerpc-wrs-vxworks|powerpc-wrs-vxworksae|powerpc-wrs-vxworksmils) Two variants we now also support (spe and 7)

[RFC PATCH, i386]: Convert TLS location to DEFAULT_TLS_SEG_REG address space

2017-08-31 Thread Uros Bizjak
Hello! Using following testcase: --cut here-- __thread int a; int foo (void) { return a; } --cut here-- Attached patch converts TLS location in the form of: (mem/c:SI (plus:DI (unspec:DI [ (const_int 0 [0]) ] UNSPEC_TP) (con

Re: libgo patch committed: netinet/icmp6.h require netinet/in.h on AIX

2017-08-31 Thread Ian Lance Taylor
On Thu, Aug 31, 2017 at 1:09 AM, Rainer Orth wrote: > >> This patch from Tony Reix fixes the libgo configure script to >> correctly decide whether netinet/icmp6.h exists on AIX. Bootstrapped >> and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. > > unfortunately, this patch brok

Re: [PATCH v5] aarch64: Add split-stack initial support

2017-08-31 Thread Adhemerval Zanella
Ping. On 26/07/2017 16:08, Adhemerval Zanella wrote: > This is an update patch based on my previous submission [1]. The changes > from previous version are: > > - Update aarch64_supports_split_stack to return true an let the loader > to actually emit an error if it does not provide the req

Re: [PATCH] Fix bug in simplify_ternary_operation

2017-08-31 Thread Jeff Law
On 08/28/2017 12:26 PM, Tom de Vries wrote: > Hi, > > I think I found a bug in r17465: > ... >>* cse.c (simplify_ternary_operation): Handle more IF_THEN_ELSE >>simplifications. >> >> diff --git a/gcc/cse.c b/gcc/cse.c >> index e001597..3c27387 100644 >> --- a/gcc/cse.c >> +++ b/gcc

Ping on three small aarch64 patches

2017-08-31 Thread Steve Ellcey
This is a ping for several small aarch64 specific patches that have not been approved or commented on. Enable resolver attribute on aarch64. https://gcc.gnu.org/ml/gcc-patches/2017-06/msg00806.html Improve cost of shift/extend instructions on ThunderX2T99. https://gcc.gnu.org/ml/gcc-patches/2017

Re: [PATCH][compare-elim] Merge zero-comparisons with normal ops

2017-08-31 Thread Jeff Law
On 08/29/2017 02:39 AM, Kyrill Tkachov wrote: >>> This scares combine away as x0 is used in insn 33 as well as the >>> comparison in insn 34. >>> I think the compare-elim pass can help us here. >> Is it the multiple use or the hard register that combine doesn't >> appreciate. The latter would def

Re: [PING][PATCH 2/3] retire mem_signal_fence pattern

2017-08-31 Thread Jeff Law
On 08/28/2017 06:05 AM, Alexander Monakov wrote: > Ping (for this and patch 3/3 in the thread). > > On Wed, 2 Aug 2017, Alexander Monakov wrote: > >> Similar to mem_thread_fence issue from the patch 1/3, RTL representation of >> __atomic_signal_fence must be a compiler barrier. We have just one

Re: [PING #2] [PATCH] enhance -Wrestrict to handle string built-ins (PR 78918)

2017-08-31 Thread Jeff Law
On 08/28/2017 06:20 PM, Martin Sebor wrote: >> >> Warning for memcpy (p, p, ...) is going to fire false positives all >> around >> given the C++ FE emits those in some cases and optimization can >> expose that we are dealing with self-assignments. And *p = *p is >> valid. > > I changed it to only

Re: Statement Frontier Notes, Location Views, and Inlined Entry Point Markers

2017-08-31 Thread Alexandre Oliva
On Aug 23, 2017, Richard Biener wrote: > Just separating the boilerplate changes out from the "meat" of the change > into a separate patch for easier reviewing would be nice. I've broken up the patch into a patchset with 10 patches. I've already posted the one that makes -g options negatable th

[PATCH 1/9] [SFN] adjust RTL insn-walking API

2017-08-31 Thread Alexandre Oliva
This patch removes unused RTL functions, introduces alternate ones for use in a later SFN patch, and regroups other related functions so that they appear in a more consistent order. for gcc/ChangeLog * emit-rtl.c (next_nondebug_insn, prev_nondebug_insn): Reorder. (next_nonnote_no

[PATCH 5/9] [SFN] Introduce -gstatement-frontiers option, enable debug markers

2017-08-31 Thread Alexandre Oliva
Introduce a command line option to enable statement frontiers, enabled by default in optimized builds with DWARF2+ debug information. This patch depends on an earlier patch that completed the infrastructure for debug markers, and on another patch that turns -g into a negatable option prefix. gcc/

[PATCH 8/9] [IEPM] Introduce debug hook for inline entry point markers

2017-08-31 Thread Alexandre Oliva
The inline_entry hook will be given a definition in a later patch. for gcc/ChangeLog * debug.h (gcc_debug_hooks): Add inline_entry. * dbxout.c (dbx_debug_hooks, xcoff_debug_hooks): Likewise. * debug.c (do_nothing_debug_hooks): Likewise. * sdbout.c (sdb_debug_hooks

[PATCH 2/9] [SFN] boilerplate changes in preparation to introduce nonbind markers

2017-08-31 Thread Alexandre Oliva
This patch introduces a number of new macros and functions that will be used to distinguish between different kinds of debug stmts, insns and notes, namely, preexisting debug bind ones and to-be-introduced nonbind markers. In a seemingly mechanical way, it adjusts several uses of the macros and fu

[PATCH 6/9] [LVU] Allow final_start_function to skip initial insns

2017-08-31 Thread Alexandre Oliva
This API change will enable final_start_function() to "consume" initial insns, and choose the first insn to be passed to final(). Many ports call final_start_function() and final() when creating thunks and whatnot, so they needed adjusting. for gcc/ChangeLog * output.h (final_start_func

[PATCH 3/9] [SFN] not-quite-boilerplate changes in preparation to introduce nonbind markers

2017-08-31 Thread Alexandre Oliva
This patch adjusts numerous parts of the compiler that would malfunction should they find debug markers at points where they may be introduced. The changes purport to allow the compiler to pass bootstrap-debug-lean (-fcompare-debug in stage3) at various optimization levels, as well as bootstrap-de

[PATCH 4/9] [SFN] introduce statement frontier notes, still disabled

2017-08-31 Thread Alexandre Oliva
This patch completes the infrastructure for the introduction of statement frontiers in C-family languages. It brings in all the code remaining code needed to introduce and transform begin stmt trees, gimple stmts, insns and notes, and ultimately use them to generate the is_stmt column in DWARF2+ l

[PATCH 9/9] [IEPM] Introduce inline entry point markers

2017-08-31 Thread Alexandre Oliva
Output DW_AT_entry_pc based on markers. Introduce DW_AT_GNU_entry_view as a DWARF extension. If views are enabled are we're not in strict compliance mode, output DW_AT_GNU_entry_view if it might be nonzero. This patch depends on SFN and LVU patchsets, and on the IEPM patch that introduces the in

[PATCH 7/9] [LVU] Introduce location views

2017-08-31 Thread Alexandre Oliva
This patch introduces an option to enable the generation of location views along with location lists. The exact format depends on the DWARF version: it can be a separate attribute (DW_AT_GNU_locviews) or (DW_LLE_view_pair) entries in DWARF5+ loclists. Line number tables are also affected. If the

[PATCH] combine: Fix for PR82024

2017-08-31 Thread Segher Boessenkool
With the testcase in the PR, with all the command line options mentioned there, a (comparison) instruction becomes dead in fwprop1 but is not deleted until all the way in rtl_dce. Before combine this insn look like: 20: flags:CC=cmp(r106:DI,0x) REG_DEAD r106:DI REG_UNU

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

2017-08-31 Thread Prathamesh Kulkarni
On 26 August 2017 at 04:15, Joseph Myers wrote: > On Tue, 11 Jul 2017, 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 believe the

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

2017-08-31 Thread Prathamesh Kulkarni
On 17 August 2017 at 18:02, Prathamesh Kulkarni wrote: > On 8 August 2017 at 09:50, Prathamesh Kulkarni > wrote: >> 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: >> >>

Re: [PING][PATCH 2/3] retire mem_signal_fence pattern

2017-08-31 Thread Alexander Monakov
On Thu, 31 Aug 2017, Jeff Law wrote: > This is OK. > > What's the point of the delete_insns_since calls in patch #3? Deleting the first barrier when maybe_expand_insn failed. Other functions in the file use a similar approach. Thanks. Alexander