RE: [patch mips/gcc] add build-time and runtime options to disable or set madd.fmt type

2017-01-11 Thread Matthew Fortune
Sandra Loosemore writes: > On 01/10/2017 07:24 AM, Yunqiang Su wrote: > > Hi, folks, any idea about this patch? > > I can only comment on the documentation parts. I am reviewing the patch but need to determine if the changes are sufficient and safe to meet the goal. This area is complex in the M

Re: [PATCH] adding missing LTO to some warning options (PR 78606)

2017-01-11 Thread Richard Biener
On Tue, 10 Jan 2017, Martin Sebor wrote: > The -Walloca-larger-than, -Wformat-length, and -Wformat-truncation > options do not mention LTO among the supported languages and so are > disabled when -flto is used, causing false negatives. > > The attached patch adds the missing LTO to the three opti

Re: [PATCH v2] Offer suggestions for unrecognized sanitizer options (PR driver/78877)

2017-01-11 Thread Jakub Jelinek
On Tue, Jan 10, 2017 at 08:47:26PM -0500, David Malcolm wrote: > + /* For -fsanitize-recover= (and not -fno-sanitize-recover=), > + don't offer the non-recoverable options. */ > + if (!sanitizer_opts[i].can_recover && code == OPT_fsanitize_recover_ > + && value) If a conditio

Re: [PATCH] Optimize n + 1 for automatic n array (PR c++/71537)

2017-01-11 Thread Richard Biener
On Tue, 10 Jan 2017, Jakub Jelinek wrote: > Hi! > > This patch allows to fold n + 1 != 0 into true for automatic array n. > We already handle it for variables in the symbol table (if not weak), > but automatic vars are never in the symbol table. > > Bootstrapped/regtested on x86_64-linux and i68

Re: [PATCH] DOn't miscompile programs with -flto -fno-merge-constants (PR middle-end/50199)

2017-01-11 Thread Richard Biener
On Tue, 10 Jan 2017, Jakub Jelinek wrote: > Hi! > > LTO partitioning can actually take appart uses of STRING_CSTs or other > constants and put those into multiple partitions. When -fno-merge-constants > is in effect, it means those constants aren't merged by the linker and > e.g. following testc

Re: [PATCH] Optimize n + 1 for automatic n array (PR c++/71537)

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 09:31:38AM +0100, Richard Biener wrote: > > Or shall I add the function local address check into maybe_nonzero_address > > instead (return 1 for those)? > > Yes please, and cleanup the other user of maybe_nonzero_address then > (which contains the code you added). Ok, I'll

[PATCH][PR lto/79042] Propagate node->dynamically_initialized bit for varpool node to LTRANS stage.

2017-01-11 Thread Maxim Ostapenko
Hi, as mentioned in PR, LTO doesn't propagate node->dynamically_initialized bit for varpool nodes that leads to ASan fails to detect initialization order fiasco even for trivial example (e.g. from here: https://github.com/google/sanitizers/wiki/AddressSanitizerExampleInitOrderFiasco). This tri

Re: [PATCH] Optimize n + 1 for automatic n array (PR c++/71537)

2017-01-11 Thread Richard Biener
On Wed, 11 Jan 2017, Jakub Jelinek wrote: > On Wed, Jan 11, 2017 at 09:31:38AM +0100, Richard Biener wrote: > > > Or shall I add the function local address check into maybe_nonzero_address > > > instead (return 1 for those)? > > > > Yes please, and cleanup the other user of maybe_nonzero_address

[PATCH] Fix EVRP not setting ranges on PHI reults

2017-01-11 Thread Richard Biener
This fixes EVRP to also set range-info/nonnull for PHI results as well as not doing useless work in setting such info for SSA defs we'll propagate out later. Bootstrapped and tested on x86_64-unknown-linux-gnu, installed. Richard. 2017-01-11 Richard Biener * tree-vrp.c (evrp_dom_wa

Re: [PATCH] avoid infinite recursion in maybe_warn_alloc_args_overflow (pr 78775)

2017-01-11 Thread Christophe Lyon
Hi Martin, On 9 January 2017 at 04:14, Jeff Law wrote: > On 01/08/2017 02:04 PM, Martin Sebor wrote: >> >> On 01/06/2017 09:45 AM, Jeff Law wrote: >>> >>> On 01/05/2017 08:52 PM, Martin Sebor wrote: >>> >>> So Richi asked for removal of the VR_ANTI_RANGE handling, which would >>> impl

Re: [Aarch64][PATCH] Fix gcc.dg/zero_bits_compound-2.c for aarch64

