Re: More forwprop for vectors

2013-06-12 Thread Marc Glisse
On Wed, 12 Jun 2013, Jeff Law wrote: 2013-06-13 Marc Glisse * tree-ssa-forwprop.c (simplify_bitwise_binary, associate_plusminus): Generalize to complex and vector. * tree.c (build_all_ones_cst): New function. * tree.h (build_all_ones_cst): Declare it. This is OK. Extra

Re: [patch] set MULTIARCH_DIRNAME for multilib architectures

2013-06-12 Thread Bernhard Reutner-Fischer
On 12 June 2013 20:20:50 Richard Sandiford wrote: Matthias Klose writes: > Index: config/mips/t-linux64 > === > --- config/mips/t-linux64 (revision 200012) > +++ config/mips/t-linux64 (working copy) > @@ -24,3 +24,13 @@ > ../li

Re: [PATCH] PR57518, RA generated redundent code

2013-06-12 Thread Wei Mi
The testcase is attached. Thanks, Wei. On Wed, Jun 12, 2013 at 5:03 PM, H.J. Lu wrote: > On Wed, Jun 12, 2013 at 2:44 PM, Wei Mi wrote: >> Hi, >> >> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57518 >> >> pr57518 happened because update_equiv_regs in IRA marked a reg >> equivalent with a mem, l

powerpc64le abi check

