Re: [Patch] Adjust diag-scans in vect-tests to fix fails on AVX/AVX2

2011-12-21 Thread Michael Zolotukhin
Thanks! Yes, those xpasses were introduced by the changes in dg-scans I recently made, but I'm not sure if there is an error in them: in these three tests compiler for some reason assume that arrays are aligned to 16 byte even in 32-bit mode (AFAIK, ABI requirement for arrays alignment is alignment

RE: PING: [PATCH, ARM, iWMMXt][5/5]: pipeline description

2011-12-21 Thread Xinyu Qi
At 2011-10-20 20:36:53,"Ramana Radhakrishnan" wrote: > On 20 October 2011 08:42, Xinyu Qi wrote: > > Ping > > > > http://gcc.gnu.org/ml/gcc-patches/2011-07/msg01106.html > > Index: gcc/config/arm/marvell-f-iwmmxt.md > > > > === >

RE: PING: [PATCH, ARM, iWMMXt][3/5]: built in define and expand

2011-12-21 Thread Xinyu Qi
At 2011-11-24 09:27:04,"Xinyu Qi" wrote: > At 2011-11-19 07:08:22,"Ramana Radhakrishnan" > wrote: > > On 20 October 2011 08:39, Xinyu Qi wrote: > > > Ping > > > > > > http://gcc.gnu.org/ml/gcc-patches/2011-07/msg01103.html > > > > > >        * config/arm/arm.c (enum arm_builtins): Revise built

RE: PING: [PATCH, ARM, iWMMXt][4/5]: WMMX machine description

2011-12-21 Thread Xinyu Qi
At 2011-12-15 01:32:13,"Richard Earnshaw" wrote: > On 24/11/11 01:33, Xinyu Qi wrote: > > Hi Ramana, > > > > I solve the conflict, please try again. The new diff is attached. > > > > Thanks, > > Xinyu > > > > At 2011-11-19 07:36:15,"Ramana Radhakrishnan" > wrote: > >> > >> Hi Xinyu, > >> > >> Thi

RE: [PATCH, ARM, iWMMXt][1/5]: ARM code generic change

2011-12-21 Thread Xinyu Qi
At 2011-12-15 00:47:48,"Richard Earnshaw" wrote: > On 14/07/11 08:35, Xinyu Qi wrote: > >>> Hi, > >>> > >>> It is the first part of iWMMXt maintenance. > >>> > >>> *config/arm/arm.c (arm_option_override): > >>> Enable iWMMXt with VFP. iWMMXt and NEON are incompatible. > >> iWMMXt unsupported un

gcov-io.h type typo

2011-12-21 Thread DJ Delorie
This field is built as a gcov_unsigned_t but declared as a plain "unsigned", which breaks all int16 targets: /* n_functions */ field = build_decl (BUILTINS_LOCATION, FIELD_DECL, NULL_TREE, get_gcov_unsigned_t ()); DECL_CHAIN (field) = fields; fields = field; Assumin

[PATCH] PR33919/preprocessor fix __BASE_FILE__ when included from the command line

2011-12-21 Thread Gary Funck
Attached is a suggested fix for a long-standing C pre-processor bug. Ref: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=33919 Ref: http://gcc.gnu.org/ml/gcc/2004-10/msg00534.html The patch implements the approach suggested by Harald van Dijk in the cited bug report. I am not familiar with the subt

[RFC / Patch] PR 51494

2011-12-21 Thread Paolo Carlini
Hi, the issue is that we are rejecting: struct A { static void f() {} void foo() { [] () { f(); }; } }; because 'this' is not captured, but we are wrong because f is static. The problem happens in maybe_dummy_object (called from finish_call_expr) because it cannot kn

[PATCH RFA] tree-optimization/PR43491, Unnecessary temporary for global register variable

2011-12-21 Thread Bin Cheng
Hi, This patch fixes the bug PR43491, which exists at least on arm-none-eabi/mips-elf targets. The cause is ssa-pre eliminates global register variable when it is the RHS of single assign statment, while following passes do not handle the const/register attributes of the variable. This patch ski

Go patch committed: Rework range over slice

2011-12-21 Thread Ian Lance Taylor
This patch to the Go frontend reworks the range over slice support so that the index operation does not normally require a bounds check. I did this by the simple expedient of copying the slice to a temporary variable before doing the range. This makes it safe for the optimizers to eliminate the b

Re: adjust installation docs to discourage installing GMP, MPFR and MPC separately

2011-12-21 Thread Jonathan Wakely
On 22 December 2011 00:36, Joseph S. Myers wrote: > On Thu, 22 Dec 2011, Jonathan Wakely wrote: > >> It is almost always caused by installing libgmp.so etc. in a >> non-standard location and not using ldconfig, DT_RUNPATH, >> $LD_LIBRARY_PATH or some other method to tell the dynamic linker how >> t

Re: adjust installation docs to discourage installing GMP, MPFR and MPC separately

