[PATCH][PR rtl-optimization/78812] Fix pruning of expressions with embedded MEMs

2017-01-04 Thread Jeff Law
GCSE has some smarts to detect cases when a MEM appears in a block with predecessor edges marked as EDGE_ABNORMAL. Such MEMs are removed from the antic/transparent bitmaps. Unfortunately this code did not work if the MEM was not the topmost RTX. So something like (zero_extend (mem (...))

Re: [PR tree-optimization/71691] Fix unswitching in presence of maybe-undef SSA_NAMEs (take 2)

2017-01-04 Thread Trevor Saunders
On Fri, Dec 16, 2016 at 09:41:33AM -0500, Aldy Hernandez wrote: > Hi folks. > > This is a follow-up on Jeff and Richi's interaction on the aforementioned PR > here: > > https://gcc.gnu.org/ml/gcc-patches/2016-08/msg01397.html > > I decided to explore the idea of analyzing may-undefness

Re: [bootstrap-O3,fortran] silence warning in simplify_transformation_to_array

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Alexandre Oliva wrote: > I'll prepare and post a patch anyway, but do we want to make it > standard practice? Here it is. simplify_transformation_to_array had the nested loop unrolled 7 times, which is reasonable given that it iterates over arrays of size

[bootstrap-O1] change value type to avoid sprintf buffer size warning (was: Re: [bootstrap-O1] enlarge sprintf output buffer to avoid warning)

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Martin Sebor wrote: > The manual recommends to use a length modifier to constrain the length > of output to that of a narrower type: > sprintf (xname, "", ((unsigned short)((uintptr_t)(t) & 0x))); > This should work even without optimization. It

Re: [-fcompare-debug] var tracking options are not optimization options

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Alexandre Oliva wrote: > So I guess we need some alternate PerFunction option flag that makes > it per-function, but not part of the ICF hash? Like this... If we include them in the ICF hash, they may cause congruence_groups to be processed in a different

Re: [PATCH] s/__unused/__dimensions/ in

2017-01-04 Thread Tim Shen via gcc-patches
On Wed, Jan 4, 2017 at 7:16 PM, Tim Shen wrote: > Since it's an obvious textual fix, I'm going to check it in directly. Checked in with 80-columns limit respected. I have confusing tabstop settings... :/ -- Regards, Tim Shen

[PATCH] s/__unused/__dimensions/ in

2017-01-04 Thread Tim Shen via gcc-patches
Since it's an obvious textual fix, I'm going to check it in directly. -- Regards, Tim Shen commit b005916b043f52feed32b646f86ced80f3e5392b Author: Tim Shen Date: Wed Jan 4 19:07:07 2017 -0800 2017-01-05 Tim Shen PR

Re: [PATCH], PR 71977/70568/78823: Improve PowerPC code that uses SFmode in unions

2017-01-04 Thread David Edelsohn
On Wed, Jan 4, 2017 at 4:00 PM, Michael Meissner wrote: > On Wed, Jan 04, 2017 at 02:17:16PM -0500, David Edelsohn wrote: >> The change to rs6000_emit_move() really should have been in a helper >> function. We have to stop adding to the complexity of the function. I

Re: MAINTAINERS

2017-01-04 Thread Gerald Pfeifer
On Tue, 11 Oct 2016, Nathan Sidwell wrote: Update my email address Did you mean to step down as -type-safe vectors Nathan Sidwell maintainer? Unlike the other entries you modified, there is no + line with your new address. Gerald

Re: [PATCH v2] Add mcpu flag for Qualcomm falkor core

2017-01-04 Thread Gerald Pfeifer
On Thu, 10 Nov 2016, Richard Earnshaw wrote: >> * gcc/config/aarch64/aarch64-cores.def (qdf24xx): Update part >> number. >> (falkor): New core. > Installed. Please can you prepare a patch for the release notes as well. In case you are wondering, Siddhesh, Richard was referring to

Re: [C++ PATCH] Reject invalid reference type non-static data members in unions (PR c++/78890)

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 04:24:55PM -0500, Jason Merrill wrote: > On Mon, Jan 2, 2017 at 2:32 PM, Jakub Jelinek wrote: > > if (TREE_CODE (type) == REFERENCE_TYPE) > > { > > - error ("in C++98 %q+D may not have reference type %qT " > > -

Re: [C++ PATCH] Fix decomp handling of fields with reference type (PR c++/78931)

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 04:27:42PM -0500, Jason Merrill wrote: > On Thu, Dec 29, 2016 at 10:11 AM, Jakub Jelinek wrote: > > probe = TREE_OPERAND (probe, 0); > > TREE_TYPE (v[i]) = TREE_TYPE (probe); > > layout_decl (v[i], 0); > > -

[PATCH] correct off-by-one error in handling of precision of negative numbers (PR 78910)

2017-01-04 Thread Martin Sebor
The attached patch corrects an off-by-one mistake in handling non-zero precisions in signed conversions (%d and %i) with negative arguments, such as in sprintf(d, "%.2", -1). The call which results in the three bytes "-01" on output, not 2. I.e., the minus sign must be taken into consideration.

Re: [bootstrap-O3] add a default initializer to avoid a warning at -O3

2017-01-04 Thread David Malcolm
On Wed, 2017-01-04 at 09:04 -0700, Jeff Law wrote: > On 01/04/2017 06:42 AM, Jason Merrill wrote: > > On Wed, Jan 4, 2017 at 8:13 AM, Alexandre Oliva > > wrote: > > > On Jan 3, 2017, Jason Merrill wrote: > > > > > > > Are there bugzillas for these false

Re: [libcc1] add support for C++

2017-01-04 Thread Alexandre Oliva
On Dec 14, 2016, Alexandre Oliva wrote: > On Oct 19, 2016, Alexandre Oliva wrote: >> On Sep 23, 2016, Alexandre Oliva wrote: >>> This patchset adds support for the C++ language to libcc1. >>> It updates a few patches for libcc1 by Jan

Re: [C++ PATCH] Fix decomp handling of fields with reference type (PR c++/78931)

2017-01-04 Thread Jason Merrill
On Thu, Dec 29, 2016 at 10:11 AM, Jakub Jelinek wrote: > probe = TREE_OPERAND (probe, 0); > TREE_TYPE (v[i]) = TREE_TYPE (probe); > layout_decl (v[i], 0); > - SET_DECL_VALUE_EXPR (v[i], tt); > + SET_DECL_VALUE_EXPR (v[i],

Re: [C++ PATCH] Fix -Wunused-but-set-* false positive with ~ of vector type (PR c++/78949)

2017-01-04 Thread Jason Merrill
OK. On Thu, Dec 29, 2016 at 10:19 AM, Jakub Jelinek wrote: > Hi! > > For integral arg, mark_exp_read is called during > cp_perform_integral_promotions, for complex type it is called during > cp_default_conversion, but for vector types nothing actually calls it. > > Fixed

Re: [C++ PATCH] Reject invalid reference type non-static data members in unions (PR c++/78890)

2017-01-04 Thread Jason Merrill
On Mon, Jan 2, 2017 at 2:32 PM, Jakub Jelinek wrote: > if (TREE_CODE (type) == REFERENCE_TYPE) > { > - error ("in C++98 %q+D may not have reference type %qT " > -"because it is a member of a union", x, type); > -

Re: [C++ PATCH] Don't reject auto deduction of multiple variables if some initializers were type dependent (PR c++/78693)

2017-01-04 Thread Jason Merrill
OK. On Mon, Jan 2, 2017 at 3:11 PM, Jakub Jelinek wrote: > Hi! > > As the testcase shows, if some initializers are type dependent, auto_result > is still using auto, is not yet deduced and the deduction will happen during > instantiation. So rejecting it due to inconsistent

Re: [bootstrap-O3,fortran] silence warning in simplify_transformation_to_array

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Richard Biener wrote: >> Unfortunately I don't have another that silences the warning without >> (or even with) impact on codegen. > #pragma GCC diagnostic push ("Wno-array-bounds") > #pragma GCC diagnostic pop Wwwhaaat? #pragma GCC diagnostic to

Re: C/C++ PATCH to implement -Wpointer-compare warning (PR c++/64767) (version 2)

2017-01-04 Thread Joseph Myers
On Wed, 4 Jan 2017, Marek Polacek wrote: > Bootstrapped/regtested on x86_64-linux, ok for trunk? The C changes are OK. -- Joseph S. Myers jos...@codesourcery.com

Re: [PATCH] Error on Enum option without RejectNegative

2017-01-04 Thread Joseph Myers
On Wed, 4 Jan 2017, Jakub Jelinek wrote: > On Wed, Jan 04, 2017 at 01:31:28PM +0100, Richard Biener wrote: > > > Rather than implicit RejectNegative it might be better to just diagnose > > > such options as invalid. If you agree, I can implement that as follow-up. > > > Also note that

Re: [PATCH] vimrc: fix TAB settings

2017-01-04 Thread Gerald Pfeifer
On Mon, 14 Nov 2016, Martin Liška wrote: > Following patch adds TAB settings to contrib/vimrc file. > Hope it looks reasonable? This does not appear applied, are you waiting for approval? If so, for something like this in contrib we don't need to get overly strict and I'd say go ahead.

[PATCH] Improve -f{,no}-vect-cost-model

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 01:31:28PM +0100, Richard Biener wrote: > > And not sure why this actually > > is RejectNegative, wouldn't > > Common Alias(fvect-cost-model=,dynamic,unlimited) > > work just on fvect-cost-model (can test that)? > > Good question ;) If it works, ok. And here is a patch

[PATCH] Error on Enum option without RejectNegative

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 01:31:28PM +0100, Richard Biener wrote: > > Rather than implicit RejectNegative it might be better to just diagnose > > such options as invalid. If you agree, I can implement that as follow-up. > > Also note that RejectNegative is only needed on the Enum switches that have

Re: [PATCH] PR sanitizer/78992: Fix sigaction definition on 32-bit sparc

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 08:56:07PM +, James Clarke wrote: > libsanitizer: > PR sanitizer/78992 > * sanitizer_common/sanitizer_platform_limits_posix.h: sigaction > should only have __glibc_reserved0 as a member on 64-bit sparc. It should be committed upstream first and then

Re: C/C++ PATCH to implement -Wpointer-compare warning (PR c++/64767) (version 2)

2017-01-04 Thread Jason Merrill
On Wed, Jan 4, 2017 at 1:19 PM, Marek Polacek wrote: > +Note that the code above is illegal in C++11. "invalid". The C++ changes are OK. Jason

Re: [PATCH], PR 71977/70568/78823: Improve PowerPC code that uses SFmode in unions

2017-01-04 Thread Michael Meissner
On Wed, Jan 04, 2017 at 02:17:16PM -0500, David Edelsohn wrote: > The change to rs6000_emit_move() really should have been in a helper > function. We have to stop adding to the complexity of the function. I > won't insist that you split it out, but any addition of more than a > few lines in

Re: [PATCH] c++/78765

2017-01-04 Thread Jason Merrill
OK. Jason On Wed, Jan 4, 2017 at 11:44 AM, Nathan Sidwell wrote: > On 01/04/2017 10:13 AM, Jason Merrill wrote: > >> OK, that looks like the problem; we shouldn't be calling >> maybe_constant_value before we perform the conversion. > > > Yup, that worked. > > > ok? > > nathan >

[PATCH] PR sanitizer/78992: Fix sigaction definition on 32-bit sparc

2017-01-04 Thread James Clarke
libsanitizer: PR sanitizer/78992 * sanitizer_common/sanitizer_platform_limits_posix.h: sigaction should only have __glibc_reserved0 as a member on 64-bit sparc. --- libsanitizer/sanitizer_common/sanitizer_platform_limits_posix.h | 7 +-- 1 file changed, 5

Re: [PATCH], PR 71977/70568/78823: Improve PowerPC code that uses SFmode in unions

2017-01-04 Thread Michael Meissner
On Wed, Jan 04, 2017 at 02:17:16PM -0500, David Edelsohn wrote: > On Thu, Dec 29, 2016 at 7:24 PM, Michael Meissner > wrote: > > Mike, > > Thanks for the tremendous effort on this patch. A few comments. > > The ChangeLog contains a lot of extraneous commentary

Re: [PATCH] C++: fix fix-it hints for misspellings within explicit namespaces

2017-01-04 Thread Jason Merrill
On Tue, Jan 3, 2017 at 8:28 PM, David Malcolm wrote: > PR c++/77829 and PR c++/78656 identify an issue within the C++ frontend > where it issues nonsensical fix-it hints for misspelled name lookups > within an explicitly given namespace: it finds the closest name within > all

Re: [PATCH] Change DWARF5 .debug_loclists location description sizes from 2-byte length to uleb128 lengths

2017-01-04 Thread Jason Merrill
OK. On Tue, Jan 3, 2017 at 6:15 PM, Jakub Jelinek wrote: > Hi! > > http://dwarfstd.org/ShowIssue.php?issue=161102.1 > got accepted today, so DWARF5 is going to use uleb128 sizes instead of > 2-byte sizes in .debug_loclists section. > On a randomly chosen *.i file I had around,

Re: [C++ PATCH] Avoid UB in cp_lexer_previous_token (PR c++/71182)

2017-01-04 Thread Jason Merrill
OK. On Tue, Jan 3, 2017 at 5:42 PM, Jakub Jelinek wrote: > Hi! > > cp_lexer_new_from_tokens creates lexer that has NULL lexer->buffer, > calling lexer->buffer->address () therefore is UB (diagnosed by > --with-boot-config=bootstrap-ubsan). > > The following patch fixes this, or

Re: [C++ PATCH] Reject invalid auto foo (), a = 5;

2017-01-04 Thread Jason Merrill
On Tue, Jan 3, 2017 at 5:39 PM, Jakub Jelinek wrote: > + if (auto_function_declaration > + && (TREE_CODE (decl) == FUNCTION_DECL > + || auto_function_declaration != error_mark_node)) > + { > + error_at

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

2017-01-04 Thread Jeff Law
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 are normally disabled on targets that

Re: [PATCH] Special case clzl like builtins in factor_out_conditional_conversion (PR tree-optimization/71016)

2017-01-04 Thread Jeff Law
On 01/04/2017 11:01 AM, Jakub Jelinek wrote: On Wed, Jan 04, 2017 at 11:19:46AM +0100, Richard Biener wrote: For the SSA_NAME + INTEGER_CST case restrict it to the case if (x_1 > 5) tem_2 = (char) x_1; # tem_3 = PHI that is, (char) x_1 uses x_1 and that also appears in the

Re: [PR tree-optimization/67955] Exploit PTA in DSE

2017-01-04 Thread Jeff Law
On 01/04/2017 11:55 AM, Jeff Law wrote: On 12/09/2016 01:28 AM, Richard Biener wrote: On Wed, Dec 7, 2016 at 12:18 AM, Jeff Law wrote: So I was going through the various DSE related bugs as stumbled across 67955. The basic issue in 67955 is that DSE is too simplistic when

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

2017-01-04 Thread Segher Boessenkool
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 are normally disabled on targets that support insn >scheduling > 4. therefore,

Re: [PATCH], PR 71977/70568/78823: Improve PowerPC code that uses SFmode in unions

2017-01-04 Thread David Edelsohn
On Thu, Dec 29, 2016 at 7:24 PM, Michael Meissner wrote: Mike, Thanks for the tremendous effort on this patch. A few comments. The ChangeLog contains a lot of extraneous commentary that should be in the documentation comments. And a few typos in comments. >

Re: [PR tree-optimization/67955] Exploit PTA in DSE

2017-01-04 Thread Jeff Law
On 12/09/2016 01:28 AM, Richard Biener wrote: On Wed, Dec 7, 2016 at 12:18 AM, Jeff Law wrote: So I was going through the various DSE related bugs as stumbled across 67955. The basic issue in 67955 is that DSE is too simplistic when trying to determine if two writes hit the

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

2017-01-04 Thread Richard Sandiford
Segher Boessenkool writes: > On Wed, Jan 04, 2017 at 04:39:36PM +0100, Georg-Johann Lay wrote: >> Well, if it can be done in the back-end, then that's generally my strong >> preference. And the blocker for LRA is that it doesn't support cc0, >> hence LRA will require

Re: [PATCH] Fix late dwarf generated early from optimized out globals

2017-01-04 Thread Andreas Tobler
On 04.01.17 10:21, Richard Biener wrote: On Wed, 28 Dec 2016, Andreas Tobler wrote: On 28.12.16 19:24, Richard Biener wrote: On December 27, 2016 11:17:00 PM GMT+01:00, Andreas Tobler wrote: On 16.09.16 13:30, Richard Biener wrote: On Thu, 15 Sep 2016, Richard

C/C++ PATCH to implement -Wpointer-compare warning (PR c++/64767) (version 2)

2017-01-04 Thread Marek Polacek
This is another version of the patch I posted a while ago. To recap: Spurred by the recent findings, I decided to implement a warning that warns when a pointer is compared with a zero character literal (constant), because this isn't likely to be intended. So

Re: [PATCH] Special case clzl like builtins in factor_out_conditional_conversion (PR tree-optimization/71016)

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 11:19:46AM +0100, Richard Biener wrote: > For the SSA_NAME + INTEGER_CST case restrict it to the case > > if (x_1 > 5) > tem_2 = (char) x_1; > # tem_3 = PHI > > that is, (char) x_1 uses x_1 and that also appears in the controlling > GIMPLE_COND. That's

Re: [bootstrap-O1] enlarge sprintf output buffer to avoid warning

2017-01-04 Thread Martin Sebor
On 01/03/2017 10:39 AM, Jeff Law wrote: On 01/02/2017 10:28 PM, Alexandre Oliva wrote: In stage2 of bootstrap-O1, the code that warns if sprintf might overflow its output buffer cannot tell that an unsigned value narrowed to 16 bits will fit in 4 bytes with %4x. I couldn't find a better way to

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

2017-01-04 Thread Segher Boessenkool
On Wed, Jan 04, 2017 at 04:39:36PM +0100, Georg-Johann Lay wrote: > Well, if it can be done in the back-end, then that's generally my strong > preference. And the blocker for LRA is that it doesn't support cc0, > hence LRA will require an almost complete rewrite of the avr back-end... Heh,

Re: [PATCH] c++/78765

2017-01-04 Thread Nathan Sidwell
On 01/04/2017 10:13 AM, Jason Merrill wrote: OK, that looks like the problem; we shouldn't be calling maybe_constant_value before we perform the conversion. Yup, that worked. ok? nathan -- Nathan Sidwell 2017-01-04 Nathan Sidwell cp/ PR c++/78765 * pt.c

Re: [bootstrap-O3] add a default initializer to avoid a warning at -O3

2017-01-04 Thread Jeff Law
On 01/04/2017 06:42 AM, Jason Merrill wrote: On Wed, Jan 4, 2017 at 8:13 AM, Alexandre Oliva wrote: On Jan 3, 2017, Jason Merrill wrote: Are there bugzillas for these false positive warnings? I don't think so. Did you mean in the sense that the patch

Re: [PATCH, GCC/testsuite/ARM, ping] Fix empty_fiq_handler target selector

2017-01-04 Thread Thomas Preudhomme
On 04/01/17 09:42, Kyrill Tkachov wrote: On 03/01/17 17:22, Thomas Preudhomme wrote: Happy new year! Ping? Best regards, Thomas On 09/12/16 15:28, Thomas Preudhomme wrote: Hi, The current target selector for empty_fiq_handler.c testcase skips the test when targeting Thumb mode on a

[PATCH] PR78968 add configure check for __cxa_thread_atexit in libc

2017-01-04 Thread Jonathan Wakely
FreeBSD 11 adds __cxa_thread_atexit to libc, so we should use that instead of defining our own inferior version. This also avoids multiple definitions of the symbol. PR libstdc++/78968 * config.h.in: Regenerate. * configure: Likewise. * configure.ac: Check for

[patch,avr] PR78883: Implement a dummy scheduler

2017-01-04 Thread Georg-Johann Lay
On 03.01.2017 14:43, Richard Sandiford wrote: Georg-Johann Lay writes: On 02.01.2017 15:54, Dominik Vogt wrote: On Mon, Jan 02, 2017 at 03:47:43PM +0100, Georg-Johann Lay wrote: This fixes PR78883 which is a problem in reload revealed by a change to combine.c. The fix is as

Re: [PATCH] libstdc++: Allow using without lock free atomic int

2017-01-04 Thread Christophe Lyon
On 4 January 2017 at 16:10, Jonathan Wakely wrote: > On 04/01/17 16:00 +0100, Christophe Lyon wrote: >> >> Hi Jonathan, >> >> On 4 January 2017 at 12:02, Jonathan Wakely wrote: >>> >>> On 03/01/17 15:32 +, Jonathan Wakely wrote: Here's

Re: C++ PATCH for c++/77545 and c++/77284 (ICE with CLEANUP_STMT)

2017-01-04 Thread Jason Merrill
OK. On Tue, Jan 3, 2017 at 8:37 AM, Marek Polacek wrote: > The problem here is that we've gotten to potential_constant_expression_1 with > a > CLEANUP_STMT, but it doesn't know how to handle that so we ICE. I thought > it'd > be possible to look into CLEANUP_{BODY,EXPR} to

Re: [PATCH] PR c++/66735 lambda capture by reference

2017-01-04 Thread Jason Merrill
OK. On Wed, Jan 4, 2017 at 8:52 AM, Nathan Sidwell wrote: > On 01/04/2017 12:36 AM, Jason Merrill wrote: >> >> On 01/03/2017 08:57 AM, Nathan Sidwell wrote: > > >>> + type = auto_node; >>> + if (by_reference_p) > > >>> + type = build_reference_type (type); >>> +

Re: [PATCH] c++/78765

2017-01-04 Thread Jason Merrill
On Wed, Jan 4, 2017 at 9:33 AM, Nathan Sidwell wrote: > On 01/04/2017 12:40 AM, Jason Merrill wrote: >> On 12/16/2016 07:23 AM, Nathan Sidwell wrote: >>> >>> when cxx_eval_constant_expression finds a nonconstant expression it >>> returns a TREE without TREE_CONSTANT set. >>>

Re: [PATCH] libstdc++: Allow using without lock free atomic int

2017-01-04 Thread Jonathan Wakely
On 04/01/17 16:00 +0100, Christophe Lyon wrote: Hi Jonathan, On 4 January 2017 at 12:02, Jonathan Wakely wrote: On 03/01/17 15:32 +, Jonathan Wakely wrote: Here's what I plan to commit to trunk tomorrow. Committed to trunk. After this commit (r244051), I do see

Re: [PATCH][tree-ssa-address] Use simplify_gen_binary in gen_addr_rtx

2017-01-04 Thread Kyrill Tkachov
On 04/01/17 14:19, Richard Biener wrote: On Wed, Dec 21, 2016 at 10:40 AM, Kyrill Tkachov wrote: On 20/12/16 17:30, Richard Biener wrote: On December 20, 2016 5:01:19 PM GMT+01:00, Kyrill Tkachov wrote: Hi all, The testcase in this

Re: [PATCH] libstdc++: Allow using without lock free atomic int

2017-01-04 Thread Christophe Lyon
Hi Jonathan, On 4 January 2017 at 12:02, Jonathan Wakely wrote: > On 03/01/17 15:32 +, Jonathan Wakely wrote: >> >> Here's what I plan to commit to trunk tomorrow. > > > Committed to trunk. > > After this commit (r244051), I do see improvements, but also a few new

Re: [PATCH] c++/78765

2017-01-04 Thread Nathan Sidwell
On 01/04/2017 12:40 AM, Jason Merrill wrote: On 12/16/2016 07:23 AM, Nathan Sidwell wrote: when cxx_eval_constant_expression finds a nonconstant expression it returns a TREE without TREE_CONSTANT set. else if (non_constant_p && TREE_CONSTANT (r)) { /* This isn't actually constant, so

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

2017-01-04 Thread Joseph Myers
On Wed, 4 Jan 2017, Maciej W. Rozycki 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 works fine (of

Re: [PATCH][tree-ssa-address] Use simplify_gen_binary in gen_addr_rtx

2017-01-04 Thread Richard Biener
On Wed, Dec 21, 2016 at 10:40 AM, Kyrill Tkachov wrote: > > On 20/12/16 17:30, Richard Biener wrote: >> >> On December 20, 2016 5:01:19 PM GMT+01:00, Kyrill Tkachov >> wrote: >>> >>> Hi all, >>> >>> The testcase in this patch generates

Re: [bootstrap-O3,fortran] silence warning in simplify_transformation_to_array

2017-01-04 Thread Richard Biener
On Wed, Jan 4, 2017 at 2:23 PM, Alexandre Oliva wrote: > On Jan 4, 2017, Richard Biener wrote: > >> On Tue, Jan 3, 2017 at 7:19 PM, Jeff Law wrote: >>> On 01/02/2017 10:29 PM, Alexandre Oliva wrote: * simplify.c

Re: [-fcompare-debug] var tracking options are not optimization options

2017-01-04 Thread Richard Biener
On Wed, Jan 4, 2017 at 2:08 PM, Alexandre Oliva wrote: > On Jan 4, 2017, Richard Biener wrote: > >> On Tue, Jan 3, 2017 at 6:29 AM, Alexandre Oliva wrote: >>> If we include them in the ICF hash, they may cause congruence_groups

Re: [RFA][PATCH 3/4] Trim mem* calls in DSE

2017-01-04 Thread Richard Biener
On Fri, Dec 16, 2016 at 2:54 AM, Jeff Law wrote: > This is the 3rd patch in the kit to improve our DSE implementation. > > This patch supports trimming of the head or tail of a memset, memcpy or > memmove call. It's conceptually similar to trimming CONSTRUCTORS (and was > in

Re: [PATCH] Remove padding from DWARF5 headers

2017-01-04 Thread Jan Kratochvil
On Wed, 04 Jan 2017 00:09:43 +0100, Jakub Jelinek wrote: > Jan/Mark, are you going to adjust GDB/elfutils etc. correspondingly? My GDB DWARF-5 patchset is still off-trunk so that is sure OK. Jan

Re: [PATCH] PR c++/66735 lambda capture by reference

2017-01-04 Thread Nathan Sidwell
On 01/04/2017 12:36 AM, Jason Merrill wrote: On 01/03/2017 08:57 AM, Nathan Sidwell wrote: + type = auto_node; + if (by_reference_p) + type = build_reference_type (type); + by_reference_p = false; ^^^ here + if (!is_this && by_reference_p) +type =

Re: [PATCH] Remove padding from DWARF5 headers

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 02:46:51PM +0100, Jakub Jelinek wrote: > As for other proposals, not sure if I remember all the details, I think > 160808.1 is in, 161027.1 will say that the hashing of identifiers in > .debug_names (no matter if case sensitive or not) roughly starts by > replacing U+0131

Re: [RFA] [PATCH 4/4] Ignore reads of "dead" memory locations in DSE

2017-01-04 Thread Richard Biener
On Thu, Dec 22, 2016 at 7:26 AM, Jeff Law wrote: > This is the final patch in the kit to improve our DSE implementation. > > It's based on a observation by Richi. Namely that a read from bytes of > memory that are dead can be ignored. By ignoring such reads we can > sometimes

Re: [PATCH] Remove padding from DWARF5 headers

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 01:58:33PM +0100, Mark Wielaard wrote: > On Wed, Jan 04, 2017 at 12:09:43AM +0100, Jakub Jelinek wrote: > > 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

Re: [bootstrap-O3] add a default initializer to avoid a warning at -O3

2017-01-04 Thread Jason Merrill
On Wed, Jan 4, 2017 at 8:13 AM, Alexandre Oliva wrote: > On Jan 3, 2017, Jason Merrill wrote: > >> Are there bugzillas for these false positive warnings? > > I don't think so. > > Did you mean in the sense that the patch silences them and thus "fixes" >

Re: [RFA][PR tree-optimization/61912] [PATCH 2/4] Trimming CONSTRUCTOR stores in DSE - V3

2017-01-04 Thread Richard Biener
On Thu, Dec 22, 2016 at 7:26 AM, Jeff Law wrote: > This is the second patch in the kit to improve our DSE implementation. > > This patch recognizes when a CONSTRUCTOR assignment could be trimmed at the > head or tail because those bytes are dead. > > The first implementation of

Re: [RFA] [PR tree-optimization/33562] [PATCH 1/4] Byte tracking in DSE - v3

2017-01-04 Thread Richard Biener
On Wed, Jan 4, 2017 at 2:22 PM, Richard Biener wrote: > On Thu, Dec 22, 2016 at 7:26 AM, Jeff Law wrote: >> This is the first of the 4 part patchkit to address deficiencies in our DSE >> implementation. >> >> This patch addresses the P2 regression

Re: [bootstrap-O3,fortran] silence warning in simplify_transformation_to_array

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Richard Biener wrote: > On Tue, Jan 3, 2017 at 7:19 PM, Jeff Law wrote: >> On 01/02/2017 10:29 PM, Alexandre Oliva wrote: >>> * simplify.c (simplify_transformation_to_array): Assert the >>> array access is in range. Fix whitespace.

Re: [RFA] [PR tree-optimization/33562] [PATCH 1/4] Byte tracking in DSE - v3

2017-01-04 Thread Richard Biener
On Thu, Dec 22, 2016 at 7:26 AM, Jeff Law wrote: > This is the first of the 4 part patchkit to address deficiencies in our DSE > implementation. > > This patch addresses the P2 regression 33562 which has been a low priority > regression since gcc-4.3. To summarize, DSE no longer

Re: [bootstrap-O3] use unsigned type for regno in df-scan

2017-01-04 Thread Alexandre Oliva
On Jan 3, 2017, Jeff Law wrote: > What if REGNO is 2147483648 (assume 32 bit host). That will get us > into the else block in df_ref_record as it's >= FIRST_PSEUDO_REGISTER. > In df_ref_create_structure, we use the same expression to compute > REGNO, but this time it's

Re: [bootstrap-O3] add a default initializer to avoid a warning at -O3

2017-01-04 Thread Alexandre Oliva
On Jan 3, 2017, Jason Merrill wrote: > Are there bugzillas for these false positive warnings? I don't think so. Did you mean in the sense that the patch silences them and thus "fixes" them, or in the sense that the underlying cause for the warnings is not fixed and someone

Re: [-fcompare-debug] var tracking options are not optimization options

2017-01-04 Thread Alexandre Oliva
On Jan 4, 2017, Richard Biener wrote: > On Tue, Jan 3, 2017 at 6:29 AM, Alexandre Oliva wrote: >> If we include them in the ICF hash, they may cause congruence_groups to >> be processed in a different order due to different hashes, which in turn

Re: [PATCH][ARM] ARMv8-M Security Extensions: Warn for unused result for some intrinsics

2017-01-04 Thread Andre Vieira (lists)
On 04/01/17 11:30, Kyrill Tkachov wrote: > Hi Andre, > > On 04/01/17 11:21, Andre Vieira (lists) wrote: >> Hello, >> >> This patch adds the attribute "warn_unused_result" to the following >> intrinsics: >> __cmse_TT{,A,AT,T}_fptr >> cmse_TT{,A,AT,T} >> cmse_nonsecure_caller >>

Re: [PATCH] Remove padding from DWARF5 headers

2017-01-04 Thread Mark Wielaard
On Wed, Jan 04, 2017 at 12:09:43AM +0100, Jakub Jelinek wrote: > 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 bytes

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

2017-01-04 Thread Maciej W. Rozycki
On Wed, 4 Jan 2017, Matthew Fortune wrote: > > The MIPS sfp-machine.h has an _FP_CHOOSENAN implementation which > > emulates hardware semantics of not preserving signaling NaN payloads for > > an operation with two NaN arguments (although that doesn't suffice to > > avoid sNaN payload

Re: [v3 PATCH] Implement 2801, Default-constructibility of unique_ptr.

2017-01-04 Thread Jonathan Wakely
On 29/12/16 22:10 +0200, Ville Voutilainen wrote: On 29 December 2016 at 21:57, Ville Voutilainen wrote: Instead of repeating this condition half a dozen times, we could put it in the __uniq_ptr_impl class template and reuse it, as in the attached patch (and

Re: Pretty printers for versioned namespace

2017-01-04 Thread Jonathan Wakely
On 24/12/16 14:47 +0100, François Dumont wrote: On 15/12/2016 15:57, Jonathan Wakely wrote: And we could avoid three re.match expressions with complicated regular expressions by creating a helper function to do the "startswith" checks: def is_specialization_of(type, template_name): return

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

2017-01-04 Thread coypu
Identical patch was committed to NetBSD in April 28, 2008. https://github.com/jsonn/src/commit/7105def538f68e0a0034f5c93ec7fc384ca849b2

Re: [PATCH] Fix ICE with -fno-sso-struct=none (PR driver/78957)

2017-01-04 Thread Richard Biener
On Wed, Jan 4, 2017 at 12:40 PM, Jakub Jelinek wrote: > On Wed, Jan 04, 2017 at 12:27:09PM +0100, Richard Biener wrote: >> On Mon, Jan 2, 2017 at 8:27 PM, Jakub Jelinek wrote: >> > Enum options should not allow negative form, otherwise the option handling >> >

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

2017-01-04 Thread Richard Biener
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 multiple loop headers and > truncates the jump threading path in that case. > > What we should have done

Re: [-fcompare-debug] find jump before debug insns in expand

2017-01-04 Thread Richard Biener
On Tue, Jan 3, 2017 at 6:28 AM, Alexandre Oliva wrote: > A debug insn after the final jump of a basic block may cause the > expander to emit a dummy move where the non-debug compile won't > because it finds the jump insn at the end of the insn stream. > > Fix the condition so

Re: [bootstrap-O3,fortran] silence warning in simplify_transformation_to_array

2017-01-04 Thread Richard Biener
On Tue, Jan 3, 2017 at 7:19 PM, Jeff Law wrote: > On 01/02/2017 10:29 PM, Alexandre Oliva wrote: >> >> simplify_transformation_to_array had the nested loop unrolled 7 times, >> which is reasonable given that it iterates over arrays of size >> GFC_MAX_DIMENSIONS == 7. >> >> The

Re: [PR tree-optimization/71691] Fix unswitching in presence of maybe-undef SSA_NAMEs (take 2)

2017-01-04 Thread Richard Biener
On Tue, Jan 3, 2017 at 6:36 PM, Aldy Hernandez wrote: > On 12/20/2016 09:16 AM, Richard Biener wrote: >> >> On Fri, Dec 16, 2016 at 3:41 PM, Aldy Hernandez wrote: >>> >>> Hi folks. >>> >>> This is a follow-up on Jeff and Richi's interaction on the

Re: [committed] contrib/update-copyright.py --this-year

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 12:48:47PM +0100, Jakub Jelinek wrote: > On Sun, Jan 01, 2017 at 01:19:49PM +0100, Jakub Jelinek wrote: > > Update copyright years. > > > > (result of contrib/update-copyright.py --this-year). > > Apparently a bunch of directories I think we want to handle is not

Re: [committed] contrib/update-copyright.py --this-year

2017-01-04 Thread Jakub Jelinek
On Sun, Jan 01, 2017 at 01:19:49PM +0100, Jakub Jelinek wrote: > Update copyright years. > > (result of contrib/update-copyright.py --this-year). Apparently a bunch of directories I think we want to handle is not included by default. I've updated them by running

Re: [PR tree-optimization/71691] Fix unswitching in presence of maybe-undef SSA_NAMEs (take 2)

2017-01-04 Thread Richard Biener
On Wed, Dec 21, 2016 at 7:43 PM, Aldy Hernandez wrote: > On 12/20/2016 09:16 AM, Richard Biener wrote: > >> You do not handle memory or calls conservatively which means the existing >> testcase only needs some obfuscation to become a problem again. To fix >> that before /*

Re: [PATCH] Fix ICE with -fno-sso-struct=none (PR driver/78957)

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 12:27:09PM +0100, Richard Biener wrote: > On Mon, Jan 2, 2017 at 8:27 PM, Jakub Jelinek wrote: > > Enum options should not allow negative form, otherwise the option handling > > ICEs on it. -fsso-struct= allows only big-endian or little-endian, > >

Re: [-fcompare-debug] var tracking options are not optimization options

2017-01-04 Thread Richard Biener
On Tue, Jan 3, 2017 at 6:29 AM, Alexandre Oliva wrote: > If we include them in the ICF hash, they may cause congruence_groups to > be processed in a different order due to different hashes, which in turn > causes different funcdef_nos to be assigned to functions. Since these >

Re: [-fcompare-debug] skip more debug stmts in cleanup_empty_eh

2017-01-04 Thread Richard Biener
On Tue, Jan 3, 2017 at 6:28 AM, Alexandre Oliva wrote: > Various Ada RTS files failed -fcompare-debug compilation because debug > stmts prevented EH cleanups from taking place. Adjusting > cleanup_empty_eh to skip them fixes it. > > Regstrapped on x86_64-linux-gnu and

Re: [PATCH][ARM] ARMv8-M Security Extensions: Warn for unused result for some intrinsics

2017-01-04 Thread Kyrill Tkachov
Hi Andre, On 04/01/17 11:21, Andre Vieira (lists) wrote: Hello, This patch adds the attribute "warn_unused_result" to the following intrinsics: __cmse_TT{,A,AT,T}_fptr cmse_TT{,A,AT,T} cmse_nonsecure_caller cmse_check_address_range If the result of these intrinsics is not used it means the

Re: [PATCH] Fix ICE with -fno-sso-struct=none (PR driver/78957)

2017-01-04 Thread Richard Biener
On Mon, Jan 2, 2017 at 8:27 PM, Jakub Jelinek wrote: > Hi! > > Enum options should not allow negative form, otherwise the option handling > ICEs on it. -fsso-struct= allows only big-endian or little-endian, > -fno-sso-struct=big-endian or -fno-sso-struct=whatever makes no

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

2017-01-04 Thread Matthew Fortune
Joseph Myers writes: > The MIPS sfp-machine.h has an _FP_CHOOSENAN implementation which > emulates hardware semantics of not preserving signaling NaN payloads for > an operation with two NaN arguments (although that doesn't suffice to > avoid sNaN payload preservation in

Use a specfile that actually allows building programs on NetBSD

2017-01-04 Thread coypu
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 explicitly specifying -lc. This patch is needed for just about any program to work. --- gcc/config/netbsd.h | 2 ++ 1 file changed, 2 insertions(+)

[PATCH][ARM] ARMv8-M Security Extensions: Warn for unused result for some intrinsics

2017-01-04 Thread Andre Vieira (lists)
Hello, This patch adds the attribute "warn_unused_result" to the following intrinsics: __cmse_TT{,A,AT,T}_fptr cmse_TT{,A,AT,T} cmse_nonsecure_caller cmse_check_address_range If the result of these intrinsics is not used it means the result of the checks they perform are never used and that

  1   2   >