[PATCH, committed] PR 78976 Testcase changes

2017-01-04 Thread Janne Blomqvist
Hi, As r244011 had to be reverted, this change adds back the testcase changes that are needed due to r244003. Committed as obvious. 2017-01-04 Janne Blomqvist PR fortran/78534 PR fortran/78976 * gfortran.dg/dependency_49.f90: Change scan-tree-dump-times due to gfc_trans_string_copy change to

Update configure deps, remove stray \xA0 in picflag.m4, regen

2017-01-04 Thread Alan Modra
Also fix a stray changelog entry. Some of the regen here is due to previous changes not being regenerated properly, in part due to the missing configure dependencies. I noticed the picflag.m4 high bit set char and after fixing that found that some configure files didn't automatically update in ma

Re: [PATCH] Optimize X << Y with low bits of Y known to be 0 (PR tree-optimization/71563, take 2)

2017-01-04 Thread Richard Biener
On Thu, 29 Dec 2016, Jakub Jelinek wrote: > Hi! > > On Tue, Dec 20, 2016 at 09:45:03PM +0100, Jakub Jelinek wrote: > > > Note that you can write (shift @0 SSA_NAME@1) in the pattern instead of a > > > separate test. > > > > That is what I tried first, but there is some bug in genmatch.c that > >

Re: [PATCH] Do not sanitize in lower_omp_target context (PR, sanitizer/78815).

2017-01-04 Thread Martin Liška
PING^1 On 12/16/2016 01:04 PM, Martin Liška wrote: > Currently, use-after-scope relies on fact that entry point of > gimplify_decl_expr > is gimplify_function_tree. Fixed by checking if asan_poisoned_variables is > non-null. > > Patch can bootstrap on ppc64le-redhat-linux and survives regressio

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

2017-01-04 Thread Richard Biener
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 Biener wrote: > > > > > > > > > > > > > > This addr

Re: [PATCH] Do not sanitize in lower_omp_target context (PR, sanitizer/78815).

2017-01-04 Thread Jakub Jelinek
On Wed, Jan 04, 2017 at 10:19:28AM +0100, Martin Liška wrote: > PING^1 > > On 12/16/2016 01:04 PM, Martin Liška wrote: > > Currently, use-after-scope relies on fact that entry point of > > gimplify_decl_expr > > is gimplify_function_tree. Fixed by checking if asan_poisoned_variables is > > non-n

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

2017-01-04 Thread Kyrill Tkachov
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 device with ARM execution state. Because it chec

Re: [PATCH] Use the middle-end boolean_type_node

2017-01-04 Thread Janne Blomqvist
On Tue, Jan 3, 2017 at 9:20 PM, FX wrote: >> The regression with 8 bit boolean types surfaced with the z10 machine. The >> ABI is much older. Since >> we cannot change it anymore we should rather talk to the hardware guys to >> add the instruction we >> need. So for now we probably have to live

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

2017-01-04 Thread Richard Biener
On Mon, 2 Jan 2017, Jakub Jelinek wrote: > Hi! > > The clzl-like integral unary builtins at least from my short testing > on x86_64-linux and aarch64-linux usually benefit from > factor_out_conditional_conversion not being performed, i.e. the > sign-extension (or zero-extension) being performed c

Re: [PATCH v2] combine: Improve change_zero_ext, call simplify_set afterwards.