2013-06-12 Thread Alan Modra
In order to check powerpc64le abi symbols. Bootstrapped etc. powerpc64-linux. OK to apply? * configure.host (abi_baseline_pair): Match powerpc64*. Index: libstdc++-v3/configure.host === --- libstdc++-v3/configure.host (revi

Re: [RFC] Inconsistency in ordering vector widening operations on big-endian targets?

2013-06-12 Thread Alan Modra
On Wed, Jun 12, 2013 at 04:22:46PM +0100, Tejas Belagod wrote: > From the IR above, it seems that result of widening the high part > (vect__12.6_40) is being stored at offset 0 from _29 and result of > widening the low part goes into *(_29 + 16). Shouldn't this be the > other way around? Big-endia

[PATCH GCC]Consider NOP_EXPR and CONVERT_EXPR as equal nodes in operand_equal_p

2013-06-12 Thread Bin Cheng
Hi, This is a case of NOP_EXPR and CONVERT_EXPR not compared equal in operand_equal_p, resulting in below two nodes are considered different: NODE 0: unit size align 16 symtab 0 alias set 4 canonical type 0xb74602a0 precision 16 min max context pointer_to_this > a

[PATCH GCC]Check the code to be executed for COND_EXEC in noop_move_p

2013-06-12 Thread Bin Cheng
Hi, For arm, gcc generates redundant assembly code like "movlt r4, r4", because it doesn't check noop move for COND_EXEC instructions. This patch fixes the issue by checking the inner code to be executed for COND_EXEC in noop_move_p. Bootstrap and test on both x86 and cortex-a15. Is it OK? Than

Re: [RS6000] IBM long double little-endian

2013-06-12 Thread David Edelsohn
On Wed, Jun 12, 2013 at 10:53 AM, Alan Modra wrote: > FLOAT_WORDS_BIG_ENDIAN doesn't work out too well for IBM extended > double when little-endian, because we're thinking to keep the large > magnitude double first. See the comment below on > LONG_DOUBLE_LARGE_FIRST. > > This patch fixes all occu

Re: GCC does not support *mmintrin.h with function specific opts

2013-06-12 Thread Sriraman Tallam
Hi Honza, I have isolated the ipa-inline.c part into a separate patch with a test and attached it here. The patch is simple. Could you please take a look? * ipa-inline.c (can_early_inline_edge_p): Flag an error when the function that cannot be inlined is target specific.

[C++ Patch] PR 57599

2013-06-12 Thread Paolo Carlini
Hi, this dynamic_cast bug, which just came in, notices that in the simple case of static conversion we forget to perform the cv-qualifier conversions. It seems to me that we are missing a build_nop. I extended quite a bit the testcase, to references too, because at some point I got those wro

Re: [Bug libstdc++/56430] In __airy: return-statement with a value, in function returning 'void'.

2013-06-12 Thread Paolo Carlini
On 06/13/2013 02:10 AM, Ed Smith-Rowland wrote: The point of the patch is to fix the base function and then offer access to the function as a gcc extension. boost has these functions. These have been offered in C++ library papers extending TR 29123. If Boost already has those extensions and are

Re: C++: fix ICE with CONST_DECLs

2013-06-12 Thread Jason Merrill
Go ahead and apply the patch; it never hurts to make the code more robust. Jason

Re: C++: fix ICE with CONST_DECLs

2013-06-12 Thread Mike Stump
On Jun 11, 2013, at 11:00 AM, Jason Merrill wrote: > On 06/11/2013 12:39 PM, Paolo Carlini wrote: >> On 06/11/2013 06:27 PM, Mike Stump wrote: >>> Here is a simple one. When processing CONST_DECLs after an error, we >>> can ICE. This avoid the ICE. > >> No testcase? > > Yep; the patch is fine,

Re: [Bug libstdc++/56430] In __airy: return-statement with a value, in function returning 'void'.

2013-06-12 Thread Ed Smith-Rowland
Original Message Subject: Re: [Bug libstdc++/56430] In __airy: return-statement with a value, in function returning 'void'. Date: Wed, 12 Jun 2013 20:02:27 -0400 From: Ed Smith-Rowland <3dw...@verizon.net> To: libstd...@gcc.gnu.org , gcc-patches Origi

Re: [PATCH] PR57518, RA generated redundent code

2013-06-12 Thread H.J. Lu
On Wed, Jun 12, 2013 at 2:44 PM, Wei Mi wrote: > Hi, > > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57518 > > pr57518 happened because update_equiv_regs in IRA marked a reg > equivalent with a mem, lowered its mem_cost in scan_one_insn, set > NO_REGS to its rclass, but didn't consider the reg was

[google/gcc-4_8] Add support for .debug_gnu_pubnames/pubtypes section.

2013-06-12 Thread Cary Coutant
This patch is ported from the google/gcc-4_7 branch. Tested with crosstool_validate.py and committed. -cary include: 2012-08-20 Sterling Augustine * gdb/gdb-index.h: Check in from src. gcc: 2012-08-20 Sterling Augustine * dwarf2out.c (DEBUG_PUBNAMES_SECTION, DEBUG_PUB

Go patch committed: Implement Go 1.1 terminating statements

2013-06-12 Thread Ian Lance Taylor
The Go 1.1 release defines what it means for a function to have a terminating statement, and makes it an error for a function with return values to not have one. This patch, from Rémy Oudompheng, implements that for gccgo. Bootstrapped and ran testsuite on x86_64-unknown-linux-gnu. Committed to

Re: [PATCH 1/4] Fix trailing whitespaces

2013-06-12 Thread Joseph S. Myers
In general I think no formatting fixes should be made to GCC testcases, including removal of trailing whitespace; it's good if they cover a range of coding styles and oddities as that reflects how GCC is used in practice. -- Joseph S. Myers jos...@codesourcery.com

[PATCH] fix for c/PR57577

2013-06-12 Thread Iyer, Balaji V
Hello Everyone, This patch fixes an ICE when rank mismatch occurs in a modify expression where the right-hand side is a function call. The crash is actually occuring in a while loop whose result is not used, i.e. dead code. I removed the dead code and things seem to work fine now. Teste

[patch] reimplement -fstrict-volatile-bitfields

2013-06-12 Thread Sandra Loosemore
Background: on ARM and some other targets, the ABI requires that volatile bit-fields be accessed atomically in a mode that corresponds to the declared type of the field, which conflicts with GCC's normal behavior of doing accesses in a mode that might correspond to the size of a general-purpos

Re: [PATCH, rs6000] power8 patches, patch #7, quad/byte/half-word atomic instructions

2013-06-12 Thread David Edelsohn
On Tue, Jun 11, 2013 at 7:53 PM, Michael Meissner wrote: > I needed to rework the sync.md so that it would work correctly with no > optimization (using SUBREG's at -O0 did not give us the even registers for > holding PTImode values, so I created a PTImode temporary in load_lockedti and > store_con

[PATCH] PR57518, RA generated redundent code

2013-06-12 Thread Wei Mi
Hi, http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57518 pr57518 happened because update_equiv_regs in IRA marked a reg equivalent with a mem, lowered its mem_cost in scan_one_insn, set NO_REGS to its rclass, but didn't consider the reg was used in paradoxical subreg which prevented the reg from bei

Re: patch to fix PR57559 for s390

2013-06-12 Thread Richard Sandiford
Vladimir Makarov writes: > Index: lra.c > === > --- lra.c (revision 199753) > +++ lra.c (working copy) > @@ -306,11 +306,11 @@ lra_emit_add (rtx x, rtx y, rtx z) > || (disp != NULL_RTX && ! CONSTANT_P (disp)) >

Re: [gomp4] Some progress on #pragma omp simd

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 10:38:00AM -0700, Richard Henderson wrote: > On 06/12/2013 10:30 AM, Jakub Jelinek wrote: > > So the built-ins would take address of this decl, something else? > > Perhaps address, perhaps just referenced uninitialized? True, assuming no pass would actually want to change

Re: [Debug/Fortran] PR37132 - RFC/RFA - support DW_TAG_namelist

2013-06-12 Thread Mikael Morin
Hello, Le 10/06/2013 22:40, Tobias Burnus a écrit : > My problem: I do not see where one can best handle the namelist for > modules. One possibility would be gen_namespace_die - but that would > come before the dies of all VAR_DECLs used in the namelist have been > created. And the code seems to

[committed] Fix mips/memcpy-1.c after DATA_ALIGNMENT change

2013-06-12 Thread Richard Sandiford
Make the array non-common so that it is treated as binding to the current TU. Tested on mipsisa32-sde-elf and applied. Richard gcc/testsuite/ * gcc.target/mips/mips.exp: Handle -f{no-,}common. * gcc.target/mips/memcpy-1.c: Remove redundant dg-do. Run with -fno-common. I

Re: [Bug libstdc++/56430] In __airy: return-statement with a value, in function returning 'void'.

2013-06-12 Thread Paolo Carlini
Hi, On 06/12/2013 10:28 PM, 3dw...@verizon.net wrote: Here is an overdue patch for the Airy function. I repair the void function and I out two Airy functions as C++ extensions. Built and tested on x86_64-linux. OK? The functions are unused, please remove them and close the PR. Thanks, Paolo.

Re: More forwprop for vectors

2013-06-12 Thread Marc Glisse
On Wed, 12 Jun 2013, Jeff Law wrote: On 06/12/13 14:17, Marc Glisse wrote: On Wed, 12 Jun 2013, Marc Glisse wrote: I suppose it's explicitely not allowing complex integer constants? Hmm... Thanks, I keep forgetting complex :-( And complex is even more of a pain than vector to handle. Te

Re: RFC [MIPS, RS6000] Mangling of IBM long double template literals

2013-06-12 Thread Richard Sandiford
"Joseph S. Myers" writes: > On Thu, 13 Jun 2013, Alan Modra wrote: >> This is of course an ABI change for any existing little-endian users >> of IBM long double literals in templates. On powerpc, I think we can >> safely say there are no such users. However it does look like MIPS >> also uses a

Re: More forwprop for vectors

2013-06-12 Thread Jeff Law
On 06/12/13 14:17, Marc Glisse wrote: On Wed, 12 Jun 2013, Marc Glisse wrote: I suppose it's explicitely not allowing complex integer constants? Hmm... Thanks, I keep forgetting complex :-( And complex is even more of a pain than vector to handle. Testing for CONSTANT_CLASS_P seems suffic

Re: [Patch, fortran] PR 49074 ICE on defined assignment with class arrays.

2013-06-12 Thread Tobias Burnus
Hello Mikael, Mikael Morin wrote: Regression tested on x86_64-unknown-linux-gnu. OK for trunk? OK - looks good to me. The test case is also nice and a bit tricky, I tried it with three compilers: Two segfaulted at run time and only one passed the test. Tobias

[Patch, fortran] PR 49074 ICE on defined assignment with class arrays.

2013-06-12 Thread Mikael Morin
Hello, this is a fix for PR49074, where the temporary created by gfc_conv_elemental_dependencies was leading to an ICE because it didn't have the array reference expected by the scalarization code. There was a bypass in gfc_conv_procedure_call avoiding exactly this problem, but it is not reached

Re: [PATCH 0/4] Fix leading and trailing whitespaces.

2013-06-12 Thread Marc Glisse
On Wed, 12 Jun 2013, Ondřej Bílka wrote: I am writing a tool to fix common style issues. This is first part which deals with leading and trailing whitespaces. I can follow this up with other refactorings, for example rewriting K&R definitions. Bonus points for asking first ;-) 2013-06-12

RE: [Bug libstdc++/56430] In __airy: return-statement with a value, in function returning 'void'.

2013-06-12 Thread 3dw4rd
Here is an overdue patch for the Airy function. I repair the void function and I out two Airy functions as C++ extensions. Built and tested on x86_64-linux. OK? Ed CL_Airy Description: Binary data patch_Airy4 Description: Binary data

Re: More forwprop for vectors

2013-06-12 Thread Marc Glisse
On Wed, 12 Jun 2013, Marc Glisse wrote: I suppose it's explicitely not allowing complex integer constants? Hmm... Thanks, I keep forgetting complex :-( And complex is even more of a pain than vector to handle. Testing for CONSTANT_CLASS_P seems sufficient here. Some transformations also se

Re: Unordered container insertion hints

2013-06-12 Thread François Dumont
Hi Any news regarding this patch ? Thanks François On 06/06/2013 10:33 PM, François Dumont wrote: On 05/24/2013 01:00 AM, Paolo Carlini wrote: On 05/23/2013 10:01 PM, François Dumont wrote: Some feedback regarding this patch ? Two quick ones: what if the hint is wrong? I suppose the in

Re: [PATCH 4/4] Fix leading spaces.

2013-06-12 Thread Ondřej Bílka
A followup to previous patch is more general pass that changes leading spaces to tabs followed by at most 8 spaces. http://kam.mff.cuni.cz/~ondra/0004-Formatted-by-leading_space.patch

[PATCH 3/4] Fix space followed by tab

2013-06-12 Thread Ondřej Bílka
Now we move to leading spaces, If you want only to fix leading spaces followed by tab then please use following patch http://kam.mff.cuni.cz/~ondra/0003-Formatted-by-space_before_tab.patch

[PATCH 2/4][RFC] Remove form feeds.

2013-06-12 Thread Ondřej Bílka
A second part of this cleanup is optional. If you want to preserve form feeds its your decision, If you want to remove them here is patch. http://kam.mff.cuni.cz/~ondra/0002-Formatted-by-form_feed.patch

[PATCH, committed] Replaced abort and exit in 1 Cilk Plus Array Notation test

2013-06-12 Thread Iyer, Balaji V
Hello Everyone, I replaced abort and exit in one of the Cilk Plus Array Notation test with return 1 and return 0, respectively. This patch (cut and pasted below) is committed as obvious. Thanks, Balaji V. Iyer. Index: gcc/testsuite/ChangeLog

[PATCH 0/4] Fix leading and trailing whitespaces.

2013-06-12 Thread Ondřej Bílka
Hi, I am writing a tool to fix common style issues. This is first part which deals with leading and trailing whitespaces. I can follow this up with other refactorings, for example rewriting K&R definitions. I wrote a simple programs that fixes them. Then it suffices for me or any volunteer to r

Re: [C++ Path] PR 38958

2013-06-12 Thread Jason Merrill
OK. Jason

Re: Aw: Re: [PATCH] Basic support for MIPS r5900

2013-06-12 Thread Richard Sandiford
"Jürgen Urban" writes: >> > How much other changes will be currently accepted here? There is other >> > stuff which I want to prepare and submit here, e.g.: >> > 1. disable use of dmult and ddiv (ABI n32). >> > 2. use trunc.w.s instead of cvt.w.s (to get single float working for >> > normal range

Re: [patch, mips] Micromips delay slot fix

2013-06-12 Thread Richard Sandiford
Richard Sandiford writes: > "Moore, Catherine" writes: >> I'm testing a slightly different patch from the one that Steve posted: >> >> Index: mips.md >> === >> --- mips.md (revision 199648) >> +++ mips.md (working copy) >> @@

[google/gcc-4_8] Port patches to fix ICEs when using -fdebug-types-section.

2013-06-12 Thread Cary Coutant
I've ported the following four patches from the google/gcc-4_7 branch. (I'll also push these to trunk shortly.) Bootstrapped, tested, and committed at r200036. -cary gcc: 2012-08-09 Cary Coutant Backport of pending upstream patch. * dwarf2out.c (clone_as_declaration): Copy DW

Re: [C++ Path] PR 38958

2013-06-12 Thread Paolo Carlini
Hi, On 06/12/2013 07:46 PM, Jason Merrill wrote: On 06/12/2013 01:37 PM, Paolo Carlini wrote: Rewording: as the one line comment says, I only call non_reference at the outset when I know that either we'll end up producing the normal unused-variable warning or nothing at all. Oh, I see. But th

Re: [patch] set MULTIARCH_DIRNAME for multilib architectures

2013-06-12 Thread Richard Sandiford
Matthias Klose writes: > Index: config/mips/t-linux64 > === > --- config/mips/t-linux64 (revision 200012) > +++ config/mips/t-linux64 (working copy) > @@ -24,3 +24,13 @@ > ../lib32$(call > if_multiarch,:mips64$(MIPS_EL)

Re: RFC [MIPS, RS6000] Mangling of IBM long double template literals

2013-06-12 Thread Joseph S. Myers
On Thu, 13 Jun 2013, Alan Modra wrote: > This is of course an ABI change for any existing little-endian users > of IBM long double literals in templates. On powerpc, I think we can > safely say there are no such users. However it does look like MIPS > also uses a variant of IBM long double, and

RE: [PATCH] Cilk Plus Array Notation for C++

2013-06-12 Thread Iyer, Balaji V
> -Original Message- > From: Aldy Hernandez [mailto:al...@redhat.com] > Sent: Wednesday, June 12, 2013 1:40 PM > To: Iyer, Balaji V > Cc: gcc-patches@gcc.gnu.org; Jason Merrill (ja...@redhat.com); > r...@redhat.com > Subject: Re: [PATCH] Cilk Plus Array Notation for C++ > > > >> Overall

Re: Remove self-assignments

2013-06-12 Thread Marc Glisse
On Wed, 12 Jun 2013, Richard Biener wrote: On Wed, Jun 12, 2013 at 10:47 AM, Marc Glisse wrote: Essentially never. I tried with the fold_stmt version of the patch, and libstdc++-v3/src/c++98/concept-inst.cc is the only file where it triggers. Note that the case: b=*a *a=b is already handled b

Re: [PATCH] DATA_ALIGNMENT vs. DATA_ABI_ALIGNMENT (PR target/56564)

2013-06-12 Thread Edmar Wienskoski
The e500v2 (SPE) hardware is such that if the address of vector (double world load / stores) are not double world aligned the instruction will trap. So this alignment is not optional. Edmar On Fri, Jun 7, 2013 at 3:43 PM, Richard Henderson wrote: > On 06/07/2013 12:25 PM, Jakub Jelinek wrote:

Re: [C++ Path] PR 38958

2013-06-12 Thread Jason Merrill
On 06/12/2013 01:37 PM, Paolo Carlini wrote: Rewording: as the one line comment says, I only call non_reference at the outset when I know that either we'll end up producing the normal unused-variable warning or nothing at all. Oh, I see. But that's a rather subtle difference; better to have

Re: [PATCH] Cilk Plus Array Notation for C++

2013-06-12 Thread Aldy Hernandez
Overall, a lot of the stuff in cp-array-notation.c looks familiar from the C front- end changes. Can't you reuse a lot of it? I looked into trying to combine many functionality. The issue that prohibited me was templates and extra trees. For example, IF_STMT, FOR_STMT, MODOP_EXPR, etc are not

Re: [C++ Path] PR 38958

2013-06-12 Thread Paolo Carlini
Humpf, >I understand the general issue, but I'm not sure we can't use 'type' >here: we don't even consider emitting the unused-but-set warning when >TREE_USED (decl) is false and in this case I don't call non_reference >at the outset. I meant *only* in this case I call non_reference, you see my

Re: [gomp4] Some progress on #pragma omp simd

2013-06-12 Thread Richard Henderson
On 06/12/2013 10:30 AM, Jakub Jelinek wrote: > So the built-ins would take address of this decl, something else? Perhaps address, perhaps just referenced uninitialized? > Then there is the _simduid_ clause (also can hold address of the decl), and > after lowering it lives only in loop structure (

Re: [gomp4] Some progress on #pragma omp simd

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 10:21:53AM -0700, Richard Henderson wrote: > On 04/27/2013 11:17 AM, Jakub Jelinek wrote: > > where simd_uid would be some say integer constant, unique to the simd loop > > (at least unique within the same function, and perhaps inlining/LTO would > > need to remap). > > If

Re: [C++ Path] PR 38958

2013-06-12 Thread Paolo Carlini
Hi, Jason Merrill ha scritto: >On 06/12/2013 11:58 AM, Paolo Carlini wrote: >> - && TREE_CODE (TREE_TYPE (decl)) != REFERENCE_TYPE >> + && TREE_CODE (type) != REFERENCE_TYPE > >This change is wrong; we specifically want to suppress the >unused-but-set warning fo

[PATCH] for for c/PR57541

2013-06-12 Thread Iyer, Balaji V
Hello Everyone, Attach, please find a patch that will fix the issues in C/PR57541. The issue reported was that the parameters passed into the builtin array notation reduction functions were not checked correctly. This patch should fix that issue. It is tested on x86 and x86_64 and it see

Re: [gomp4] Some progress on #pragma omp simd

2013-06-12 Thread Richard Henderson
On 04/27/2013 11:17 AM, Jakub Jelinek wrote: > where simd_uid would be some say integer constant, unique to the simd loop > (at least unique within the same function, and perhaps inlining/LTO would > need to remap). If all we need is uniqueness, then perhaps an otherwise unused decl would do? We'r

RE: [PATCH] Cilk Plus Array Notation for C++

2013-06-12 Thread Iyer, Balaji V
Hi Aldy, Below are my responses to a couple of the things you pointed out. Thanks, Balaji V. Iyer. > -Original Message- > From: Aldy Hernandez [mailto:al...@redhat.com] > Sent: Wednesday, June 12, 2013 12:34 PM > To: Iyer, Balaji V > Cc: gcc-patches@gcc.gnu.org; Jason Merrill (ja

[PATCH][ARM][testsuite] Add 'dg-require-effective-target sync_*' to some atomic tests

2013-06-12 Thread Meador Inge
Hi All, This patch adds the needed 'dg-require-effective-target sync_*' lines to some of the atomic tests so that they will not be run if the appropriate atomic support is not available. OK for trunk? 2013-06-12 Meador Inge * gcc.dg/atomic-flag.c: Add dg-require-effective-target sync

Re: [C++ Path] PR 38958

2013-06-12 Thread Jason Merrill
On 06/12/2013 11:58 AM, Paolo Carlini wrote: -&& TREE_CODE (TREE_TYPE (decl)) != REFERENCE_TYPE +&& TREE_CODE (type) != REFERENCE_TYPE This change is wrong; we specifically want to suppress the unused-but-set warning for reference variables. Drop it and

Re: [c++-concepts] code review

2013-06-12 Thread Jason Merrill
On 06/12/2013 11:53 AM, Gabriel Dos Reis wrote: I am still surprised though that we don't generate TEMPLATE_DECLs for partial instantiations (since they are still morally templates.) Yes, we should. Jason

Re: [PATCH] Cilk Plus Array Notation for C++

2013-06-12 Thread Aldy Hernandez
[Jason/Richard: there are some things below I could use your feedback on.] Hi Balaji. Overall, a lot of the stuff in cp-array-notation.c looks familiar from the C front-end changes. Can't you reuse a lot of it? Otherwise, here are some minor nits... + /* If the function call is builti

Re: Improve uncprop and coalescing

2013-06-12 Thread Jeff Law
On 06/07/13 03:14, Richard Biener wrote: +/* Given SSA_NAMEs NAME1 and NAME2, return true if they are candidates for + coalescing together, false otherwise. + + This must stay consistent with the code in tree-ssa-live.c which + sets up base values in the var map. */ + +bool +gimple_can_c

[C++ Path] PR 38958

2013-06-12 Thread Paolo Carlini
Hi, this bug is a sort of follow up to 10416, which I fixed some time ago and was about avoiding -Wunused warnings for class types with destructors with side-effects. In this issue reporter notes that we don't handle in the same way references, thus, considering the testcase, we do not warn

Re: [Patch, Fortran] Print floating-point exception status after STOP/ERROR STOP

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 03:05:30PM +0200, Tobias Burnus wrote: > --- a/libgfortran/runtime/stop.c > +++ b/libgfortran/runtime/stop.c > @@ -32,6 +32,37 @@ see the files COPYING3 and COPYING.RUNTIME respectively. > If not, see > #endif > > > +/* Fortran 2008 demands: If any exception (14) is s

Re: C++ PATCH to warn about undefined functions in anonymous namespace

2013-06-12 Thread Gabriel Dos Reis
On Mon, Jun 10, 2013 at 2:37 PM, Jason Merrill wrote: > Since members of the anonymous namespace can't be defined in another > translation unit, we should treat them like statics for diagnostic purposes. > > Tested x86_64-pc-linux-gnu, applying to trunk. Thank you! -- Gaby

Re: [c++-concepts] code review

2013-06-12 Thread Gabriel Dos Reis
On Mon, Jun 10, 2013 at 2:30 PM, Jason Merrill wrote: > On 06/08/2013 09:34 AM, Andrew Sutton wrote: >> >> I think I previously put constraint_info in lang_decl_min, right next >> to template_info no less. It was easy to manage there, and initialized >> as part of build_template_decl. But this obv

Re: [Patch, Fortran] Print floating-point exception status after STOP/ERROR STOP

2013-06-12 Thread Tobias Burnus
Updated version: * Uros suggestions are incorporated * Changed from -f(no-)underflow-warning to -ffpe-summary=[none,all,underflow,...] Tobias Burnus wrote: David: Can you have a look at libgfortran/config/fpu-aix.h - Thanks! The attached patch causes gfortran-compiled programs to print warnin

Re: Remove self-assignments

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 09:42:55AM -0600, Jeff Law wrote: > On 06/12/13 02:03, Richard Biener wrote: > >DSE looks like the right place to me as we are removing a store. Yes, > >DCE removes a limited set of stores as well, but the way we remove this kind > >of store makes it much more suited to DSE

Re: [RFC] Implement Undefined Behavior Sanitizer (take 2)

2013-06-12 Thread Marek Polacek
On Wed, Jun 12, 2013 at 05:29:21PM +0200, Jakub Jelinek wrote: > > @@ -4070,8 +4081,12 @@ cp_build_binary_op (location_t location, > > { > > enum tree_code tcode0 = code0, tcode1 = code1; > > tree cop1 = fold_non_dependent_expr_sfinae (op1, tf_none); > > + cop1 = maybe_constant_

Re: [Patch, Fortran] Print floating-point exception status after STOP/ERROR STOP

2013-06-12 Thread David Edelsohn
On Wed, Jun 12, 2013 at 9:05 AM, Tobias Burnus wrote: > David: Can you have a look at libgfortran/config/fpu-aix.h - Thanks! > Uros: Can you have a look at libgfortran/config/fpu-387.h - Thanks! The AIX bits look correct. Thanks very much for investigating AIX support. Thanks, David

Re: Remove self-assignments

2013-06-12 Thread Jeff Law
On 06/11/13 13:30, Marc Glisse wrote: I'd be curious how often this triggers in GCC itself as well. Do you know a convenient way to test that? I usually put in some kind of debugging printfs during early development which I can then grep for in build logs. Not very sexy, but effective to

Re: Remove self-assignments

2013-06-12 Thread Jeff Law
On 06/12/13 02:03, Richard Biener wrote: DSE looks like the right place to me as we are removing a store. Yes, DCE removes a limited set of stores as well, but the way we remove this kind of store makes it much more suited to DSE. As of possibly trapping/throwing stores, we do not bother to pr

Re: [RS6000] IBM long double little-endian

2013-06-12 Thread David Edelsohn
What is your model for the way that the RTL and C statements in the new signbittf2 pattern interact? The C preparation statements are executed before the RTL code generated from the RTL template. In the patch, it seems that the new pattern is assuming that it can rely on some results produced by

Re: [RFC] Implement Undefined Behavior Sanitizer (take 2)

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 05:17:45PM +0200, Marek Polacek wrote: > @@ -3867,6 +3868,7 @@ cp_build_binary_op (location_t location, >tree final_type = 0; > >tree result; > + tree orig_type = NULL; > >/* Nonzero if this is an operation like MIN or MAX which can > safely be compute

[RFC] Inconsistency in ordering vector widening operations on big-endian targets?

2013-06-12 Thread Tejas Belagod
Hi, This test case: void foo(long long *d, int *f) { int i; for (i=0; i< 16; i++) { d[i] = f[i]; } } when vectorized for big-endian mode, generates this sequence of widening operations: ... _33 = (void *) ivtmp.22_25; vect__11.5_39 = MEM[base: _33, offset: 0B]; vect__12.6_

Re: [RS6000] IBM long double little-endian

2013-06-12 Thread Alan Modra
On Wed, Jun 12, 2013 at 11:09:03AM -0400, David Edelsohn wrote: > On Wed, Jun 12, 2013 at 10:53 AM, Alan Modra wrote: > > > * config/rs6000/rs6000.h (LONG_DOUBLE_LARGE_FIRST): Define. > > * config/rs6000/rs6000.md (signbittf2): New insn. > > (extenddftf2_internal): Use LON

Re: [RFC] Implement Undefined Behavior Sanitizer (take 2)

2013-06-12 Thread Marek Polacek
On Wed, Jun 12, 2013 at 03:52:08PM +0200, Jakub Jelinek wrote: > No, you really need to use the cp_save_expr/c_save_expr, especially for > C it e.g. fully folds etc. You want to call that in > cp_build_binary_op etc., also because you want both the instrument_expr > itself, but also the original b

RFC [MIPS, RS6000] Mangling of IBM long double template literals

2013-06-12 Thread Alan Modra
As noted in the comment below, IBM long double is really an array of two doubles. In little-endian mode this means the words of each double should be reversed in write_real_cst, but the large magnitude double remains the first element of the array. This patch specially treats IBM long double so t

Re: [RS6000] IBM long double little-endian

2013-06-12 Thread David Edelsohn
On Wed, Jun 12, 2013 at 10:53 AM, Alan Modra wrote: > * config/rs6000/rs6000.h (LONG_DOUBLE_LARGE_FIRST): Define. > * config/rs6000/rs6000.md (signbittf2): New insn. > (extenddftf2_internal): Use LONG_DOUBLE_LARGE_FIRST. > (abstf2_internal, cmptf_internal2): Likewi

[RS6000] IBM long double little-endian

2013-06-12 Thread Alan Modra
FLOAT_WORDS_BIG_ENDIAN doesn't work out too well for IBM extended double when little-endian, because we're thinking to keep the large magnitude double first. See the comment below on LONG_DOUBLE_LARGE_FIRST. This patch fixes all occurrences of FLOAT_WORDS_BIG_ENDIAN in the rs6000 backend (all of

[Patch ARM] Fix some testsuite fallout with DATA_ABI_ALIGNMENT changes.

2013-06-12 Thread Ramana Radhakrishnan
Hi, This fixes up some of the fallout in the testsuite for ARM with the DATA_ABI_ALIGNMENT changes recently. Applied to trunk. regards Ramana 2013-06-12 Ramana Radhakrishnan * gcc.target/arm/unaligned-memcpy-4.c (src, dst): Initialize to ensure alignment. * gcc.t

Fix verifier for duplicated decls during sreaming

2013-06-12 Thread Jan Hubicka
Hi, verifier needs update to tolerate duplicated nodes for a decl during LTO streaming state. Bootstrapped/regtested x86_64-linux, comitted. Honza * cgraph.c (verify_edge_corresponds_to_fndecl): Be lax about decl has when in streaming stage. * lto-symtab.c (lto_symtab_me

Re: [C++ Patch] PR 42021

2013-06-12 Thread Paolo Carlini
On 06/12/2013 04:05 PM, Paolo Carlini wrote: On 06/12/2013 03:38 PM, Jason Merrill wrote: OK, but please add a comment. Thanks. I added this: // cp_parser_lookup_name has the same diagnostic, // thus make sure to emit it almost once. As mentioned by Marc off-line,

[patch] set MULTIARCH_DIRNAME for multilib architectures

2013-06-12 Thread Matthias Klose
[CCing port maintainers] Currently the MULTIARCH_DIRNAME is not correctly set for the x86_64-kfreebsd-gnu target, and is not set at all for architectures which do have multilib configurations by default. This patch makes sure that MULTIARCH_DIRNAME is always set to the default multilib configurat

Re: [C++ Patch] PR 42021

2013-06-12 Thread Paolo Carlini
On 06/12/2013 03:38 PM, Jason Merrill wrote: OK, but please add a comment. Thanks. I added this: // cp_parser_lookup_name has the same diagnostic, // thus make sure to emit it almost once. Paolo.

Re: [Patch, Fortran] Print floating-point exception status after STOP/ERROR STOP

2013-06-12 Thread Uros Bizjak
On Wed, Jun 12, 2013 at 3:05 PM, Tobias Burnus wrote: > David: Can you have a look at libgfortran/config/fpu-aix.h - Thanks! > Uros: Can you have a look at libgfortran/config/fpu-387.h - Thanks! > + unsigned short cw; + + __asm__ ("fnstsw %0" : "=a" (cw)); __asm__ __volatile__ ("fnstsw\t%0" :

Re: SPE detection broken on Linux (bits/predefs.h: No such file or directory)

2013-06-12 Thread Matthias Klose
Am 12.06.2013 13:05, schrieb Olivier Hainque: > > On Jun 11, 2013, at 16:50 , David Edelsohn wrote: >>> I solved this in gcc/config/rs6000/t-linux by replacing the line >>> >>> MULTIARCH_DIRNAME = powerpc-linux-gnuspe$(if $(findstring >>> rs6000/e500-double.h, $(tm_file_list)),,v1) >>> >>> with >

Re: [RFC] Implement Undefined Behavior Sanitizer (take 2)

2013-06-12 Thread Jakub Jelinek
On Wed, Jun 12, 2013 at 03:48:24PM +0200, Marek Polacek wrote: > On Tue, Jun 11, 2013 at 10:44:12PM +0200, Jakub Jelinek wrote: > > There is another thing to solve BTW, op0 and/or op1 might have side-effects, > > if you are going to evaluate them more than once, they need to be surrounded > > into

Re: [RFC] Implement Undefined Behavior Sanitizer (take 2)

2013-06-12 Thread Marek Polacek
On Tue, Jun 11, 2013 at 10:44:12PM +0200, Jakub Jelinek wrote: > There is another thing to solve BTW, op0 and/or op1 might have side-effects, > if you are going to evaluate them more than once, they need to be surrounded > into cp_save_expr resp. c_save_expr. There's that unpleasant thing that cp_

Re: [C++ Patch] PR 42021

2013-06-12 Thread Jason Merrill
OK, but please add a comment. Jason

Re: *PING* / Re: [Patch, Fortran] Finalize nonallocatables with INTENT(out)

2013-06-12 Thread Tobias Burnus
Tobias Burnus wrote: Dominique Dhumieres wrote: I have tried to weaken the test by not using any target and using a regexp of the kind "(int|long)", but I did not succeeded. Ups, I missed that Dominique's and Andreas' 32bit dumps are different ("unsigned int" vs. "character(kind=4)"). Thus,

Re: *PING* / Re: [Patch, Fortran] Finalize nonallocatables with INTENT(out)

2013-06-12 Thread Tobias Burnus
Thanks Dominique and Andreas for reporting this issue. Dominique Dhumieres wrote: The test gfortran.dg/finalize_10.f90 fails in 32 bit mode [...] The following patch fixes it [...] I have tried to weaken the test by not using any target and using a regexp of the kind "(int|long)", but I did

[gomp4] Small OpenMP 4.0 post-RC2 tweaks

2013-06-12 Thread Jakub Jelinek
Hi! 1) reference types in map/to/from clauses are supposed to map/copy what those references refer to, so the reference var itself doesn't need to be addressable. We'll need to remap the reference variable to a new reference that will refer to the corresponding device object. 2) the spec now allo

[Patch, Fortran] Print floating-point exception status after STOP/ERROR STOP

2013-06-12 Thread Tobias Burnus
David: Can you have a look at libgfortran/config/fpu-aix.h - Thanks! Uros: Can you have a look at libgfortran/config/fpu-387.h - Thanks! The attached patch causes gfortran-compiled programs to print warnings like Note: The following floating-point status flag is signalling: IEEE_DIVIDE_BY_ZERO

[gomp4] Introduce thread_limit clause

2013-06-12 Thread Jakub Jelinek
Hi! The num_threads clause on the #pragma omp teams construct has been replaced with a new thread_limit clause. Changed for C++ FE thusly: 2013-06-12 Jakub Jelinek * gimplify.c (gimplify_scan_omp_clauses): Handle OMP_CLAUSE_THREAD_LIMIT. * tree-pretty-print.c (dump_om

[PATCH] Limit LTO output block-size

2013-06-12 Thread Richard Biener
This limits the block-size granularity we use for increasing the output buffer for LTO to 2MB. Previously it grows exponentially and unlimited. I've increased the first block-size to 4096 bytes from 1024 as well. Any comments on the particular limit? Not sure if we could even optimize away the

[PATCH, trunk, PR57358] Avoid IPA-CP analysis if attribute optimize precludes it

2013-06-12 Thread Martin Jambor
Hi, this is how I would like to fix the ICE when analyzing a function with attribute optimize on trunk. Inlining, the other user of the analysis, is already smart enough not to analyze such functions, so this teaches IPA-CP to do the same thing. Consequently, functions witrh attribute optimize(O

  1   2   >