Re: [PATCH] [5/6 Regression] Fix PR c++/66857

2015-07-25 Thread Jason Merrill
On 07/25/2015 04:16 PM, Patrick Palka wrote: On Sat, Jul 25, 2015 at 7:12 PM, Patrick Palka wrote: gcc/cp/ChangeLog: PR c++/66857 * cvt.c (ocp_convert): Don't call scalar_constant_value when converting to a class type. gcc/testsuite/ChangeLog: PR c++/66857

Re: [PATCH] Fix PR c++/18969 (invalid return statement diagnosed too late)

2015-07-25 Thread Jason Merrill
OK. Jason

[PATCH] Fix PR c++/18969 (invalid return statement diagnosed too late)

2015-07-25 Thread Patrick Palka
This patch makes check_return_expr less paranoid about checking the return value of a return-statement when processing a template declaration. At the same time this patch removes some vestigial code (the middle two hunks) that were related to the long-removed "named return value" gcc extension. I

Re: [PATCH] [5/6 Regression] Fix PR c++/66857

2015-07-25 Thread Patrick Palka
On Sat, Jul 25, 2015 at 7:12 PM, Patrick Palka wrote: > gcc/cp/ChangeLog: > > PR c++/66857 > * cvt.c (ocp_convert): Don't call scalar_constant_value when > converting to a class type. > > gcc/testsuite/ChangeLog: > > PR c++/66857 > * g++.dg/init/pr66857.C: N

[PATCH] [5/6 Regression] Fix PR c++/66857

2015-07-25 Thread Patrick Palka
gcc/cp/ChangeLog: PR c++/66857 * cvt.c (ocp_convert): Don't call scalar_constant_value when converting to a class type. gcc/testsuite/ChangeLog: PR c++/66857 * g++.dg/init/pr66857.C: New test. --- gcc/cp/cvt.c| 3 ++- gcc/testsuit

[gomp4] Fix some gomp tests

2015-07-25 Thread Nathan Sidwell
I've committed this to gomp4 branch. It fixes some tests that were incorrect and fail with some development I am working on. nathan 2015-07-25 Nathan Sidwell * testsuite/libgomp.oacc-c-c++-common/reduction-2.c: Copy lresult, not result for logical reductions. * testsuite/libgomp.oacc-c-c

[PATCH] DWARF: materialize subprogram renamings in Ada as imported declarations

2015-07-25 Thread Pierre-Marie de Rodat
Hello, This change makes GCC materialize subprogram renamings in Ada as imported declarations (DW_TAG_imported_declarations). For instance, procedure Foo renames Bar; will output: DW_TAG_imported_declaration: DW_AT_name: foo DW_AT_import: This new debugging informat

Re: [Revert][AArch64] PR 63521 Define REG_ALLOC_ORDER/HONOR_REG_ALLOC_ORDER

2015-07-25 Thread Andrew Pinski
On Fri, Jul 24, 2015 at 2:07 AM, Jiong Wang wrote: > > James Greenhalgh writes: > >> On Wed, May 20, 2015 at 01:35:41PM +0100, Jiong Wang wrote: >>> Current IRA still use both target macros in a few places. >>> >>> Tell IRA to use the order we defined rather than with it's own cost >>> calculation

Re: [PATCH 1/4] convert ASM_OUTPUT_ASCII to a hook

2015-07-25 Thread Trevor Saunders
On Fri, Jul 24, 2015 at 08:09:26PM -0700, pins...@gmail.com wrote: > > > > > > On Jul 24, 2015, at 7:36 PM, tbsaunde+...@tbsaunde.org wrote: > > +++ b/gcc/config/arm/arm.c > > @@ -18963,14 +18963,13 @@ int_log2 (HOST_WIDE_INT power) > > #define MAX_ASCII_LEN 51 > > > > void > > -output_ascii_p

Re: [PATCH 4/4] define ASM_OUTPUT_LABEL to the name of a function

2015-07-25 Thread Segher Boessenkool
On Sat, Jul 25, 2015 at 02:40:56PM -0400, Trevor Saunders wrote: > > If so many targets use default_assemble_label, can you make it an actual > > default instead of defining it everywhere? > > Well, it is the default, but many targets do over ride it to set it to > the default ;) Right, noticed

[v3 PATCH] PR libstdc++/60970, implement LWG 2148

2015-07-25 Thread Ville Voutilainen
Tested on Linux-PPC64. The proposed resolution of the issue doesn't really say whether our regression test for PR libstdc++/52931 should remain valid. However, it doesn't say that we shouldn't keep it valid, either. This approach keeps it valid, but provides support for hashing enums. It took a wh

Re: [PATCH 4/4] define ASM_OUTPUT_LABEL to the name of a function