2017-01-04 Thread Dominik Vogt
On Fri, Dec 23, 2016 at 05:54:01PM +0100, Georg-Johann Lay wrote: > Segher Boessenkool schrieb: > >On Thu, Dec 22, 2016 at 04:18:34PM +0100, Georg-Johann Lay wrote: > >If you don't have instruction scheduling subregs of mem are allowed (and > >are counted as registers). Combine asks recog,

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 10:51:28AM +0100, Richard Biener wrote: > > The clzl-like integral unary builtins at least from my short testing > > on x86_64-linux and aarch64-linux usually benefit from > > factor_out_conditional_conversion not being performed, i.e. the > > sign-extension (or zero-extensi

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

2017-01-04 Thread Richard Biener
On Wed, 4 Jan 2017, Jakub Jelinek wrote: > On Wed, Jan 04, 2017 at 10:51:28AM +0100, Richard Biener wrote: > > > The clzl-like integral unary builtins at least from my short testing > > > on x86_64-linux and aarch64-linux usually benefit from > > > factor_out_conditional_conversion not being perfo

Re: Pointer Bounds Checker and trailing arrays (PR68270)

2017-01-04 Thread Richard Biener
On Thu, Dec 22, 2016 at 12:47 AM, Ilya Enkovich wrote: > 2016-12-21 22:18 GMT+03:00 Alexander Ivchenko : >> Right.. here is this updated chunk (otherwise no difference in the patch) >> >> diff --git a/gcc/tree-chkp.c b/gcc/tree-chkp.c >> index 2769682..6c7862c 100644 >> --- a/gcc/tree-chkp.c >> ++

Re: [PATCH][GIMPLEFE] Fix for ICE due to undeclared variable

2017-01-04 Thread Richard Biener
On Wed, Dec 28, 2016 at 7:27 PM, Prasad Ghangal wrote: > Hi, > The attached patch tries fix ICE due to undeclared variable(s) in the input. > Successfully bootstrapped on x86_64-pc-linux-gnu, testing is in progress Ok. Richard. > > Thanks, > Prasad

Re: [PATCH] varasm: Propagate litpool decl alignment to generated RTX.

2017-01-04 Thread Richard Biener
On Thu, Dec 22, 2016 at 1:58 PM, Andreas Krebbel wrote: > On 12/20/2016 11:38 AM, Richard Biener wrote: >> On Fri, Dec 16, 2016 at 9:29 PM, Andreas Krebbel >> wrote: >>> When pushing a value into the literal pool the resulting decl might >>> get a higher alignment than the original expression dep

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

2017-01-04 Thread Jonathan Wakely
On 03/01/17 15:32 +, Jonathan Wakely wrote: Here's what I plan to commit to trunk tomorrow. Committed to trunk.

[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 could

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(+) d

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 any case with just one NaN

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 sense. > > Bootstrapped/

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 res

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 i686-linux-gnu. Ok to insta

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 > numbers are include

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, > > -fno-sso-struct=big-endi

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 /* Check that any SSA name

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 contrib/update-copyright.py

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 inclu

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 aforementioned >>> PR >>> here: >>> >>> h

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 problem is that the

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 that, instead of requ

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 instead is invalidat

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 >> > ICEs on it. -fsso-struct= allows on

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: 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

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 similarly for the unique_ptr special

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 preservation

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: [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 >> cmse_check_address_r

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 >> causes different funcdef_nos to be assigned to

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 might want to look i

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 interpreted as a signed

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 has the ability t

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. > But once we default to release checking it

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 33562 which has been a low priority >> regression

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 this turned the CON

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" > them, or in the sense that the underlying

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 t

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 find additional sto

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 ch

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 = build_reference_

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: [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 fact developed first)

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 to >>> be processed in a different order due to different hashes, w

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 (simplify_transformation_to_array): Assert the array access is in range.

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 bogus assembly for arm with -O1 >>> -mfloat-abi=soft: >>>

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 course

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 u

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 failures. The big picture is

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 patch generates bogus assembly for arm with -O1 -mfloat-ab

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 improvements, but al

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. >>> else if (non_constan

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); >>> + by_reference_p

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 determine whether th

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 what I plan to commit to trunk tomorrow. >

[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 proposed by Seghe

[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 __cx

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 device

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 silences them and thus "fixes" them,

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 (convert_nontype_argument): D

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, gettin

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] 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 what enabl

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 e.

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 Biener wrote: This addresse

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 an almost complete rewrite of

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 same memory addre

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. > * config/rs6000/predicates

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, de

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 trying to determin

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 controlling

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: [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 (decl_specifiers.locations[ds_type_spe

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 Markus offered >

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, this results in shr

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 namespaces, and uses

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 that should be > in the documenta

[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 insertions(+),

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 > > > -- > Nathan S

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 rs6000

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 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 th

[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

[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 f

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. Gerald>Fr

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 RejectNegat

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: [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 silence warnings? Who'd have

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 deduction when one >

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); > - continue; > +

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 thusly, bootstrapped/regt

  1   2   >