2011-12-21 Thread Joseph S. Myers
On Thu, 22 Dec 2011, Jonathan Wakely wrote: > It is almost always caused by installing libgmp.so etc. in a > non-standard location and not using ldconfig, DT_RUNPATH, > $LD_LIBRARY_PATH or some other method to tell the dynamic linker how > to find them. The current installation docs mention --wit

adjust installation docs to discourage installing GMP, MPFR and MPC separately

2011-12-21 Thread Jonathan Wakely
The most frequently asked question on gcc-help, and a frequently reported "bug" in bugzilla, is http://gcc.gnu.org/wiki/FAQ#configure_suffix It is almost always caused by installing libgmp.so etc. in a non-standard location and not using ldconfig, DT_RUNPATH, $LD_LIBRARY_PATH or some other method

[google] fix ICE when using LIPO profiles for FDO (issue5500068)

2011-12-21 Thread Rong Xu
This patch is for google_main branch only. This patch fixes the ICE when using LIPO profiles for regular FDO compilation. LIPO has INDIR_CALL_TOPN profiles while FDO has INDIR_CALL profile. Tested with SPEC2000 INT (with -Wno-coverage-mismatch to work around the minor pass difference b/w LIPO and

Re: libgcc patch committed: Improve calling non-split-stack code

2011-12-21 Thread Ian Lance Taylor
Richard Henderson writes: > On 12/20/2011 03:07 PM, Ian Lance Taylor wrote: >> __morestack_non_split: >> +.cfi_startproc >> >> #ifndef __x86_64__ >> -addl$0x4000,4(%esp) >> + >> +# See below for an extended explanation of the CFI instructions. >> +.cfi_offset 8, 8

Re: [PATCH][Cilkplus] Array notations as a Condition for If and switch statements

2011-12-21 Thread Andi Kleen
"Iyer, Balaji V" writes: > new file mode 100644 > index 000..833379b > --- /dev/null > +++ b/gcc/testsuite/gcc.dg/cilk-plus/array_notation_tests/if_test.c > @@ -0,0 +1,162 @@ > +#include > + > +int main (int argc, char **argv) > +{ > + int x = 3, y, z, array[10], array2[10], TwodArray[10][10

Re: libgo patch committed: Catch signals on alternate stack

2011-12-21 Thread Ian Lance Taylor
Richard Henderson writes: > On 12/21/2011 02:29 PM, Ian Lance Taylor wrote: >> +/* Ignore a signal. This is called on the alternate signal stack so >> + it may not split the stack. */ >> + >> +static void sig_ignore (int) __attribute__ ((no_split_stack)); >> >> static void >> sig_ignore (

Re: [patch committed SH] Add atomic patterns

2011-12-21 Thread Kaz Kojima
Oleg Endo wrote: > 2011-12-21 Oleg Endo > > * config/sh/sync.md: Add soft atomics ABI description. > (fetchop_name): Use 'or' instead of 'ior'. > (fetchop_insn): Remove. > (atomic_compare_and_swap_soft): > Don't insert aligning nop after the write-back instructi

Re: libgo patch committed: Catch signals on alternate stack

2011-12-21 Thread Richard Henderson
On 12/21/2011 02:29 PM, Ian Lance Taylor wrote: > +/* Ignore a signal. This is called on the alternate signal stack so > + it may not split the stack. */ > + > +static void sig_ignore (int) __attribute__ ((no_split_stack)); > > static void > sig_ignore (int sig __attribute__ ((unused))) >

[PATCH][Cilkplus] Array notations as a Condition for If and switch statements

2011-12-21 Thread Iyer, Balaji V
Hello Everyone, These patches are for the C-Compiler in Cilkplus branch. It is an extension to the patch given in submission: http://gcc.gnu.org/ml/gcc-patches/2011-12/msg01473.html. The first patch will handle cases where array notations are used as condition for if-then-else and switch st

libgo patch committed: Catch signals on alternate stack

2011-12-21 Thread Ian Lance Taylor
This patch to libgo catches most signals on the alternate signal stack. The only ones caught on the normal stack are the ones which can occur synchronously: SIGSEGV, SIGBUS, SIGFPE. While updating the signal code I also used SA_SIGINFO to distinguish expected signals (null dereferences, division b

Re: Add -std=c11 option, final __STDC_VERSION__ value, etc.

2011-12-21 Thread Joseph S. Myers
I've now made corresponding updates to the 4.7 release notes. Index: changes.html === RCS file: /cvs/gcc/wwwdocs/htdocs/gcc-4.7/changes.html,v retrieving revision 1.69 diff -u -r1.69 changes.html --- changes.html12 Dec 2011 15

Re: [Patch, fortran] Would this patch - applied to trunk - be OK for the 4.6 branch ?

2011-12-21 Thread Steve Kargl
On Mon, Dec 19, 2011 at 06:54:08PM +0100, Toon Moene wrote: > The attached patch makes -finit-= generate default > initialization for automatic arrays. > > It was OK for the trunk - is it also OK for the 4.6 branch ? > > Strictly speaking, it doesn't fix a regression, it is a fix for a > (non-d

Fix PR target/51552

2011-12-21 Thread Richard Henderson
As I say in the pr, this is partially a bfin backend bug. But as it is also a debug/eh_frame size regression for all targets, I'm fixing it anyway. This has the side-effect of re-hiding the bfin backend bug and allowing the build to finish for bfin-rtems. For x86_64, cc1: before: .eh_frame

Re: [Patch, libfortran] PR 51646 Use POSIX mode flags

2011-12-21 Thread Paul Richard Thomas
Dear All, I would put Mike Long up with the people that climb the likes of K2! A remarkable achievement that is nearly but not quite completely useless. I hope that teh view made up fo it On the other hand, he helped us out :-) Cheers Paul On Wed, Dec 21, 2011 at 5:14 PM, Tobias Burnus w

Re: [Patch] Adjust diag-scans in vect-tests to fix fails on AVX/AVX2

2011-12-21 Thread Uros Bizjak
On Mon, Dec 19, 2011 at 9:47 AM, Michael Zolotukhin wrote: >> What do you mean no tests require it?  For instance, all of the ones >> that currently pass with with vect_perm? > Current implementation of vect_perm doesn't check for SSSE3 - so any > x86 target is supposed to support permutation. > >

[PATCH, i386]: Enable flag_ree also on 32bit targets

2011-12-21 Thread Uros Bizjak
Hello! As shown by pr50038.c testcase, recent redundant extension insns improvements also benefit 32bit targets. Attached patch enables this pass for all x86 targets. The patch also moves the testcase to better place. 2011-12-21 Uros Bizjak * config/i386/i386.c (ix86_option_override_

Re: [PATCH, SMS] Prevent the creation of reg-moves for definitions with MODE_CC

2011-12-21 Thread Richard Henderson
On 12/20/2011 09:47 AM, Richard Sandiford wrote: > Revital Eres writes: >> +/* Return true if one of the definitions in INSN has MODE_CC. Otherwise >> + return false. */ >> +static bool >> +def_has_ccmode_p (rtx insn) >> +{ >> + df_ref *def; >> + >> + for (def = DF_INSN_DEFS (insn); *def; de

Re: Ping^2: Add a prepare_pch_save target hook (fix many MIPS16 PCH failures)

2011-12-21 Thread Richard Henderson
On 12/20/2011 01:44 PM, Richard Sandiford wrote: > Ping for this patch to add a prepare_pch_save target hook: > > http://gcc.gnu.org/ml/gcc-patches/2011-12/msg00273.html > > It fixes many PCH failures for MIPS16 (which are a regression from > earlier releases). Ok. r~

C++ PATCH for c++/51611 (conversion to vbase in NSDMI)

2011-12-21 Thread Jason Merrill
We handled use of 'this' in an NSDMI, but conversion to a virtual base still broke because it depends on having a function context set up. This patch fixes this problem by not building such conversions until we use the NSDMI in an actual constructor. Tested x86_64-pc-linux-gnu, applying to tru

PATCH to doc/standards.texi for C++11

2011-12-21 Thread Jason Merrill
Joseph pointed out that when I changed most places to talk about C++11 instead of C++0x, I missed standards.texi. So this patch remedies that oversight. Applying to trunk. commit ae87efaee9300b831ef609b88b4c813248dd0a2f Author: Jason Merrill Date: Wed Dec 21 10:54:04 2011 -0500 * doc/

Re: Add an extra reload dump file

2011-12-21 Thread Richard Henderson
On 12/21/2011 10:48 AM, Bernd Schmidt wrote: > * tree-pass.h (pass_reload): Declare. > * ira.c (overall_cost_before, saved_flag_ira_share_spill_slots): > New global variables, moved out of ira. > (do_reload): New static function, split off from the second half > of ...

Re: libgcc patch committed: Improve calling non-split-stack code

2011-12-21 Thread Richard Henderson
On 12/20/2011 03:07 PM, Ian Lance Taylor wrote: > __morestack_non_split: > + .cfi_startproc > > #ifndef __x86_64__ > - addl$0x4000,4(%esp) > + > + # See below for an extended explanation of the CFI instructions. > + .cfi_offset 8, 8# New PC stored at CFA + 8

Re: Possible wrong-way example in gcc4-4-2 documentation of __builtin_expect

2011-12-21 Thread Ian Lance Taylor
Jonathan Wakely writes: > In order to follow the GCC coding style (a space between the function > name and opening parenthesis) and to match the first example for > __builtin_expect, I propose this patch instead: > > Index: extend.texi > ===

Add an extra reload dump file

2011-12-21 Thread Bernd Schmidt
IRA can make quite a lot of changes to the RTL, but the debugging dumps are not very helpful as the .ira dump is produced after reload has run. The patch below splits off reload into its own pass so that we get two separate dump files. This makes debugging certain classes of problems a lot easier.

Re: [patch]: ia64 - allow VMS to redefine TARGET_PROMOTE_FUNCTION_MODE

2011-12-21 Thread Richard Henderson
On 12/21/2011 02:49 AM, Tristan Gingold wrote: > * config/ia64/ia64.c (TARGET_PROMOTE_FUNCTION_MODE): Move to... > * config/ia64/ia64.h (TARGET_PROMOTE_FUNCTION_MODE): ... Here. > * config/ia64/vms.h (TARGET_PROMOTE_FUNCTION_MODE): Override. Again, the true default definition in

Re: [patch] Fix libstdc++/51626

2011-12-21 Thread Jonathan Wakely
On 19 December 2011 22:39, Jonathan Wakely wrote: > We don't have allocator_traits in 4.6 so this patch adds a test for > whether we can call allocator::construct(p) with a single argument and > calls _Construct(p) if not. > >        PR libstdc++/51626 >        * include/bits/stl_uninitialized.h (_

Re: Possible wrong-way example in gcc4-4-2 documentation of __builtin_expect

2011-12-21 Thread Jonathan Wakely
On 21 December 2011 18:03, Jonathan Wakely wrote: > On 21 December 2011 02:00, Jim Avera wrote: >> Ok, here is a patch which improves the example: >> >> --- gcc/doc/extend.texi.ORIG    2011-12-20 17:35:32.236578828 -0800 >> +++ gcc/doc/extend.texi    2011-12-20 17:37:10.460583316 -0800 >> @@ -7932,

Re: Possible wrong-way example in gcc4-4-2 documentation of __builtin_expect

2011-12-21 Thread Jonathan Wakely
On 21 December 2011 02:00, Jim Avera wrote: > Ok, here is a patch which improves the example: > > --- gcc/doc/extend.texi.ORIG    2011-12-20 17:35:32.236578828 -0800 > +++ gcc/doc/extend.texi    2011-12-20 17:37:10.460583316 -0800 > @@ -7932,7 +7932,7 @@ > >  @smallexample >  if (__builtin_expect (

[PATCH 06/10] mips: Improve support for vec_init.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/loongson.md | 26 + gcc/config/mips/mips-ps-3d.md | 14 +-- gcc/config/mips/mips.c| 226 - 3 files changed, 233 insertions(+), 33 deletions(-) diff --git a/gcc/config/mips/loongson.md b/gcc/config/mips/loongson.md inde

[PATCH 09/10] mips: Add reduction support for Loongson.

2011-12-21 Thread Richard Henderson
Both plus and min/max. --- gcc/config/mips/loongson.md | 230 + gcc/config/mips/mips-protos.h |3 + gcc/config/mips/mips.c| 77 ++ 3 files changed, 290 insertions(+), 20 deletions(-) diff --git a/gcc/config/mips/loongson.md b/gc

[PATCH 05/10] mips: Support vec_unpack[su] for Loongson.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/loongson.md | 36 gcc/config/mips/mips-protos.h |1 + gcc/config/mips/mips.c| 45 + 3 files changed, 82 insertions(+), 0 deletions(-) diff --git a/gcc/config/mips/loongson.md b/gcc/confi

[PATCH 07/10] mips: Fix some insn types for Loongson.

2011-12-21 Thread Richard Henderson
Tables 63 and 64 show the multimedia insn and the fpu insn on which it is mapped. The last bullet of 12.1 explicitly says that this is meaningful for looking up the latency in Table 61. --- gcc/config/mips/loongson.md | 16 1 files changed, 8 insertions(+), 8 deletions(-) diff

[PATCH 08/10] mips: Add sdot_prodv4hi for Loongson.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/loongson.md | 25 +++-- 1 files changed, 19 insertions(+), 6 deletions(-) diff --git a/gcc/config/mips/loongson.md b/gcc/config/mips/loongson.md index 8743984..e9fa616 100644 --- a/gcc/config/mips/loongson.md +++ b/gcc/config/mips/loongson.md @@ -381,15 +

[PATCH 10/10] mips: Add reduction patterns for paired-single

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/mips-ps-3d.md | 26 ++ 1 files changed, 26 insertions(+), 0 deletions(-) diff --git a/gcc/config/mips/mips-ps-3d.md b/gcc/config/mips/mips-ps-3d.md index 7c3fe85..cc8a4c0 100644 --- a/gcc/config/mips/mips-ps-3d.md +++ b/gcc/config/mips/mips-ps-3d.md @

[PATCH 04/10] mips: Support even-odd permutation for Loongson V8QImode.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/mips.c | 59 1 files changed, 59 insertions(+), 0 deletions(-) diff --git a/gcc/config/mips/mips.c b/gcc/config/mips/mips.c index a1f06d4..0ac1096 100644 --- a/gcc/config/mips/mips.c +++ b/gcc/config/mips/mips.c @@ -16391,6 +1

[PATCH 02/10] mips: Implement vec_perm_const.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/loongson.h |4 +- gcc/config/mips/loongson.md| 200 ++- gcc/config/mips/mips-modes.def | 12 ++- gcc/config/mips/mips-protos.h |1 + gcc/config/mips/mips-ps-3d.md | 225 +-- gcc/config/mip

[PATCH 03/10] mips: Implement logical operations on vectors for Loongson.

2011-12-21 Thread Richard Henderson
--- gcc/config/mips/loongson.md | 45 +++ 1 files changed, 45 insertions(+), 0 deletions(-) diff --git a/gcc/config/mips/loongson.md b/gcc/config/mips/loongson.md index 1b1fe0b..325838d 100644 --- a/gcc/config/mips/loongson.md +++ b/gcc/config/mips/loongs

[PATCH 01/10] mips: Allow mode changes between integrals in FP registers.

2011-12-21 Thread Richard Henderson
We ask for subregs of vectors all of the time, punning them between different vector modes. The test below allows punning between DI, V8QI, V4HI, and V2SI modes. Without this we get oodles of dummy copies to and from the general register set for each mode change. --- gcc/config/mips/mips.c |

[PATCH v3 00/10] MIPS vectorization improvements

2011-12-21 Thread Richard Henderson
The second patch you've seen before, updated with your comments. The rest came from trying to reduce the number of tests failing to be vectorized when compiling for Loongson. Eventually I just had to stop though; the result is still quite a few pattern match tests fail, but at least there are no

RFA: backport fix for PR 48660 (assigning to BLKmode return regs)

2011-12-21 Thread Richard Sandiford
PR 48660 is about an ICE while trying to assign a value to a BLKmode result register. It's already fixed on trunk, but it's a regression from 4.4 that has no workaround besides changing the source code, so is it OK for 4.5 and 4.6 as well? Tested on arm-linux-gnueabi and x86_64-linux-gnu. The or

Re: [PATCH, PR 51600] IPA-CP workaround for negative size cloning estimates

2011-12-21 Thread Jan Hubicka
> Hi, > > given that we already have a workaround for zero size increase > estimates from estimate_ipcp_clone_size_and_time, I see little reason > not to extend it to negative values too, 0 is really just as bad as -2 > that we are getting in the testcase. Hopefully this will allow peple > who hi

Re: [PATCH] atomic test and set re-org.

2011-12-21 Thread Richard Henderson
On 12/21/2011 04:49 AM, Oleg Endo wrote: > BTW, currently the only target utilizing the new atomic_test_and_set is > SPARC. However, as far as I've observed an expander like > > (define_expand "atomic_test_and_set" That's a mistake. The mode is significant -- it's the mode of the memory. I'm so

Re: [Patch, libfortran] PR 51646 Use POSIX mode flags

2011-12-21 Thread Tobias Burnus
On 12/21/2011 04:59 PM, Janne Blomqvist wrote: someone made some effort to build gfortran on an android phone (see the PR). One problem was that libgfortran was using the old BSD S_IREAD and S_IWRITE mode flags instead of the POSIX S_IRUSR and S_IWUSR. The attached patch replaces the usage of the

Re: [PATCH] Reorder AM_CXXFLAGS in libitm

2011-12-21 Thread Jakub Jelinek
On Wed, Dec 21, 2011 at 08:00:08AM -0800, Richard Henderson wrote: > On 12/21/2011 06:25 AM, Jakub Jelinek wrote: > > In my redhat/gcc-4_7-branch build with -fexceptions in XCFLAGS > > (comes from standard Fedora optimization flags) > > Really? Out of curiousity, why? Because for C it allows mo

Re: [Patch]: ia64 - remove ia64_promote_function_mode

2011-12-21 Thread Richard Henderson
On 12/21/2011 02:29 AM, Tristan Gingold wrote: > #undef TARGET_PROMOTE_FUNCTION_MODE > -#define TARGET_PROMOTE_FUNCTION_MODE ia64_promote_function_mode > +#define TARGET_PROMOTE_FUNCTION_MODE default_promote_function_mode Delete this entirely. r~

Re: [RFC / Patch] PR 51305

2011-12-21 Thread Paolo Carlini
On 12/21/2011 04:44 PM, Jason Merrill wrote: If reordering works, let's just do that. Sure. Then I'm going to apply the below when re-testing completes. Thanks! Paolo. /// /cp 2011-12-21 Paolo Carlini PR c++/51305 * semantics.c (massage_constexpr_body): Reor

Re: [PATCH] Reorder AM_CXXFLAGS in libitm

2011-12-21 Thread Richard Henderson
On 12/21/2011 06:25 AM, Jakub Jelinek wrote: > In my redhat/gcc-4_7-branch build with -fexceptions in XCFLAGS > (comes from standard Fedora optimization flags) Really? Out of curiousity, why? > * Makefile.am (AM_CXXFLAGS): Put $(XCFLAGS) first. > * Makefile.in: Regenerated. Ok. r

[Patch, libfortran] PR 51646 Use POSIX mode flags

2011-12-21 Thread Janne Blomqvist
Hi, someone made some effort to build gfortran on an android phone (see the PR). One problem was that libgfortran was using the old BSD S_IREAD and S_IWRITE mode flags instead of the POSIX S_IRUSR and S_IWUSR. The attached patch replaces the usage of these BSD flags with the POSIX ones. I decided

Re: [RFC / Patch] PR 51305

2011-12-21 Thread Jason Merrill
If reordering works, let's just do that. Jason

Re: [patch committed SH] Add atomic patterns

2011-12-21 Thread Oleg Endo
> > Ugh, I've read the middle end code wrongly. Then we can remove > > fetchop_insn which now becomes to be the same one with fetchop_name. > > Could you propose the patch with that change and the backslash > > changes rth suggested? It's pre-approved with those changes. > > Attached patch shou

[PATCH] Fix make_relative_prefix_1 (PR driver/48306)

2011-12-21 Thread Jakub Jelinek
Hi! As reported in the PR, when the gcc (or g++, ...) binary is not started with full path and somewhere in $PATH earlier then were gcc binary is is a directory with the same name (gcc, g++, ...), then execvp will ignore it, but make_relative_prefix will think it is the path to the driver and deri

Re: [PATCH] Fix some further gimple_clobber_p fallout (PR middle-end/51644)

2011-12-21 Thread Richard Guenther
On Wed, 21 Dec 2011, Jakub Jelinek wrote: > Hi! > > The following testcases fail on the trunk, because at -O0 > we don't decide to copy the finally stmts if there is more than one > destination. That is of course desirable for debugging reasons if > there are any real stmts, but if the try/final

[PATCH] Fix some further gimple_clobber_p fallout (PR middle-end/51644)

2011-12-21 Thread Jakub Jelinek
Hi! The following testcases fail on the trunk, because at -O0 we don't decide to copy the finally stmts if there is more than one destination. That is of course desirable for debugging reasons if there are any real stmts, but if the try/finally has been created only to hold gimple_clobber_p stmts

[PATCH] Reorder AM_CXXFLAGS in libitm

2011-12-21 Thread Jakub Jelinek
Hi! In my redhat/gcc-4_7-branch build with -fexceptions in XCFLAGS (comes from standard Fedora optimization flags) I got many libitm testsuite failures, because libitm currently relies on -fno-exceptions as it is not linked against -lstdc++. Fixed by putting XCFLAGS first and thus overriding thos

Re: [PATCH] Fix profiledbootstrap failures

2011-12-21 Thread Richard Guenther
On Wed, Dec 21, 2011 at 3:21 PM, Jakub Jelinek wrote: > Hi! > > My profiledbootstrap --enable-checking=release (and lots of other configury > options) failed this morning, I got warnings (promoted to errors due to > -Werror*) because our uninitialized warning code couldn't figure these out. > > Fi

[PATCH] Fix profiledbootstrap failures

2011-12-21 Thread Jakub Jelinek
Hi! My profiledbootstrap --enable-checking=release (and lots of other configury options) failed this morning, I got warnings (promoted to errors due to -Werror*) because our uninitialized warning code couldn't figure these out. Fixed thusly, bootstrapped/regtested on x86_64-linux and i686-linux,

Re: PR middle-end/51472: set DECL_GIMPLE_REG_P on TM vector saves

2011-12-21 Thread Jakub Jelinek
On Wed, Dec 21, 2011 at 08:15:38AM -0600, Aldy Hernandez wrote: > >The first hunk looks okay. > > Was that an approval? Updated patch attached. Yes. Thanks. Jakub

Re: PR middle-end/51472: set DECL_GIMPLE_REG_P on TM vector saves

2011-12-21 Thread Aldy Hernandez
On 12/21/11 08:07, Jakub Jelinek wrote: On Wed, Dec 21, 2011 at 07:52:16AM -0600, Aldy Hernandez wrote: Oh neat... create_tmp_reg will do all this for me. I don't think that update_stmt is needed there. The stmt is freshly allocated a few lines above it: stmt = gimple_build_assign (lp-

RFC: IRA patch to reduce lifetimes

2011-12-21 Thread Bernd Schmidt
For a customer I've looked into improving code for 456.hmmer on a mips64 target. The benchmark responds to -fsched-pressure, which reduces lifetimes of a few registers. This patch was an experiment to see if we can get the same improvement with modifications to IRA, making it more tolerant to over

Re: PR middle-end/51472: set DECL_GIMPLE_REG_P on TM vector saves

2011-12-21 Thread Jakub Jelinek
On Wed, Dec 21, 2011 at 07:52:16AM -0600, Aldy Hernandez wrote: > Oh neat... create_tmp_reg will do all this for me. I don't think that update_stmt is needed there. The stmt is freshly allocated a few lines above it: stmt = gimple_build_assign (lp->save_var, unshare_expr (lp->addr)); so th

[Ada] Ada 2012 type invariants on type completions

2011-12-21 Thread Arnaud Charlet
In Ada 2012, type invariants can appear in the private part of a package, on a type declaration that is a completion. This patch analyzes properly the invariant and creates the invariant procedure for the type, so that it is applied in the same contexts as an invariant in the visible part. Compili

Re: PR middle-end/51472: set DECL_GIMPLE_REG_P on TM vector saves

2011-12-21 Thread Aldy Hernandez
You can't simply do + if (TREE_CODE (TREE_TYPE (var)) == COMPLEX_TYPE + || TREE_CODE (TREE_TYPE (var)) == VECTOR_TYPE) + DECL_GIMPLE_REG_P (var) = 1; + update_stmt (stmt); where is 'var' created? At _that_ point you should do the above (or use create_tmp_

[Ada] Allocation of coextensions

2011-12-21 Thread Arnaud Charlet
In certain cases the object designated by an access discriminant can be stack- allocated, for example when the enclosing object is a local object declaration. However, if the access discriminant is an aggregate component of a return expression or a return object, it must be allocated dynamically.

[Ada] Implement conventions Ada_Pass_By_Copy and Ada_Pass_By_Reference

2011-12-21 Thread Arnaud Charlet
These conventions allow the programmer to control the parameter passing method used in cases where it would normally be up to the implementation. The convention is applied to the type, and then affects how parameters with this type are passed. It is not allowed to specify Ada_Pass_By_Copy for types

[Ada] Spurious warnings on element iterator whose domain is a function call

2011-12-21 Thread Arnaud Charlet
This patch suppresses spurious warnings on an iterator of the form: "for E of C" when C is a parameterless function call, and code expansion is disabled. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Ed Schonberg * sem_ch5.adb (Analyze_Iterator_Specification): If the na

[Ada] Fixed incorrect comment about conditional insertion

2011-12-21 Thread Arnaud Charlet
An incorrect comment in Generic_Conditional_Insert was fixed, and the subprogram was properly documented. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Matthew Heaney * a-crbtgk.adb (Generic_Conditional_Insert): Fixed incorrect comment. Index: a-crbtgk.adb

[Ada] Use Encapsulated instead of Fully Standalone library

2011-12-21 Thread Arnaud Charlet
Attributes Library_Fully_Standalone_Supported and Library_Fully_Standalone_Options have been renamed Library_Encapsulated_Supported and Library_Encapsulated_Options respectively. No change in behavior. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Pascal Obry * gnat_ug

[Ada] Inherited aspects of subtypes

2011-12-21 Thread Arnaud Charlet
Certain aspects on types apply to their subtypes as well. These include the aspects involved in iterators. If the type of a container is a subtype, obtain the iterator aspects from the base type. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Ed Schonberg * aspects.ads:

[PATCH] Speedup and make LTO type merging consistent for pre-loaded types

2011-12-21 Thread Richard Guenther
This speeds up LTO type merging by only calling gimple_register_type on those types that possibly can require fixup (by means on how the uniquification process is designed). This makes the behavior for pre-loaded type nodes consistent, as we do not throw them at gimple_register_type directly but

Re: [PATCH] atomic test and set re-org.

2011-12-21 Thread Oleg Endo
On Thu, 2011-11-24 at 15:50 -0500, Andrew MacLeod wrote: > This patch adds missing pattern support for atomic_test_and_set and > atomic_clear operations. It also restructures the code for > atomic_test_and_set, atomic_exchange, and __sync_lock_test_and_set so > that it is easier to read and tr

[Ada] Allow generic iteration on formal lists

2011-12-21 Thread Arnaud Charlet
This patch allows the use of generic iteration on formal lists. If L is a formal list of integers, the following loop is now accepted: for C of L loop Put_Line ("Value =>" & C'Img); end loop; Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Claire Dross * a-cfdlli.ads

[PATCH, SMS] Prevent the creation of reg-moves for non allocatable definition​s (re-submission)

2011-12-21 Thread Revital Eres
Hello, Following Richard's comment http://gcc.gnu.org/ml/gcc-patches/2011-12/msg01469.html attached is a new version of the patch to prevent reg-moves for non allocatable definitions. Currently testing and bootstrap on ppc64-redhat-linux, enabling SMS on loops with SC 1. OK for 4.7 once testing

[Ada] Proper handling of Has_Element in user-defined iterators

2011-12-21 Thread Arnaud Charlet
To iterate over a user-defined container, it must have a primitive operation that returns an iterator type, that is to say a type that implements one of the iterfaces declared in an instance of Ada.Iterator_Interfaces. Has_Element is a formal of this package. In the expansion of the iterator loop,

[Ada] Send gnatls/gnatcmd verbose diagnostics to stderr

2011-12-21 Thread Arnaud Charlet
This change ensures that verbose debugging/diagnostics messages emitted by gnatls/gnat list are sent to stderr instead of being interspersed with the normal stdout output. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-12-21 Thomas Quinot * gnatls.adb (Gnatls): Call Set_Standa

[Ada] Add support for fully standalone libraries

2011-12-21 Thread Arnaud Charlet
The new Library_Standalone attribute is used to select the mode for the standalone shared libraries. No : This is not a standalone library. Library_Interface should not be set. Standard : elaboration/finalization local for the library. Full : as above, but link o

Re: [PATCH] Remove some newlines from tree-into-ssa.c dumps

2011-12-21 Thread Richard Guenther
On Wed, Dec 21, 2011 at 11:32 AM, Martin Jambor wrote: > Hi, > > I know it's stage three but I hope this tiny patch which affects only > dumping is still acceptable.  In SRA passes I wrote dumping so that > when the detailed dump is not requested, it is quite brief and only > writes the decisions,

[Patch]: split libgcc/config/ia64/t-ia64 in two

2011-12-21 Thread Tristan Gingold
Hi, this patch fixes two build libgcc issues on VMS/ia64. * Because VMS doesn't define LIBGCC2_HAS_TF_MODE, compatibility thunks shouldn't be compiled. Otherwise, the shared libgcc library fails to build due to undefined symbols. * As VMS isn't fully compliant with ELF, crtstuff.c is used for

[patch]: ia64 - allow VMS to redefine TARGET_PROMOTE_FUNCTION_MODE

2011-12-21 Thread Tristan Gingold
Hi, a follow-up of the previous patch. Maybe they should be merged. VMS/ia64 doesn't closely follow the standard ELF ABI, and keep some aspects of the Alpha ABI for backward compatibility. With the previous patch, this patch fixes a convention call ABI issue, as well as an ICE that appears wh

[PATCH] Remove some newlines from tree-into-ssa.c dumps

2011-12-21 Thread Martin Jambor
Hi, I know it's stage three but I hope this tiny patch which affects only dumping is still acceptable. In SRA passes I wrote dumping so that when the detailed dump is not requested, it is quite brief and only writes the decisions, not how it reached those decisions. Of course, that means that de

[Patch]: ia64 - remove ia64_promote_function_mode

2011-12-21 Thread Tristan Gingold
Hi, config/ia/ia64.c define ia64_promote_function_mode only for the sake of VMS, as linux and hp/ux uses default_promote_function_mode. What is done for VMS could be achieved by defining PROMOTE_MODE. This patch cleans up ia64.c a little bit, by removing ia64_promote_function_mode, and defining

[PATCH, PR 51600] IPA-CP workaround for negative size cloning estimates

2011-12-21 Thread Martin Jambor
Hi, given that we already have a workaround for zero size increase estimates from estimate_ipcp_clone_size_and_time, I see little reason not to extend it to negative values too, 0 is really just as bad as -2 that we are getting in the testcase. Hopefully this will allow peple who hit this bug pro

Re: [RFC / Patch] PR 51305

2011-12-21 Thread Paolo Carlini
Hi again, Hi, this is a rejects-valid with constexpr & noexcept, noticed by Daniel (and myself time ago). I find it pretty annoying. Anyway, the issue is, we reject: constexpr bool ok() noexcept { typedef int type; return true; } constexpr auto x = ok(); because of the noexcept. What h

[committed] VMS: always default to .text section

2011-12-21 Thread Tristan Gingold
Hi, like the HP-UX linker, the VMS linker doesn't deal well with named text sections. So, always default to .text section on both Alpha and ia64 VMS. Committed on trunk. Tristan. 2011-12-21 Tristan Gingold * config/vms/vms-protos.h (vms_function_section): New prototype. * c

Re: PR middle-end/51472: set DECL_GIMPLE_REG_P on TM vector saves

2011-12-21 Thread Richard Guenther
On Tue, Dec 20, 2011 at 5:57 PM, Aldy Hernandez wrote: > The problem here is a verify_gimple ICE because a vector store's LHS is not > a gimple register, but the vector type is a gimple_reg_type. > >     if (!is_gimple_reg (lhs) >          && is_gimple_reg_type (TREE_TYPE (lhs))) >        { >    

[PATCH] Fix PR41159

2011-12-21 Thread Richard Guenther
This fixes an ICE with -O0 at LTO link time. The assertion that the destination result is equal to the promote_decl_mode result is only true for pseudos - but with -O0 we commit all autos to stack variables, so SA.partition_to_pseudo[] can contain MEMs. Fixed by adjusting the assertion and alway

[committed]: VMS/ia64 add missing macro in fde-vms.c

2011-12-21 Thread Tristan Gingold
Hi, this is a minor adjustment after the move of fde-vms from gcc/ to libgcc/. Macro UNW_IVMS_MODE was not defined. Fixed by this patch, committed on trunk. Tristan. libgcc/ 2011-12-21 Tristan Gingold * config/ia64/fde-vms.c (UNW_IVMS_MODE): Define. --- a/libgcc/config/ia64/fde-v

[committed]: VMS: remove definition of STANDARD_EXEC_PREFIX

2011-12-21 Thread Tristan Gingold
Hi, the definition in vms/xm-vms.h was not correct and the default value is fine. So this patch remove the line. Applied on trunk. Tristan. 2011-12-21 Tristan Gingold * config/vms/xm-vms.h (STANDARD_EXEC_PREFIX): Remove define. diff --git a/gcc/config/vms/xm-vms.h b/gcc/config/vm

Re: [PATCH, ARM] Fix stack red zone bug (PR38644) for GCC 4.6

2011-12-21 Thread Sebastian Huber
Would someone mind committing this to the 4.6 branch. Thanks. The test suite results are only missing for the 4.4 and 4.5 branch. -- Sebastian Huber, embedded brains GmbH Address : Obere Lagerstr. 30, D-82178 Puchheim, Germany Phone : +49 89 18 90 80 79-6 Fax : +49 89 18 90 80 79-9 E-Mai