2017-01-11 Thread Kyrill Tkachov
On 06/12/16 00:46, Michael Collison wrote: This patches fixes a regression in gcc.dg/zero_bits_compound-2.c. A recent patch (https://gcc.gnu.org/ml/gcc-patches/2016-11/msg02392.html) to the aarch64 backend improved generation for 'and' instructions with constants. The patch changed the number

Re: [Aarch64][PATCH] Fix gcc.dg/zero_bits_compound-2.c for aarch64

2017-01-11 Thread James Greenhalgh
On Wed, Jan 11, 2017 at 09:41:42AM +, Kyrill Tkachov wrote: > > On 06/12/16 00:46, Michael Collison wrote: > >This patches fixes a regression in gcc.dg/zero_bits_compound-2.c. A recent > >patch (https://gcc.gnu.org/ml/gcc-patches/2016-11/msg02392.html) > >to the aarch64 backend improved gener

Re: [ARM] PR 78253 do not resolve weak ref locally

2017-01-11 Thread Christophe Lyon
Ping? On 3 January 2017 at 16:45, Christophe Lyon wrote: > Ping? > > The patch is at https://gcc.gnu.org/ml/gcc-patches/2016-12/msg00078.html > > > On 14 December 2016 at 16:29, Christophe Lyon > wrote: >> Ping^2 ? >> >> As a reminder, this patch mimics what aarch64 does wrt to references to wea

Re: [Patch][ARM,AArch64] more poly64 intrinsics and tests

2017-01-11 Thread Christophe Lyon
Ping? James, I'm not sure whether your comment was a request for a new version of my patch or just FYI? On 3 January 2017 at 16:47, Christophe Lyon wrote: > Ping? > > > On 14 December 2016 at 23:09, Christophe Lyon > wrote: >> On 14 December 2016 at 17:55, James Greenhalgh >> wrote: >>> On M

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Christophe Lyon
Hi Martin, On 10 January 2017 at 15:40, Martin Liška wrote: > On 01/10/2017 02:56 PM, Richard Biener wrote: >> >> On Mon, Jan 9, 2017 at 4:05 PM, Martin Liška wrote: >>> >>> Second part of the patch does sorting of final congruence classes, it's >>> groups >>> and items included in the groups ac

Re: [hsa] Exclude parallel outlines from hsa_callable_functions_p

2017-01-11 Thread Martin Jambor
Hi, On Fri, Dec 02, 2016 at 02:55:46PM +0100, Martin Jambor wrote: > Hi, > > after the merge of nvidia OpenMP implementation, the normal parallel > outline functions were also marked as "omp declare target" which lead > to them being cloned and compiled to HSA which is not only unnecessary > but

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 11:21:08AM +0100, Christophe Lyon wrote: > Since then, I've noticed that > gcc.dg/tree-ssa/flatten-3.c scan-assembler cycle[123][: \t\n] > now fails on aarch64 and arm targets. It fails on x86_64-linux and i686-linux too. Jakub

Re: [v3 PATCH] Reduce the size of variant, it doesn't need an index of type size_t internally.

2017-01-11 Thread Jonathan Wakely
On 11/01/17 00:19 +0200, Ville Voutilainen wrote: @@ -1086,7 +1099,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION { return !this->_M_valid(); } constexpr size_t index() const noexcept - { return this->_M_index; } + { + if (this->_M_index == + typename _Base::_Storag

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Martin Liška
On 01/11/2017 11:28 AM, Jakub Jelinek wrote: > On Wed, Jan 11, 2017 at 11:21:08AM +0100, Christophe Lyon wrote: >> Since then, I've noticed that >> gcc.dg/tree-ssa/flatten-3.c scan-assembler cycle[123][: \t\n] >> now fails on aarch64 and arm targets. > > It fails on x86_64-linux and i686-linux t

RE: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Koval, Julia
Ok. I fixed the enum formatting and the enums remain internal. -Julia -Original Message- From: Andrew Senkevich [mailto:andrew.n.senkev...@gmail.com] Sent: Tuesday, January 10, 2017 5:48 PM To: Uros Bizjak Cc: Koval, Julia ; GCC Patches ; vaalfr...@gmail.com Subject: Re: [PATCH] Enable

Re: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 10:31:33AM +, Koval, Julia wrote: > Ok. I fixed the enum formatting and the enums remain internal. No further objections from me, if Uros acks it, check it in. > > Sure. Plus it depends on if users of the APIs should just write the > > operands on their own as number

Re: [v3 PATCH] Reduce the size of variant, it doesn't need an index of type size_t internally.

2017-01-11 Thread Jonathan Wakely
On 11/01/17 10:29 +, Jonathan Wakely wrote: On 11/01/17 00:19 +0200, Ville Voutilainen wrote: @@ -1086,7 +1099,12 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION { return !this->_M_valid(); } constexpr size_t index() const noexcept - { return this->_M_index; } + { + if (this->

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Martin Liška
On 01/11/2017 11:28 AM, Jakub Jelinek wrote: > On Wed, Jan 11, 2017 at 11:21:08AM +0100, Christophe Lyon wrote: >> Since then, I've noticed that >> gcc.dg/tree-ssa/flatten-3.c scan-assembler cycle[123][: \t\n] >> now fails on aarch64 and arm targets. > > It fails on x86_64-linux and i686-linux t

Re: [PATCH][PR tree-optimization/78856] Invalidate cached iteration information when threading across multiple loop headers

2017-01-11 Thread Richard Biener
On Tue, Jan 10, 2017 at 8:16 PM, Jeff Law wrote: > On 01/04/2017 05:25 AM, Richard Biener wrote: >> >> On Wed, Jan 4, 2017 at 6:31 AM, Jeff Law wrote: >>> >>> >>> So as noted in the BZ comments the jump threading code has code that >>> detects >>> when a jump threading path wants to cross multipl

Re: [LRA] Fix PR rtl-optimization/79032

2017-01-11 Thread Richard Biener
On Tue, Jan 10, 2017 at 9:31 PM, Eric Botcazou wrote: > Hi, > > LRA generates an unaligned memory access for 32-bit SPARC on the attached > testcase when it is compiled with optimization. It's again the business of > paradoxical subregs of memory dealt with by simplify_operand_subreg: > >

Re: [PATCH] avoid infinite recursion in maybe_warn_alloc_args_overflow (pr 78775)

2017-01-11 Thread Andreas Schwab
On Jan 11 2017, Christophe Lyon wrote: > The new test (gcc.dg/pr78973.c) fails on arm targets (there's no warning). Also fails on m68k. > In addition, I have noticed a new failure: > gcc.dg/attr-alloc_size-4.c (test for warnings, line 140) > on target arm-none-linux-gnueabihf --with-cpu=cort

Re: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Uros Bizjak
On Wed, Jan 11, 2017 at 11:31 AM, Koval, Julia wrote: > Ok. I fixed the enum formatting and the enums remain internal. @@ -7023,7 +7029,6 @@ ix86_can_inline_p (tree caller, tree callee) bool ret = false; tree caller_tree = DECL_FUNCTION_SPECIFIC_TARGET (caller); tree callee_tree = DECL_F

Re: [PATCH][PR lto/79042] Propagate node->dynamically_initialized bit for varpool node to LTRANS stage.

2017-01-11 Thread Richard Biener
On Wed, Jan 11, 2017 at 10:00 AM, Maxim Ostapenko wrote: > Hi, > > as mentioned in PR, LTO doesn't propagate node->dynamically_initialized bit > for varpool nodes that leads to ASan fails to detect initialization order > fiasco even for trivial example (e.g. from here: > https://github.com/google/

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Richard Biener
On Wed, Jan 11, 2017 at 11:48 AM, Martin Liška wrote: > On 01/11/2017 11:28 AM, Jakub Jelinek wrote: >> On Wed, Jan 11, 2017 at 11:21:08AM +0100, Christophe Lyon wrote: >>> Since then, I've noticed that >>> gcc.dg/tree-ssa/flatten-3.c scan-assembler cycle[123][: \t\n] >>> now fails on aarch64 an

Re: [PATCH][PR lto/79042] Propagate node->dynamically_initialized bit for varpool node to LTRANS stage.

2017-01-11 Thread Maxim Ostapenko
On 11/01/17 14:17, Richard Biener wrote: On Wed, Jan 11, 2017 at 10:00 AM, Maxim Ostapenko wrote: Hi, as mentioned in PR, LTO doesn't propagate node->dynamically_initialized bit for varpool nodes that leads to ASan fails to detect initialization order fiasco even for trivial example (e.g. from

[PATCH] Fix parts of PR79052 (gimplefe)

2017-01-11 Thread Richard Biener
The following hopefully fixes the gimplefe ubsan bootstrap warnings. Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. Richard. 2017-01-11 Richard Biener PR bootstrap/79052 * gimple-parser.c (c_parser_gimple_switch_stmt): Add missing returns on parse errors

Re: [PATCH][PR lto/79042] Propagate node->dynamically_initialized bit for varpool node to LTRANS stage.

2017-01-11 Thread Richard Biener
On Wed, Jan 11, 2017 at 12:21 PM, Maxim Ostapenko wrote: > On 11/01/17 14:17, Richard Biener wrote: >> >> On Wed, Jan 11, 2017 at 10:00 AM, Maxim Ostapenko >> wrote: >>> >>> Hi, >>> >>> as mentioned in PR, LTO doesn't propagate node->dynamically_initialized >>> bit >>> for varpool nodes that lead

Re: C++ PATCH for C++17 NB comment FI20 (parenthesized initialization with decomposition)

2017-01-11 Thread Jakub Jelinek
On Tue, Jan 10, 2017 at 02:03:14PM -0500, Jason Merrill wrote: > The FI20 comment on the decomposition declarations proposal complained > that the syntax unnecessarily excluded parenthesized initialization. > This patch implements the resolution. > > Tested x86_64-pc-linux-gnu, applying to trunk.

RE: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Koval, Julia
Ok, fixed it. Can you please commit it for me, cause I don't have rights to commit? Thanks, Julia -Original Message- From: Uros Bizjak [mailto:ubiz...@gmail.com] Sent: Wednesday, January 11, 2017 12:11 PM To: Koval, Julia Cc: Andrew Senkevich ; GCC Patches ; vaalfr...@gmail.com; kiril

[committed] Small tweak for the decomp4.C testcase

2017-01-11 Thread Jakub Jelinek
Hi! When compiling this testcase with trunk clang++, I've noticed the error is different, because there are in fact 2 errors, one that a struct has 2 non-static data members and the decomposition just one identifier, the other that one of those non-static data members is private. I've committed a

[PATCH C++] Fix PR77489 -- mangling of discriminator >= 10

2017-01-11 Thread Markus Trippelsdorf
Currently gcc mangles symbols wrongly when the discriminator is greater than ten. The fix is straightforward. The demangler now handles both the old and the new correct mangling. Tested on ppc64le. OK for trunk? Thanks. libiberty: PR c++/77489 * cp-demangle.c (d_discriminator):

Re: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Uros Bizjak
On Wed, Jan 11, 2017 at 12:40 PM, Koval, Julia wrote: > Ok, fixed it. Can you please commit it for me, cause I don't have rights to > commit? OK, but please send me updated ChangeLogs. Uros. > Thanks, > Julia > > -Original Message- > From: Uros Bizjak [mailto:ubiz...@gmail.com] > Sent:

Re: [PATCH C++] Fix PR77489 -- mangling of discriminator >= 10

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 12:48:29PM +0100, Markus Trippelsdorf wrote: > @@ -1965,7 +1966,11 @@ write_discriminator (const int discriminator) >if (discriminator > 0) > { >write_char ('_'); > + if (abi_version_at_least(11) && discriminator - 1 >= 10) > + write_char ('_'); >

RE: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Koval, Julia
Here is it. gcc/ * common/config/i386/i386-common.c (OPTION_MASK_ISA_SGX_UNSET, OPTION_MASK_ISA_SGX_SET): New. (ix86_handle_option): Handle OPT_msgx. * config.gcc: Added sgxintrin.h. * config/i386/cpuid.h (bit_SGX): New. * config/i386/driver-i386.c (host_detect_local_

Re: [PATCH] PR77528 add default constructors for container adaptors

2017-01-11 Thread Jonathan Wakely
On 10/01/17 13:15 -0500, Tim Song wrote: On Tue, Jan 10, 2017 at 12:33 PM, Jonathan Wakely wrote: The standard says that the container adaptors have a constructor with a default argument, which serves as a default constructor. That involves default-constructing the underlying sequence as the de

Re: [PATCH] PR77528 add default constructors for container adaptors

2017-01-11 Thread Tim Song
On Wed, Jan 11, 2017 at 7:21 AM, Jonathan Wakely wrote: > This patch uses the _Enable_default_constructor mixin to properly > delete the default constructors. It's a bit cumbersome, because we > have to add an initializer for the base class to every > ctor-initializer-list, but I think I prefer th

[PATCH] TS_OPTIMIZATION/TS_TARGET_OPTION need no chain/type

2017-01-11 Thread Richard Biener
LTO bootstrapped on x86_64-unknown-linux-gnu, testing in progress. (most "gross" are still TS_LIST having a type and TS_VEC having type and chain, but that's been hard to fix with the C++ FE in place) Richard. 2017-01-11 Richard Biener * tree.c (initialize_tree_contains_struct): Mak

[PATCH C++] Fix PR70182 -- missing "on" in mangling of unresolved operators

2017-01-11 Thread Markus Trippelsdorf
The ABI says: ::= [gs] ::= sr ::= srN + E ::= [gs] sr + E ::= ::= on ::= on ::= dn int f (); diff --git a/gcc/testsuite/g++.dg/abi/mangle37.C b/gcc/testsuite/g++.dg/abi/mangle37.C index 691566b384ba..4dd87e84c108 100644 --- a/gcc/testsuite/g++.dg/abi/mangle3

Re: [PATCH C++] Fix PR70182 -- missing "on" in mangling of unresolved operators

2017-01-11 Thread Nathan Sidwell
On 01/11/2017 08:16 AM, Markus Trippelsdorf wrote: --- a/gcc/cp/mangle.c +++ b/gcc/cp/mangle.c @@ -2813,6 +2813,8 @@ write_template_args (tree args) static void write_member_name (tree member) { + if (abi_version_at_least (11) && IDENTIFIER_OPNAME_P (member)) +write_string ("on"); It l

Re: [PATCH] PR77528 add default constructors for container adaptors

2017-01-11 Thread Jonathan Wakely
On 11/01/17 08:04 -0500, Tim Song wrote: On Wed, Jan 11, 2017 at 7:21 AM, Jonathan Wakely wrote: This patch uses the _Enable_default_constructor mixin to properly delete the default constructors. It's a bit cumbersome, because we have to add an initializer for the base class to every ctor-initi

Re: [PATCH] PR77528 add default constructors for container adaptors

2017-01-11 Thread Jonathan Wakely
On 11/01/17 13:25 +, Jonathan Wakely wrote: On 11/01/17 08:04 -0500, Tim Song wrote: On Wed, Jan 11, 2017 at 7:21 AM, Jonathan Wakely wrote: This patch uses the _Enable_default_constructor mixin to properly delete the default constructors. It's a bit cumbersome, because we have to add an i

Re: [PATCH] PR77528 add default constructors for container adaptors

2017-01-11 Thread Tim Song
On Wed, Jan 11, 2017 at 8:30 AM, Jonathan Wakely wrote: >>> Re the new DMI, my brain compiler says that _Sequence c = _Sequence(); >>> breaks anything with an explicit copy/move constructor pre-C++17, but >>> I also don't think we care about those, right? >> >> >> I dislike them, > > > I meant to

Re: [patch,avr] PR78883: Implement a dummy scheduler

2017-01-11 Thread Georg-Johann Lay
On 04.01.2017 20:29, Jeff Law wrote: On 01/04/2017 12:18 PM, Segher Boessenkool wrote: On Wed, Jan 04, 2017 at 06:42:23PM +, Richard Sandiford wrote: 1. reload has a bug that no-one really wants to fix (understandable) 2. the bug is triggered by paradoxical subregs of mems 3. those subregs

[arm] Replace command-line option .def files with single definition file

2017-01-11 Thread Richard Earnshaw (lists)
The files arm-cores.def, arm-fpus.def and arm-arches.def are parsed and used in several places and the format is slightly awkward to maintain as they must be parsable in C and by certain scripts. Furthermore, changes to the content that affects every entry is particularly awkward for dealing with

[PATCH] PR78273 fix count to work with partitioning function

2017-01-11 Thread Jonathan Wakely
I thought it would be an optimization to use _M_find_tr(k) != end() for the unique associative containers, but as the PR points out the heterogeneous version of count() can find multiple matches even in a unique container. We need to use _M_count_tr(k) to find all matches. PR libstdc++/7

[PATCH] PR78134 fix return types of heterogeneous lookup functions

2017-01-11 Thread Jonathan Wakely
As with PR 68190 I was returning the _Rb_tree iterator types, not converting them to the container's iterator types. PR libstdc++/78134 * include/bits/stl_map.h (map::lower_bound, map::upper_bound) (map::equal_range): Fix return type of heterogeneous overloads. * i

Re: [PATCH] PR78255: Make postreload aware of NO_FUNCTION_CSE

2017-01-11 Thread Andre Vieira (lists)
On 06/01/17 15:47, Jeff Law wrote: > On 01/06/2017 03:53 AM, Andre Vieira (lists) wrote: >> On 09/12/16 16:31, Bernd Schmidt wrote: >>> On 12/09/2016 05:16 PM, Andre Vieira (lists) wrote: >>> Regardless, 'reload_cse_simplify' would never perform the opposite transformation. It checks whe

Re: [PATCH] TS_OPTIMIZATION/TS_TARGET_OPTION need no chain/type

2017-01-11 Thread Richard Biener
On Wed, 11 Jan 2017, Richard Biener wrote: > > LTO bootstrapped on x86_64-unknown-linux-gnu, testing in progress. > > (most "gross" are still TS_LIST having a type and TS_VEC having type > and chain, but that's been hard to fix with the C++ FE in place) Forgot the tree-core.h part. Re-bootstra

[PATCH][GIMPLE FE] Add parsing of MEM_REFs

2017-01-11 Thread Richard Biener
The following fills the gap of missed handling of MEM_REF parsing. As we want to represent all info that is on a MEM_REF the existing dumping isn't sufficent so I resorted to __MEM '<' type-name [ ',' number ] '>' '(' [ '(' type-name ')' ] unary-expression [ '+' number ] ')' *

Re: [PATCH] avoid infinite recursion in maybe_warn_alloc_args_overflow (pr 78775)

2017-01-11 Thread Martin Sebor
On 01/11/2017 02:05 AM, Christophe Lyon wrote: Hi Martin, On 9 January 2017 at 04:14, Jeff Law wrote: On 01/08/2017 02:04 PM, Martin Sebor wrote: On 01/06/2017 09:45 AM, Jeff Law wrote: On 01/05/2017 08:52 PM, Martin Sebor wrote: So Richi asked for removal of the VR_ANTI_RANGE handling,

Re: Use a specfile that actually allows building programs on NetBSD

2017-01-11 Thread Krister Walfridsson
On Mon, 9 Jan 2017, co...@sdf.org wrote: 3 month ping, 1 week ping (trying again), etc... Apologies for not getting back to you sooner. Like most operating systems, NetBSD has a libc which contains stuff it needs for most programs to work, and people expect it to be linked without explicitl

Re: [ARM] PR 78253 do not resolve weak ref locally

2017-01-11 Thread Richard Earnshaw (lists)
On 01/12/16 14:27, Christophe Lyon wrote: > Hi, > > > On 10 November 2016 at 15:10, Christophe Lyon > wrote: >> On 10 November 2016 at 11:05, Richard Earnshaw >> wrote: >>> On 09/11/16 21:29, Christophe Lyon wrote: Hi, PR 78253 shows that the handling of weak references has chang

Re: [PATCH] c++/78771 ICE with inheriting ctor

2017-01-11 Thread Nathan Sidwell
On 01/04/2017 12:53 AM, Jason Merrill wrote: Hmm, that seems like where the problem is. We shouldn't try to instantiate the inheriting constructor until we've already chosen the base constructor; in the new model the inheriting constructor is just an implementation detail. Oh what fun. This

Re: [PATCH][AArch64] Improve Cortex-A53 scheduling of int/fp transfers

2017-01-11 Thread Richard Earnshaw (lists)
On 10/01/17 17:18, Wilco Dijkstra wrote: > My previous change to the Cortex-A53 scheduler resulted in a 13% regression > on a > proprietary benchmark. This turned out to be due to non-optimal scheduling > of int > to float conversions. This patch separates int to FP transfers from int to > flo

Re: [patch,avr] PR78883: Implement a dummy scheduler

2017-01-11 Thread Segher Boessenkool
On Wed, Jan 04, 2017 at 12:29:49PM -0700, Jeff Law wrote: > >We should split off a new "SUBREGS_OF_MEM_ALLOWED" from !INSN_SCHEDULING, > >and then probably even default it to false. > That would work for me :-) The question in my mind would be unexpected > fallout at this point in the release pro

Re: [PATCH][ARM] [gcc] Add __artificial__ attribute to all NEON intrinsics

2017-01-11 Thread Richard Earnshaw (lists)
On 10/01/17 10:40, Tamar Christina wrote: > Hi all, > > This patch adds the __artificial__ and __gnu_inline__ > attributes to the intrinsics in arm_neon.h so that > costs are associated to the user function during profiling > and during debugging the intrinsics are hidden in trace. > > A similar

Re: [ARM] PR 78253 do not resolve weak ref locally

2017-01-11 Thread Christophe Lyon
On 11 January 2017 at 16:48, Richard Earnshaw (lists) wrote: > On 01/12/16 14:27, Christophe Lyon wrote: >> Hi, >> >> >> On 10 November 2016 at 15:10, Christophe Lyon >> wrote: >>> On 10 November 2016 at 11:05, Richard Earnshaw >>> wrote: On 09/11/16 21:29, Christophe Lyon wrote: > Hi,

Re: [ARM] PR 78253 do not resolve weak ref locally

2017-01-11 Thread Christophe Lyon
On 11 January 2017 at 17:13, Christophe Lyon wrote: > On 11 January 2017 at 16:48, Richard Earnshaw (lists) > wrote: >> On 01/12/16 14:27, Christophe Lyon wrote: >>> Hi, >>> >>> >>> On 10 November 2016 at 15:10, Christophe Lyon >>> wrote: On 10 November 2016 at 11:05, Richard Earnshaw

Re: [ARM] PR 78253 do not resolve weak ref locally

2017-01-11 Thread Richard Earnshaw (lists)
On 11/01/17 16:14, Christophe Lyon wrote: > On 11 January 2017 at 17:13, Christophe Lyon > wrote: >> On 11 January 2017 at 16:48, Richard Earnshaw (lists) >> wrote: >>> On 01/12/16 14:27, Christophe Lyon wrote: Hi, On 10 November 2016 at 15:10, Christophe Lyon wrote: >>

Re: [PATCH, gcc, wwwdocs] Document upcoming Qualcomm Falkor processor support

2017-01-11 Thread Richard Earnshaw (lists)
On 06/01/17 12:11, Siddhesh Poyarekar wrote: > Hi, > > This patch documents the newly added flag in gcc 7 for the upcoming > Qualcomm Falkor processor core. > > Siddhesh > > Index: htdocs/gcc-7/changes.html > === > RCS file: /cvs/gc

[PATCH][AArch64][GCC 6] PR target/79041: Correct -mpc-relative-literal-loads logic in aarch64_classify_symbol

2017-01-11 Thread Kyrill Tkachov
Hi all, In this PR we generated ADRP/ADD instructions with :lo12: relocations on symbols even though -mpc-relative-literal-loads is used. This is due to the confusing double-negative logic of the nopcrelative_literal_loads aarch64 variable and its relation to the aarch64_nopcrelative_literal_lo

Re: [PATCH] Remove padding from DWARF5 headers

2017-01-11 Thread Jason Merrill
OK. On Tue, Jan 3, 2017 at 6:09 PM, Jakub Jelinek wrote: > Hi! > > http://dwarfstd.org/ShowIssue.php?issue=161031.2 > got approved today, so DWARF5 is changing and the various DW_UT_* kinds > will no longer have the same size of the headers. So, > DW_UT_compile/DW_UT_partial shrinks by 12/16 byt

Re: Use a specfile that actually allows building programs on NetBSD

2017-01-11 Thread coypu
On Wed, Jan 11, 2017 at 04:41:44PM +0100, Krister Walfridsson wrote: > On Mon, 9 Jan 2017, co...@sdf.org wrote: > > >3 month ping, 1 week ping (trying again), etc... > > Apologies for not getting back to you sooner. > > > >Like most operating systems, NetBSD has a libc which contains > >stuff i

Re: [PATCH, ARM] Further improve stack usage on sha512 (PR 77308)

2017-01-11 Thread Richard Earnshaw (lists)
On 08/12/16 19:50, Bernd Edlinger wrote: > Hi Wilco, > > On 11/30/16 18:01, Bernd Edlinger wrote: >> I attached the completely untested follow-up patch now, but I would >> like to post that one again for review, after I applied my current >> patch, which is still waiting for final review (please f

Re: [PATCH] [PR rtl-optimization/65618] Fix MIPS ADA bootstrap failure

2017-01-11 Thread Maciej W. Rozycki
On Mon, 19 Dec 2016, James Cowgill wrote: > This bug causes the ADA bootstrap comparison failure in a-except.o > because the branch delay scheduling operates slightly differently for > that file if debug information is turned on. This looks like a bug to me -- actual code produced is supposed to

Re: [PATCH] [PR rtl-optimization/65618] Fix MIPS ADA bootstrap failure

2017-01-11 Thread James Cowgill
Hi, On 11/01/17 16:49, Maciej W. Rozycki wrote: > On Mon, 19 Dec 2016, James Cowgill wrote: >> This bug causes the ADA bootstrap comparison failure in a-except.o >> because the branch delay scheduling operates slightly differently for >> that file if debug information is turned on. > > This look

Re: [PATCH, ARM] Further improve stack usage on sha512 (PR 77308)

2017-01-11 Thread Bernd Edlinger
On 01/11/17 17:55, Richard Earnshaw (lists) wrote: > > Sorry for the delay getting around to this. > > I just tried this patch and found that it doesn't apply. Furthermore, > there's not enough context in the rejected hunks for me to be certain > which patterns you're trying to fix up. > > Could y

Re: [PATCH] [PR rtl-optimization/65618] Fix MIPS ADA bootstrap failure

2017-01-11 Thread Maciej W. Rozycki
On Wed, 11 Jan 2017, James Cowgill wrote: > > From this consideration I gather you have a program source which can be > > used as a test case to reproduce the issue, so can you please file a > > problem report and include the source and a recipe to reproduce it? Is > > this a GCC issue with g

[PATCH, bugfix] builtin expansion of strcmp for rs6000

2017-01-11 Thread Aaron Sawdey
This expands on the previous patch. For strcmp and for strncmp with N larger than 64, the first 64 bytes of comparison is expanded inline and then a call to strcmp or strncmp is emitted to compare the remainder if the strings are found to be equal at that point.  -mstring-compare-inline-limit=N de

Re: [Patch ,gcc/MIPS] add an build-time/runtime option to disable madd.fmt

2017-01-11 Thread Maciej W. Rozycki
On Fri, 23 Dec 2016, Yunqiang Su wrote: > > 3, kernel: the emulation when a float exception taken. > > The big problem is that Loongson use the same encode for (unfused) > madd.fmt to (fused) madd.fmt. We cannot trap this in kernel. Why is that a problem? Just add a setting like `cpu_has_fus

Re: Go patch committed: drop size arguments to hash/equal functions

2017-01-11 Thread Ian Lance Taylor
On Tue, Jan 10, 2017 at 11:45 AM, Rainer Orth wrote: > >> Drop the size arguments for the hash/equal functions stored in type >> descriptors. Types know what size they are. To make this work, >> generate hash/equal functions for types that can use an identity >> comparison but are not a standard

Re: [PATCH] Avoid generating code when writing PCH (PR c++/72813)

2017-01-11 Thread Jason Merrill
OK. On Tue, Jan 10, 2017 at 5:33 PM, Jakub Jelinek wrote: > Hi! > > The comments in both the C and C++ FEs say that after writing PCH file > when --output-pch= is used, we don't want to do anything else and the > routines return to the caller early, especially for C++ FE skipping lots of > needed

Re: [C++ PATCH] Fix ICE on invalid (PR c++/78341)

2017-01-11 Thread Jason Merrill
OK. On Tue, Jan 10, 2017 at 5:35 PM, Jakub Jelinek wrote: > Hi! > > As mentioned in the PR, cp_parser_parse_definitely may fail even when > alignas_expr actually is meaningful, e.g. when the error is due to the > missing closing paren. > > Bootstrapped/regtested on x86_64-linux and i686-linux, ok

Re: [RFC] combine: Handle zero_extend without subreg in change_zero_ext.

2017-01-11 Thread Segher Boessenkool
On Thu, Jan 05, 2017 at 05:46:51PM +0100, Dominik Vogt wrote: > The attached patch deals with another type of zero_extend that is > not yet handled in change_zero_ext, i.e. (zero_extend > (pseudoreg)), without a "subreg" in between. What do you think? > (Mostly untested yet.) My main question is:

Go patch committed: add Bfunction to conditional_expression backend method

2017-01-11 Thread Ian Lance Taylor
This patch by Than McIntosh modifies the conditional_expression method in the Backend interface to take a Bfunction. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed to mainline. Ian 2017-01-11 Than McIntosh * go-gcc.cc (conditional_expression): Add Bfunction parameter. I

Re: [patch,avr] PR78883: Implement a dummy scheduler

2017-01-11 Thread Georg-Johann Lay
Segher Boessenkool schrieb: On Wed, Jan 04, 2017 at 12:29:49PM -0700, Jeff Law wrote: We should split off a new "SUBREGS_OF_MEM_ALLOWED" from !INSN_SCHEDULING, and then probably even default it to false. That would work for me :-) The question in my mind would be unexpected fallout at this poi

[PATCh] Avoid in gcc.target/powerpc/ -m32 or -m64 in dg-options (PR target/77416)

2017-01-11 Thread Jakub Jelinek
Hi! The pr77416.c test fails in some configurations, where the -m32 option is not supported. The following patch fixes that by guarding the test with ilp32 effective target and removing the -m32 and adjusts a couple of tests that already have ilp32 or lp64 guard, but have useless -m32 or -m64 in

RE: Make MIPS soft-fp preserve NaN payloads for NAN2008

2017-01-11 Thread Maciej W. Rozycki
On Thu, 5 Jan 2017, Matthew Fortune wrote: > > > AFAIR we deliberately decided not to define a 2008-NaN soft-float > > > ABI, and chose to require all soft-float binaries to use the legacy > > encoding. > > > > Soft-float and 2008-NaN are naturally completely orthogonal and the > > combination w

Re: [PATCH 2/2] IPA ICF: make algorithm stable to survive -fcompare-debug

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 11:48:03AM +0100, Martin Liška wrote: > gcc/testsuite/ChangeLog: > > 2017-01-11 Martin Liska > > * gcc.dg/tree-ssa/flatten-3.c: Add -fno-ipa-icf to dg-options. > --- > gcc/testsuite/gcc.dg/tree-ssa/flatten-3.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(

RE: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Koval, Julia
Hi, I rebased the patch onto latest trunk version and changed specification according to ICC: _enclu_u32 (const int __L, size_t *__D) --> _enclu_u32 (const int __L, size_t __D[]) The Changelogs remained the same: gcc/ * common/config/i386/i386-common.c (OPTION_MASK_ISA_SGX_UNSET, O

[C++ PATCH] Overload pushing cleanup

2017-01-11 Thread Nathan Sidwell
In fixing 77812, a name lookup bug, I got confused by the overload creation code, which seemed a bit complex. This simplifies it by clearly separating the optional wrapping of a single decl from the subsequent prepending of the new decl. applied to trunk nathan -- Nathan Sidwell 2017-01-11

[PATCH] Fix DW_AT_data_member_location/DW_AT_bit_offset handling (PR debug/78839)

2017-01-11 Thread Jakub Jelinek
Hi! In GCC 5 and earlier, field_byte_offset had code for PCC_BITFIELD_TYPE_MATTERS target that figured out what DW_AT_data_member_location value to use vs. DW_AT_bit_offset. That code is still in there, but due to several bugs added in r231762 it never triggers anymore. One is that the is_{bit,by

[C++ PATCH] PR/77812 struct stat hack fix

2017-01-11 Thread Nathan Sidwell
issue 77812 turned out to be a srtuct stat hack problem, the bisected commit a red herring (that just made it noisy for the enum case). We wrap using decls and template functions in a singleton overload, and this can confuse set_namespace_binding into thinking we're augmenting an existing OVER

gcc-5 branch broken

2017-01-11 Thread Nathan Sidwell
Andre, this patch: 2017-01-11 Andre Vieira Backport from mainline 2016-12-09 Andre Vieira PR rtl-optimization/78255 * gcc/postreload.c (reload_cse_simplify): Do not CSE a function if NO_FUNCTION_CSE is true. breaks gcc 5 builds on targets that do: #de

Re: [PATCH, rs6000] Add vec_nabs builtin support

2017-01-11 Thread Segher Boessenkool
Hi Carl, On Mon, Jan 09, 2017 at 10:02:40AM -0800, Carl E. Love wrote: > * config/rs6000/rs6000-c: Add support for built-in functions rs6000-c.c > vector signed char vec_nabs (vector signed char) > vector signed short vec_nabs (vector signed short) > vector signed int vec

Re: [PATCH] Optimize n + 1 for automatic n array (PR c++/71537)

2017-01-11 Thread John Tytgat
On 01/10/2017 11:40 PM, Jakub Jelinek wrote: +constexpr bool +foo () +{ + constexpr int n[42] = { 1 }; + constexpr int o = n ? 1 : 0; + constexpr int p = n + 1 ? 1 : 0; + constexpr int q = "abc" + 1 ? 1 : 0; + return p + p + q == 3; +} Not o + p + q ? John.

Re: [PATCH] Optimize n + 1 for automatic n array (PR c++/71537)

2017-01-11 Thread Jakub Jelinek
On Wed, Jan 11, 2017 at 10:27:23PM +0100, John Tytgat wrote: > On 01/10/2017 11:40 PM, Jakub Jelinek wrote: > > +constexpr bool > > +foo () > > +{ > > + constexpr int n[42] = { 1 }; > > + constexpr int o = n ? 1 : 0; > > + constexpr int p = n + 1 ? 1 : 0; > > + constexpr int q = "abc" + 1 ? 1 :

C++ PATCH for c++/78337 (ICE with invalid generic lambda)

2017-01-11 Thread Jason Merrill
We instantiate the return type of the lambda outside of the function context, at which point trying to walk from the template instantiation context up to the context of 'f' hits NULL_TREE. So we should handle that. There was also a SFINAE issue whereby we skipped the error in SFINAE context, but

Re: [PATCH] Enable SGX intrinsics

2017-01-11 Thread Uros Bizjak
On Wed, Jan 11, 2017 at 8:59 PM, Koval, Julia wrote: > Hi, I rebased the patch onto latest trunk version and changed specification > according to ICC: > _enclu_u32 (const int __L, size_t *__D) --> _enclu_u32 (const int __L, > size_t __D[]) I have committed the patch with additional testsuite

RE: Make MIPS soft-fp preserve NaN payloads for NAN2008

2017-01-11 Thread Matthew Fortune
Maciej Rozycki writes: > On Thu, 5 Jan 2017, Matthew Fortune wrote: > > It is true to say that users are discouraged from using 2008-NaN with > > soft-float for pre-R6 architectures simply to avoid further fragmentation > > of software for no real gain. However, for R6 then soft-float is 2008-NaN

[PATCH, i386]: Increase memory address length only when rip_relative_addr_p returns false.

2017-01-11 Thread Uros Bizjak
Hello! Revision 204369 [1] inadvertently reversed the detection of RIP-relative address, resulting in the incorrect calculation of the insn length. Attached patch fixes this problem. 2017-01-11 Uros Bizjak * config/i386/i386.c (memory_address_length): Increase len only when rip_relati

Re: [PATCH] PR 78534 Change character length from int to size_t

2017-01-11 Thread Janne Blomqvist
On Sun, Jan 8, 2017 at 4:29 PM, Dominique d'Humières wrote: >> r244027 reverts r244011. Sorry for the breakage. It seems to affect >> all i686 as well in addition to power, maybe all 32-bit hosts. > > For the record, I see the following failures with an instrumented r244026 (as > in pr78672) [sn

Re: [PATCH] PR target/79004, Fix char/short -> _Float128 on PowerPC -mcpu=power9

2017-01-11 Thread Segher Boessenkool
On Mon, Jan 09, 2017 at 07:32:27PM -0500, Michael Meissner wrote: > This patch fixes PR target/79004 by eliminating the optimization of avoiding > direct move if we are converting an 8/16-bit integer value from memory to IEEE > 128-bit floating point. > > I opened a new bug (PR target/79038) to ad

Re: [PATCH] MIPS: Fix generation of DIV.G and MOD.G for Loongson targets.

2017-01-11 Thread Maciej W. Rozycki
On Mon, 9 Jan 2017, Toma Tabacu wrote: > The expand_DIVMOD function, introduced in r241660, will pick the divmod4 > (or the udivmod4) pattern when it checks for the presence of hardware > div/mod instructions, which results in the generation of the old DIV > instruction. > > Unfortunately, this i

Build failure cris-elf, gcc-5 backport of PR rtl-optimization/78255 fix, gcc/postreload.c:reload_cse_simplify

2017-01-11 Thread Hans-Peter Nilsson
For cris-elf on the gcc-5-branch at r244321: g++ -c -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -Woverloaded-virtual -pedantic -Wno-long-long -Wno-variadic-m

  1   2   >