2015-07-25 Thread Trevor Saunders
On Sat, Jul 25, 2015 at 10:59:19AM -0500, Segher Boessenkool wrote: > On Fri, Jul 24, 2015 at 10:37:00PM -0400, tbsaunde+...@tbsaunde.org wrote: > > --- a/gcc/config/pa/pa.c > > +++ b/gcc/config/pa/pa.c > > @@ -9761,6 +9761,18 @@ pa_reloc_rw_mask (void) > >return 3; > > } > > > > +/* Assembl

Re: [Patch, fortran] PR66929 fix iso_varying_string ICE

2015-07-25 Thread Mikael Morin
Le 21/07/2015 23:10, Paul Richard Thomas a écrit : Hi Mikael, This looks fine to me - OK for trunk. Thanks for the patch Paul On 21 July 2015 at 14:53, Mikael Morin wrote: Hello, The fix for PR61831 committed recently [1] introduced/uncovered a NULLL pointer dereference with iso_varying_st

Re: PR c/16351 Extend Wnonnull for returns_nonnull

2015-07-25 Thread Bernhard Reutner-Fischer
On July 25, 2015 1:15:21 AM GMT+02:00, Trevor Saunders wrote: > >Another case is > >Foo * >bar() >{ > #if SHOULD_USE_BAR > ... >#else > return NULL; >#endif >} > >And somehow your program is setup so bar is only called when >SHOULD_USE_BAR is defined. In that sort of case it may be convenien

Re: [PATCH 4/4] define ASM_OUTPUT_LABEL to the name of a function

2015-07-25 Thread Segher Boessenkool
On Fri, Jul 24, 2015 at 10:37:00PM -0400, tbsaunde+...@tbsaunde.org wrote: > --- a/gcc/config/pa/pa.c > +++ b/gcc/config/pa/pa.c > @@ -9761,6 +9761,18 @@ pa_reloc_rw_mask (void) >return 3; > } > > +/* Assemble a lable. */ Typo. > +void > +pa_output_label (FILE *f, const char *label) > +{

Re: [PATCH 1/4] convert ASM_OUTPUT_ASCII to a hook

2015-07-25 Thread Segher Boessenkool
On Fri, Jul 24, 2015 at 10:36:57PM -0400, tbsaunde+...@tbsaunde.org wrote: > -@defmac ASM_OUTPUT_ASCII (@var{stream}, @var{ptr}, @var{len}) > -A C statement to output to the stdio stream @var{stream} an assembler > -instruction to assemble a string constant containing the @var{len} > -bytes at @var

Re: [PATCH] warn for unsafe calls to __builtin_return_address

2015-07-25 Thread Segher Boessenkool
On Thu, Jul 23, 2015 at 11:08:21PM -0600, Jeff Law wrote: > >There's the following comment in expand_builtin_frame_address: > > > > /* Some ports cannot access arbitrary stack frames. */ > > > >just before a block of code where the function can lead to > >an "invalid argument" warning which

[SH][committed] Fix PR 66930

2015-07-25 Thread Oleg Endo
Hi, This fixes an SH bug that has been discovered during the discussions of PR 66930. Tested by Kaz on sh4-linux. Committed to trunk as r226218 and to GCC 5 branch as r226219. Cheers, Oleg gcc/ChangeLog PR target/66930 * config/sh/sh.c (sh_split_movrt_negc_to_movt_xor): Add miss

[PATCH, i386]: Use SUBREG_P predicate

2015-07-25 Thread Uros Bizjak
2015-07-25 Uros Bizjak * config/i386/i386.c: Use SUBREG_P predicate. * config/i386/i386.md: Ditto. * config/i386/sse.md: Ditto. * config/i386/predicates.md: Ditto. Bootstrapped on x86_64-linux-gnu, committed to mainline SVN. Uros. Index: config/i386/i386.c

[PATCH, i386]: Fix PR 67004, valgrind error in recog_memoized & shorten_branches

2015-07-25 Thread Uros Bizjak
This patch fixes/improves check for valid insn in newly introduced ADJUST_INSN_LENGTH. (Please note that other targets (e.g. aarch64) needs similar fix. MIPS could use NONDEBUG_INSN_P instead of INSN_P there.) 2015-07-25 Uros Bizjak PR target/67004 * config/i386/i386.h (ADJUST_INSN_LE

[PATCH, i386]: Fix PR 66648, incorrect memcpy expansion with unrolled_loop strategy at -O2

2015-07-25 Thread Uros Bizjak
We have to emit check for main loop execution UNLESS we guarantee that min_size is at least equal to size_needed. In this testcase, VRP declared minimum copying size, and after unaligned prologue adjustment, min_size was still non-zero. The !min_size check didn't account for the case that min_size

Re: [PATCH] Don't allow unsafe reductions in graphite

2015-07-25 Thread Tom de Vries
On 24/07/15 22:20, Sebastian Pop wrote: Richard Biener wrote: On Wed, Jul 22, 2015 at 6:00 PM, Tom de Vries wrote: Currently bootstrapping and reg-testing on x86_64. OK for trunk? OK 5 and 4.9 release branches? Ok if Sebastian is fine with it. Ok to backport as well. Thanks Tom for the p

Re: [PATCH] [graphite] dump reasons why graphite failed to detect a scop

2015-07-25 Thread Tobias Grosser
On 07/25/2015 12:36 AM, Sebastian Pop wrote: When trying to analyze why Graphite does not handle a loop nest, it is easy to look in the dumps of -fdump-tree-graphite-all to guess what has to be changed to catch the loop. This patch makes the dumps a bit more verbose and useful. --- gcc/graphit

Re: [PATCH, i386]: Fix PR 64003, valgrind complains about get_attr_length_nobnd in insn-attrtab.c from i386.md

2015-07-25 Thread Uros Bizjak
On Sat, Jul 25, 2015 at 1:17 AM, Tom de Vries wrote: > On 24/07/15 18:29, Uros Bizjak wrote: >> >> This patch introduces ADJUST_INSN_LENGTH define to i386.h to increase >> the length of the insn when bnd prefix is used. [...] > Is it possible this causes a build breaker on x86_64 with > --enable

Re: [Patch] Small refactor on _State<>

2015-07-25 Thread Tim Shen
On Sat, Jul 25, 2015 at 12:11 AM, Tim Shen wrote: > It's not a very necessary refactoring, but simply can't resist. :) > > I'm not sure of the ::memcpy calls. It looks not very idiomatic, but > std::copy on char* looks even more weird? :/ > > Bootstrapped and tested. > > Thanks! > > > -- > Regards