cfg fixup bug fix

2011-08-01 Thread Xinliang David Li
The attached patch fixed a minor bug in cfg fixup -- the outgoing edge profile count is not scaled after inlining leading to warnings printed in IR dump -- 'Invalid sum of ...'. Bootstrap and tested on x86-64/linux, ok for trunk? Thanks, David p2 Description: Binary data

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Kirill Yukhin
Ping. -- K On Wed, Jul 27, 2011 at 10:23 PM, Kirill Yukhin wrote: > Okay, then here is an updated patch > > updated ChangeLog entry: > 2011-07-26  Kirill Yukhin   > >        PR target/49547 >        * config.gcc (i[34567]86-*-*): Replace abmintrin.h with >        lzcntintrin.h. >        (x86_64-

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Uros Bizjak
On Mon, Aug 1, 2011 at 10:21 AM, Kirill Yukhin wrote: >> Okay, then here is an updated patch >> >> updated ChangeLog entry: >> 2011-07-26  Kirill Yukhin   >> >>        PR target/49547 >>        * config.gcc (i[34567]86-*-*): Replace abmintrin.h with >>        lzcntintrin.h. >>        (x86_64-*-*)

Re: Patches ping

2011-08-01 Thread Revital1 Eres
Hi, Thanks for the review! > > >Changelog: > > > >       (sms_schedule_by_order): Update call to get_sched_window. > >       all set_must_precede_follow. >     ^^^ >     call Done. > >+/* Set bitmaps TMP_FOLLOW and TMP_PRECEDE to MUST_FOLLOW and MUST_PRECEDE > >+   respectively only if

[Ada] Legality checks on 'Result in the presence of quantified expression

2011-08-01 Thread Arnaud Charlet
The expansion of quantified expressions into loops introduces new scopes that must be taken into account when validating the use of the attribute 'Result. The following must compile quietly: gcc -c -gnat12 -gnata test_astrium_2.adb -- with Ada.Containers.Ordered_Sets; package Test_Astrium_2 is

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Kirill Yukhin
Thanks! Guys with waa rights, could anybody commit my fix? Thanks, K > > OK for mainline. > > Uros. >

[PATCH] Fix libquadmath on FLT_EVAL_METHOD != 0 targets

2011-08-01 Thread Jakub Jelinek
Hi! As #include #include void printq(__float128 x) { char buf[100]; quadmath_snprintf(buf, 100, "%40.30Qa", x); printf("%s\n", buf); } int main() { __float128 twopi = 6.28318530717958647692528676655900576839433879875021164194989Q; __float128 three = 3.0Q; __float128 two = 2.0Q;

[Ada] Access to protected subprograms in generic bodies

2011-08-01 Thread Arnaud Charlet
This patch fixes two bugs in the handling of 'access applied to a protected subprogram, when the attribute reference appears within a generic body, and the access type is declared outside of the body. This is now properly rejected. The patch also fixes a bug in the legality check for convention, an

[Ada] No adainit/adafinal procedures in Stand-Alone Libraries

2011-08-01 Thread Arnaud Charlet
This patch set the names of the init and final procedures of Stand-Alone Libraries to "ada_init" and "ada_final" if the name of the library is "ada", to avoid duplicate symbols "adainit" and "adafinal" in executables. The test for this is to build an executable using a shared SAL with the name "ada

Re: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Jakub Jelinek
On Mon, Aug 01, 2011 at 11:44:04AM +0800, Jiangning Liu wrote: > It's quite necessary to solve the general problem in middle-end rather than > in back-end. That's what we disagree on. All back-ends but ARM are able to handle it right, why can't ARM too? The ABI rules for stack handling in the e

[Ada] Incorrect assignment when deleting node

2011-08-01 Thread Arnaud Charlet
When a node was being removed from the tree, the node itself was being assigned to the child of its parent, which was incorrect. The correct assignment value is the left child of the deleted node. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-08-01 Matthew Heaney * a-rbtgbo.a

[Ada] Delay all aspects

2011-08-01 Thread Arnaud Charlet
This patch implements delay of all aspects till the freeze point as finally decided in the Ada 2012 design. It also corrects a couple of errors in handling delayed aspects (now that we have many more of them, these errors showed up). Here is a test program (compiled with -gnatws) 1. pragma A

[Ada] Incorrect use of iterator when selector was intended

2011-08-01 Thread Arnaud Charlet
When navigating over the nodes in the same bucket of a hash table, one only needs the next pointer of the current node in order to move to the next node (in the same bucket). The delete operation was using the container-wide iterator to get the pointer to the next node, but this was incorrect, as

Re: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Joseph S. Myers
On Mon, 1 Aug 2011, Jakub Jelinek wrote: > On Mon, Aug 01, 2011 at 11:44:04AM +0800, Jiangning Liu wrote: > > It's quite necessary to solve the general problem in middle-end rather than > > in back-end. > > That's what we disagree on. All back-ends but ARM are able to handle it > right, why can

RE: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Jiangning Liu
The answer is ARM can. However, if you look into the bugs PR30282 and PR38644, PR44199, you may find in history, there are several different cases in different ports reporting the similar failures, covering x86, PowerPC and ARM. You are right, they were all fixed in back-ends in the past, but we

Re: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Richard Earnshaw
On 01/08/11 10:11, Jakub Jelinek wrote: > On Mon, Aug 01, 2011 at 11:44:04AM +0800, Jiangning Liu wrote: >> It's quite necessary to solve the general problem in middle-end rather than >> in back-end. > > That's what we disagree on. All back-ends but ARM are able to handle it > right, why can't A

[Ada] Visibility check for aspects, part 1

2011-08-01 Thread Arnaud Charlet
This patch implements the consistent visibility check for enties with delayed aspects that are frozen early, as shown by the tests below. This step covers all aspects except Invariant and Predicate, which will be taken care of separately. 1. pragma Ada_2012; 2. package AspectVis is

Re: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Jakub Jelinek
On Mon, Aug 01, 2011 at 06:14:27PM +0800, Jiangning Liu wrote: > ARM. You are right, they were all fixed in back-ends in the past, but we > should > fix the bug in a general way to make GCC infrastructure stronger, rather > than fixing the problem target-by-target and case-by-case! If you further

[Ada] Implement new aspects Dynamic_Predicate and Static_Predicate

2011-08-01 Thread Arnaud Charlet
This patch introduces two new aspects. Dynamic_Predicate provides a subtype predicate which can have any form, but the result cannot be used in loops and case statements. Static_Predicate limits the form of expressions to be static in the sense previously implemented for the static case of Predicat

[Ada] Invariant aspect now called Type_Invariant

2011-08-01 Thread Arnaud Charlet
This patch implements the latest version of invariants, in which the aspect is called Type_Invariant, the old name Invariant is retained as an implementation-specific aspect. A general mechanism for dealing with synonyms is also implemented (so that e.g. you cannot specify both Invariant and Type_I

[gomp3.1] Handle OMP_PROC_BIND env var

2011-08-01 Thread Jakub Jelinek
Hi! This patch handles OMP_PROC_BIND=true roughly as GOMP_CPU_AFFINITY=0-65535 if GOMP_CPU_AFFINITY isn't present in the environment, just slightly more efficiently during startup. Tested on x86_64-linux, committed to gomp-3_1-branch. 2011-08-01 Jakub Jelinek * env.c (initialize_env)

[PATCH] Fix bitsizetype TYPE_MAX_VALUE

2011-08-01 Thread Richard Guenther
This sign-extends it, similar to how we treat TYPE_MAX_VALUE of sizetype. Bootstrapped and tested on x86_64-unknown-linux-gnu, applied to trunk. Richard. 2011-08-01 Richard Guenther * stor-layout.c (initialize_sizetypes): Properly sign-extend bitsiztype TYPE_MAX_VALUE. Inde

Support .debug_macro with Sun as (PR debug/49887)

2011-08-01 Thread Rainer Orth
As described in the PR, many gcc.dg/debug and g++.dg/debug tests were failing on Solaris/SPARC with -gdwarf-2 -g3 and Sun as. This happens because the signature symbols Sun as requires for the COMDAT groups are emitted in TARGET_ASM_CODE_END, before *debug_hooks->finish runs which creates new ones

Re: [patch tree-optimization]: Fix for PR/49806

2011-08-01 Thread Richard Guenther
On Fri, Jul 29, 2011 at 2:07 PM, Kai Tietz wrote: > Hello, > > this patch fixes regression of bug report PR middle-end/49806, which was > caused due unhandled type-cast patterns reasoned by boolification of compares > and type-cast preserving from/to boolean types. > > > ChangeLog > > 2011-07-29

[Patch,AVR]: PR46278 (fake X addressing)

2011-08-01 Thread Georg-Johann Lay
This is Denis' work from http://codereview.appspot.com/4674046/ updated to current trunk in order to resume work on that PR. I removed some changes from the patch (which originated in my original patch) that are avr backend cleanups and don't deal with this fake X addressing PR. Likewise the fix

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Kirill Yukhin
I've merged my changes with trunk (there was a conflict) and fixed typo. Updated patch is attached. Waiting for commit... Thanks, K On Mon, Aug 1, 2011 at 1:03 PM, Kirill Yukhin wrote: > Thanks! > Guys with waa rights, could anybody commit my fix? > > Thanks, K > >> >> OK for mainline. >> >> Uro

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread H.J. Lu
On Mon, Aug 1, 2011 at 5:20 AM, Kirill Yukhin wrote: > I've merged my changes with trunk (there was a conflict) and fixed typo. > Updated patch is attached. Waiting for commit... > > Thanks, K > > On Mon, Aug 1, 2011 at 1:03 PM, Kirill Yukhin wrote: >> Thanks! >> Guys with waa rights, could anybo

Re: [PLUGIN] compile and install gengtype, install gtype.state

2011-08-01 Thread Romain Geissler
ping 2011/7/26 Romain Geissler : > 2011/7/25 Jakub Jelinek : >> On Mon, Jul 25, 2011 at 09:10:55PM +0200, Romain Geissler wrote: >>> > 2011-07-18  Romain Geissler   >>> > >>> >     * gengtype-state.c (#include "bconfig.h"): Include "bconfig.h" >>> >     if GENERATOR_FILE is defined, "config.h" oth

[Ada] Fixes to preelaborable initialization handling

2011-08-01 Thread Arnaud Charlet
This change updates the circuitry that handles the preelaborable initialization property for controlled types. It fixes several bugs whereby some types would erroneously be treated as not having preelaborable initialization. It also implements one of the changes in AI05-028 for Ada 2012, to the eff

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Kirill Yukhin
Hi HJ, Thanks for input. I've missed it. Done. Updated patch is attached. Thanks, K On Mon, Aug 1, 2011 at 4:26 PM, H.J. Lu wrote: > On Mon, Aug 1, 2011 at 5:20 AM, Kirill Yukhin wrote: >> I've merged my changes with trunk (there was a conflict) and fixed typo. >> Updated patch is attached. Wai

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread H.J. Lu
On Mon, Aug 1, 2011 at 5:36 AM, Kirill Yukhin wrote: > Hi HJ, > Thanks for input. I've missed it. > Done. Updated patch is attached. Compiler may still optimize it away. You need to replace 0 with a function parameter. Please see: http://gcc.gnu.org/ml/gcc-patches/2011-07/msg02463.html H.J.

[Ada] New syntax for aspects in packages, add library unit aspects

2011-08-01 Thread Arnaud Charlet
This patch adds aspects for library unit pragmas, e.g. in packages, and implements the new syntax (aspects before IS keyword), as shown in these tests: 1. pragma Ada_2012; 2. package aspectpu with Pure is 3. X : Integer; | >>> declaration of variable not allowed

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread Kirill Yukhin
Done. Updated patch is attached. Thanks, K On Mon, Aug 1, 2011 at 4:49 PM, H.J. Lu wrote: > On Mon, Aug 1, 2011 at 5:36 AM, Kirill Yukhin wrote: >> Hi HJ, >> Thanks for input. I've missed it. >> Done. Updated patch is attached. > > Compiler may still optimize it away.  You need to replace 0 wit

[Ada] Add procedure to print out the predefined floating point types

2011-08-01 Thread Arnaud Charlet
This new procedure is a clean up that replaces explicit references of constants such as Standard_Long_Float_Size by calls to attribute functions in Einfo. This will allow eventual removal of explicit constants for each predefined type. No functional change. Tested on x86_64-pc-linux-gnu, committe

[Ada] Improve error message for extra "," in choice list

2011-08-01 Thread Arnaud Charlet
The new error messages should be: c.adb:4:16: extra "," ignored c.adb:9:16: "," should be "|" for the following test case: procedure c (X : Boolean) is begin case X is when True, | False => null; end case; case X is when True, False => null; end case; end c; Te

[Ada] Better reference information for in out params

2011-08-01 Thread Arnaud Charlet
The ali file not includes both a read and modify reference for an entity that is an actual for an in-out parameter. The following commands: gcc -c gp.adb grep G{integer} gp.ali must yield: 2i4*G{integer} 2|9m14 9r14 --- package GP is G : Integer; procedure Indirect_Read_Write; e

[Ada] Improved error message on invisible operator

2011-08-01 Thread Arnaud Charlet
A common programming error is to assume that a predefined operator is visible when its operand type is in scope. The compiler in that case indicates that a use clause would make the operation legal. However, the type maybe only in scope indirectly, through other visible units, in which case the err

Re: [PATCH] ARM fixed-point support [5.5/6]: argument & return padding for libcalls

2011-08-01 Thread H.J. Lu
On Thu, May 26, 2011 at 9:56 AM, Julian Brown wrote: > This patch allows padding to be specified per-target for libcalls. This > hasn't been traditionally important, because libcalls haven't accepted > quantities which might need padding, but that's no longer true with the > new(-ish) fixed-point

Re: [C++0x] contiguous bitfields race implementation

2011-08-01 Thread Richard Guenther
On Fri, Jul 29, 2011 at 11:37 AM, Richard Guenther wrote: > On Fri, Jul 29, 2011 at 4:12 AM, Aldy Hernandez wrote: >> On 07/28/11 06:40, Richard Guenther wrote: >> >>> Looking at the C++ memory model what you need is indeed simple enough >>> to recover here.  Still this loop does quadratic work f

Re: [PATCH] ARM fixed-point support [5.5/6]: argument & return padding for libcalls

2011-08-01 Thread H.J. Lu
On Mon, Aug 1, 2011 at 6:38 AM, H.J. Lu wrote: > On Thu, May 26, 2011 at 9:56 AM, Julian Brown wrote: >> This patch allows padding to be specified per-target for libcalls. This >> hasn't been traditionally important, because libcalls haven't accepted >> quantities which might need padding, but th

Re: Support -mcpu=native on Solaris/SPARC

2011-08-01 Thread Rainer Orth
Rainer Orth writes: > This is a first cut at supporting -mcpu=native/-mtune=native on > Solaris/SPARC. Unlike it's Tru64 UNIX/Alpha and IRIX/MIPS (to be > submitted soon) counterparts, it's a bit more involved: > > * There's no support for -mcpu=native in the SPARC port yet. > > * Access to the

Re: [PATCH] ARM fixed-point support [5.5/6]: argument & return padding for libcalls

2011-08-01 Thread H.J. Lu
On Mon, Aug 1, 2011 at 6:51 AM, H.J. Lu wrote: > On Mon, Aug 1, 2011 at 6:38 AM, H.J. Lu wrote: >> On Thu, May 26, 2011 at 9:56 AM, Julian Brown >> wrote: >>> This patch allows padding to be specified per-target for libcalls. This >>> hasn't been traditionally important, because libcalls haven'

Re: Support -mcpu=native on Solaris/SPARC

2011-08-01 Thread Paolo Bonzini
On 08/01/2011 03:51 PM, Rainer Orth wrote: Here's an updated version of the patch, containing two changes: * Solaris 8 doesn't support KSTAT_DATA_STRING. * I've updated the list of known cpu types, based on the /platform/sun4?/kernel/cpu{, /sparcv9} entries found in Solaris 8, 9, 10 and 1

Re: Patch for C++ build on HP-UX and to implement -static-libstdc++

2011-08-01 Thread John David Anglin
On 29-Jul-11, at 2:11 PM, Steve Ellcey wrote: On Fri, 2011-07-29 at 20:00 +0200, Rainer Orth wrote: Steve, Index: gcc/configure.ac === --- gcc/configure.ac(revision 176899) +++ gcc/configure.ac(working copy) @@ -3240,6 +

[PATCH] Fix PR49907

2011-08-01 Thread Richard Guenther
This fixes PR49907 - ok for trunk? Thanks, Richard. 2011-08-01 Richard Guenther PR bootstrap/49907 lto-plugin/ * configure.ac: Use ACX_PROG_CC_WARNING_OPTS to detect -Wall presence. * Makefile.am (AM_CFLAGS): Adjust. Do not build with -Werror. * confi

Re: [PATCH] ARM fixed-point support [5.5/6]: argument & return padding for libcalls

2011-08-01 Thread Julian Brown
On Mon, 1 Aug 2011 06:54:54 -0700 "H.J. Lu" wrote: > >> This breaks bootstrap on Linux/x86: > I checked it in as an obvious fix. Sorry about that, and thank you! Cheers, Julian

[Ada] Avoid FE crash processing wrong sources

2011-08-01 Thread Arnaud Charlet
This patch avoids the frontend crash when generated with assertions enabled and it process the following wrong sources in which partial view is not a synchronized tagged type as requested by RM 7.3 (7.2/2). package RT is type I is protected interface; type T is tagged limited private; privat

[Ada] Remove duplicated units

2011-08-01 Thread Arnaud Charlet
This code reorganization reduces the amount of code duplication in the GNAT runtime library. No behaviour change, no test. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-08-01 Thomas Quinot * s-parame-ae653.ads, s-parame-vms-alpha.ads, s-parame-hpux.ads, i-cpoint.adb,

[Patch,AVR]: Supply and use information on skip core bug

2011-08-01 Thread Georg-Johann Lay
Some AVR devices have the skip bug, i.e. they must not use any skip instruction to bypass a 2-word instruction. Affected devices are AT90S8515 (core avr2) and ATmega103 (core avr31). For information see the new file errata.txt. This patch supplies new built-in macros so that a user can test if t

[Committed,AVR]: Fix SVN properties svn:executable

2011-08-01 Thread Georg-Johann Lay
Some files had wrong svn:executable property, I fixed that. http://gcc.gnu.org/viewcvs?view=revision&revision=177039 Johann * config/avr/avr-devices.c: Delete SVN property svn:executable. * config/avr/predicates.md: Ditto. * config/avr/driver-avr.c: Ditto. * confi

RE: [Patch,AVR]: Supply and use information on skip core bug

2011-08-01 Thread Weddington, Eric
> -Original Message- > From: Georg-Johann Lay [mailto:a...@gjlay.de] > Sent: Monday, August 01, 2011 8:38 AM > To: gcc-patches@gcc.gnu.org > Cc: Anatoly Sokolov; Denis Chertykov; Weddington, Eric > Subject: [Patch,AVR]: Supply and use information on skip core bug > > Some AVR devices have

Re: [RS6000] asynch exceptions and unwind info

2011-08-01 Thread Alan Modra
On Fri, Jul 29, 2011 at 10:28:28PM +0930, Alan Modra wrote: > libgcc/ > * config/rs6000/linux-unwind.h (frob_update_context <__powerpc64__>): > Restore for indirect call bcrtl from correct stack slot, and only > if cfa+40 isn't valid. > gcc/ > * config/rs6000/rs6000-protos.h

[Ada] Update run-time files to GPLv3

2011-08-01 Thread Arnaud Charlet
This patch moves most remaining GNAT run-time files to GPLv3 run-time license, and also gradually remove the old name GNARL which is no longer used, in favor of simply GNAT. Tested on x86_64-pc-linux-gnu, committed on trunk 2011-08-01 Arnaud Charlet * g-socket-dummy.adb, s-osinte-linu

[Ada] Frontend cleanup

2011-08-01 Thread Arnaud Charlet
This patch does not change the behavior of the compiler. It removes useless code and enforces the assertions associated with attributes Access_Disp_Table and Dispatch_Table_Wrappers to follow their documentation and thus ensure that these attributes are always read from the entity associated with t

[Ada] Conformance for quantified expressions

2011-08-01 Thread Arnaud Charlet
Ada2012 Quantified expressions can appear in default expressions, and must be checked for conformance. The following compilation: gcc -c -gnat12 -gnata conf.adb must yield: conf.adb:16:14: not fully conformant with declaration at line 4 conf.adb:16:14: default expression for "X" does

Re: [Patch 4/4] ARM 64 bit sync atomic operations [V2]

2011-08-01 Thread Ramana Radhakrishnan
On 26 July 2011 10:02, Dr. David Alan Gilbert wrote: > >        gcc/ >        * config/arm/arm.c (TARGET_HAVE_DMB_MCR) MCR Not available in Thumb1 >          but is available on armv6 `:' after (TARGET_HAVE_DMB_MCR) and something like `Disable for Thumb1.' instead of what's on there. > >  /* N

Re: [Patch,AVR]: Supply and use information on skip core bug

2011-08-01 Thread Georg-Johann Lay
Weddington, Eric wrote: >> -Original Message- >> From: Georg-Johann Lay [mailto:a...@gjlay.de] >> Sent: Monday, August 01, 2011 8:38 AM >> To: gcc-patches@gcc.gnu.org >> Cc: Anatoly Sokolov; Denis Chertykov; Weddington, Eric >> Subject: [Patch,AVR]: Supply and use information on skip core b

Re: [RFC] hard-reg-set.h refactoring

2011-08-01 Thread Dimitrios Apostolou
On Sun, 31 Jul 2011, Paolo Bonzini wrote: On Sat, Jul 30, 2011 at 19:21, Dimitrios Apostolou wrote: Nevertheless I'd appreciate comments on whether any part of this patch is worth keeping. FWIW I've profiled this on i386 to be about 4 M instr slower out of ~1.5 G inst. I'll be now checking the

Re: [RFC] hard-reg-set.h refactoring

2011-08-01 Thread Paolo Bonzini
On 08/01/2011 05:57 PM, Dimitrios Apostolou wrote: I don't fully understand the output from -fdump-tree-all, but my conclusion based also on profiler output and objdump, is that both unrolling and inlining is happening in both versions. Nevertheless I can see that assembly output is a bit differ

RE: [Patch,AVR]: Supply and use information on skip core bug

2011-08-01 Thread Weddington, Eric
> -Original Message- > From: Georg-Johann Lay [mailto:a...@gjlay.de] > Sent: Monday, August 01, 2011 9:45 AM > To: Weddington, Eric > Cc: gcc-patches@gcc.gnu.org; Anatoly Sokolov; Denis Chertykov > Subject: Re: [Patch,AVR]: Supply and use information on skip core bug > > > Ok, I removed

[Ada] Wrong dispatching on private type that covers interface

2011-08-01 Thread Arnaud Charlet
If the parent of a private type is an interface type, the parent of its full type declaration is an abstract type that covers such interface, and the order of declaration of the tagged type primitives differs from their order of declaration in the parent (or if not explicitly declared in the parent

[Ada] Compiler crash processing postcondition

2011-08-01 Thread Arnaud Charlet
The compiler crashed processing Ada 2012 pre/post conditions because internally generated declarations associated with the evaluation of the preconditions located in a package spec were not propagated to the corresponding routine in the body of the package. After this patch the following program co

Re: PATCH: PR target/47766: [x32] -fstack-protector doesn't work

2011-08-01 Thread H.J. Lu
On Fri, Jul 29, 2011 at 3:14 PM, H.J. Lu wrote: > On Thu, Jul 28, 2011 at 1:03 PM, Uros Bizjak wrote: >> On Thu, Jul 28, 2011 at 9:03 PM, H.J. Lu wrote: >> > This patch adds x32 support to UNSPEC_SP_XXX patterns.  OK for trunk? http://gcc.gnu.org/contribute.html#patches >>> >>

[patch] Fix PR tree-optimization/49926

2011-08-01 Thread Ira Rosen
Hi, This patch adds another missing check for SLP reduction detection: we should check that a statement in a reduction chain has either one use inside the loop, or two uses: in the reduction phi node and the loop exit phi node. Bootstrapped and tested on powerpc64-suse-linux. Applied to trunk.

Re: [google] Backport r175347 from trunk to google/gcc-4_6 (issue4835041)

2011-08-01 Thread jingyu
ok http://codereview.appspot.com/4835041/

[MMIX] Hookize PREFERRED_RELOAD_CLASS and PREFERRED_OUTPUT_RELOAD_CLASS

2011-08-01 Thread Anatoly Sokolov
Hi. This patch removes obsolete PREFERRED_RELOAD_CLASS and PREFERRED_OUTPUT_RELOAD_CLASS macros from MMIX back end in the GCC and introduces equivalent TARGET_PREFERRED_RELOAD_CLASS and TARGET_PREFERRED_OUTPUT_RELOAD_CLASS target hooks. Regression tested on mmix-knuth-mmixware. OK to ins

[PATCH, i386]: Fix PR49927, ice in spill_failure, at reload1.c:2120

2011-08-01 Thread Uros Bizjak
Hello! On a register starved i686, the relaxation that we allow DImode values in addresses can lead to register shortages and spill failures. Attached patch puts back the requirement that we allow subregs up to and including WORD_MODE width, nicely packed in a new function. 2011-08-01 Uros Bizj

Re: [MMIX] Hookize PREFERRED_RELOAD_CLASS and PREFERRED_OUTPUT_RELOAD_CLASS

2011-08-01 Thread Richard Henderson
On 08/01/2011 10:08 AM, Anatoly Sokolov wrote: > * config/mmix/mmix.h (PREFERRED_RELOAD_CLASS, > PREFERRED_OUTPUT_RELOAD_CLASS): Remove macro. > * config/mmix/mmix-protos.h (mmix_preferred_reload_class, > mmix_preferred_output_reload_class): Remove. > * confi

Re: Ping: RFA: Fix bug in optimize_mode_switching

2011-08-01 Thread Jeff Law
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 07/31/11 03:25, Joern Rennecke wrote: > This patch has not been reviewed in more than two weeks: > http://gcc.gnu.org/ml/gcc-patches/2011-07/msg00786.html OK. jeff -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuP

Re: C++ PATCH for c++/49813 (__builtin_isinf in constant expression)

2011-08-01 Thread Jason Merrill
Another issue raised in 49813 is that morally_constexpr_builtin_function_p was rejecting __builtin_isinf because it has a variadic signature. I'm changing potential_constant_expression_1 to just allow any built-in function in a constexpr function; if it doesn't expand to a constant, we'll deal

Re: PATCH: PR target/47766: [x32] -fstack-protector doesn't work

2011-08-01 Thread Richard Henderson
> PR target/47766 > * config/i386/i386.md (PTR): New. > (stack_protect_set: Check TARGET_LP64 instead of TARGET_64BIT. > (stack_protect_test): Likewise. > (stack_protect_set_): Replace ":P" with ":PTR". > (stack_tls_protect_set_): Likewise. > (stack_tls_pro

[PATCH] OpenMP 3.1 branch merge

2011-08-01 Thread Jakub Jelinek
Hi! Now that OpenMP 3.1 has been released for a few weeks and what we have on gomp-3_1-branch should be feature complete (though in the future could benefit from various optimizations, in particular: 1) avoid atomic insns for atomic reads and stores if aligned and hw/backend can guarantee atomi

Re: [RFC] Cleanup DW_CFA_GNU_args_size handling

2011-08-01 Thread Georg-Johann Lay
Richard Henderson schrieb: This is related primarily to PR49864 but also to PR49879. The fundamental problem in the first test case is that the AVR target cannot perform (set (stack-pointer-rtx) (plus (stack-pointer-rtx) (const_int large))) where "large" is in fact really quite smal

Re: [RFC] Cleanup DW_CFA_GNU_args_size handling

2011-08-01 Thread Richard Henderson
On 08/01/2011 11:42 AM, Georg-Johann Lay wrote: > Is there a specific reason not to define > ACCUMULATE_OUTGOING_ARGS on AVR? Yes. So that you can use PUSH. But as I said in PR49881, you probably want to provide -maccumulate-outgoing-args. I have a follow-up patch to the last one in that PR...

Re: [PATCH 1/7] Linemap infrastructure for virtual locations

2011-08-01 Thread Dodji Seketeli
Jason Merrill writes: > On 07/16/2011 07:37 AM, Dodji Seketeli wrote: >> +/* Returns the highest location [of a token resulting from macro >> + expansion] encoded in this line table. */ >> +#define LINEMAPS_MACRO_HIGHEST_LOCATION(SET) \ >> + LINEMAPS_HIGHEST_LOCATION(SET, true) >> + >> +/* Re

Fwd: [AVR] Fix PR49881

2011-08-01 Thread Richard Henderson
Dang, forgot to add gcc-patches... Original Message Subject: [AVR] Fix PR49881 Date: Mon, 01 Aug 2011 11:58:32 -0700 From: Richard Henderson To: Denis Chertykov , eric.wedding...@atmel.com CC: a...@gjlay.de The following iteration fixes the two regressions reported in comment 7

Re: [RFC] hard-reg-set.h refactoring

2011-08-01 Thread Dimitrios Apostolou
On Mon, 1 Aug 2011, Paolo Bonzini wrote: On 08/01/2011 05:57 PM, Dimitrios Apostolou wrote: I don't fully understand the output from -fdump-tree-all, but my conclusion based also on profiler output and objdump, is that both unrolling and inlining is happening in both versions. Nevertheless I c

Re: C++ PATCH for c++/49813 (__builtin_isinf in constant expression)

2011-08-01 Thread Paolo Carlini
Thanks a lot, Jason. I applied the below, tested x86_64-linux multilib. Paolo. // 2011-08-01 Paolo Carlini PR c++/49813 * include/c_global/cmath (isinf): Remove workaround. Index: include/c_global/cmath ===

Re: [RFC] Cleanup DW_CFA_GNU_args_size handling

2011-08-01 Thread Denis Chertykov
2011/8/1 Richard Henderson : > On 08/01/2011 11:42 AM, Georg-Johann Lay wrote: >> Is there a specific reason not to define >> ACCUMULATE_OUTGOING_ARGS on AVR? I havn't define ACCUMULATE_OUTGOING_ARGS because AVR have a very small displacement for memory addressing (63 bytes) and I think that bette

Re: [PATCH] Propagate source locations from function_decls to their template_decls

2011-08-01 Thread Jeffrey Yasskin
Thanks. Committed to gcc-4_6-branch in r176851 and the google/gcc-4_6 branch in r177072. On Wed, Jul 27, 2011 at 11:46 AM, Jason Merrill wrote: > Yes. > > Jeffrey Yasskin wrote: > > Thanks. I'll commit to trunk in the morning when I can be around to > watch for breakage. > > Is this also ok for

C++ PATCH for c++/49932 (ICE mangling decltype()::)

2011-08-01 Thread Jason Merrill
Needed to add mangling and demangling support for the recently added support for decltype as a nested-name-specifier. Tested x86_64-pc-linux-gnu, applying to trunk. commit fe8dd6eeab2b171504b87937021eb39a13828b77 Author: Jason Merrill Date: Mon Aug 1 16:16:20 2011 -0400 PR c++/49932

C++ PATCH for c++/49924 (constexpr rejects-valid with array member)

2011-08-01 Thread Jason Merrill
cxx_eval_vec_init_1 was assuming that any CONSTRUCTOR would be for the element type, which is silly in this context because an array initializer is also a CONSTRUCTOR. Oops. While I was fixing this I also changed value-initialization to be pre-evaluated like default-initialization. Tested x

Re: PATCH: Add x32 libstdc++-v3 symbols

2011-08-01 Thread Paolo Carlini
Hi, Hi, This patch adds x32 libstdc++-v3 symbols. OK for trunk? I can't really check this but OK. Paolo.

[PATCH] bootstrap/49914

2011-08-01 Thread Paolo Carlini
Hi, I bootstrapped and I'm currently finishing testing on x86_64-linux the below. Is it Ok for mainline? Thanks, Paolo. /// 2011-08-02 Paolo Carlini PR bootstrap/49914 * fold-const.c (fold_plusminus_mult_expr): Use abs_hwi instead of abs.

Re: [PATCH] bootstrap/49914

2011-08-01 Thread Paolo Carlini
... oops, due to a missing space I missed an occurrence of abs in gimple_expand_builtin_pow. I'm restarting bootstrap and test with the below. Paolo. /// Index: fold-const.c === --- fold-const.c(revision 177

Re: [Patch, i386, testsuite] Fix for PR49547, new tescases for lzcnt instruction

2011-08-01 Thread H.J. Lu
On Mon, Aug 1, 2011 at 6:13 AM, Kirill Yukhin wrote: > Done. > Updated patch is attached. > > Thanks, K > > On Mon, Aug 1, 2011 at 4:49 PM, H.J. Lu wrote: >> On Mon, Aug 1, 2011 at 5:36 AM, Kirill Yukhin >> wrote: >>> Hi HJ, >>> Thanks for input. I've missed it. >>> Done. Updated patch is attac

Re: [RFC] Cleanup DW_CFA_GNU_args_size handling

2011-08-01 Thread Richard Henderson
Testing on h8300, newlib/libm/math/ef_j0.c revealed a crash. The problem is that PREV turned out to be unlinked when we came to fixup_args_size_notes (prev, PREV_INSN (next), INTVAL (XEXP (p, 0))); I'm not sure how this didn't previousl

Remove line 0 hack in cp/decl.c (issue4835047)

2011-08-01 Thread Gabriel Charette
This hack, has described in more details in the email labeled "Line 0 Hack??", was now causing problem when serializing the line_table in pph. According to the revision history: this was introduced by steven in 2005: commit ba821eb102fc1a654c0542fcba73898340a9a02d Author: steven Date

Re: [google][patch] Put make_heap's declaration on a single line to work around inconsistent debug locations

2011-08-01 Thread Jeffrey Yasskin
And reverted in r177083 because I fixed the underlying problem. On Fri, Jul 22, 2011 at 11:06 PM, Ollie Wild wrote: > Ok for inclusion in google/gcc-4_6. > > Ollie > > On Fri, Jul 22, 2011 at 5:46 PM, Jeffrey Yasskin wrote: >> >> For the google/gcc-4_6 branch _only_. I'll fix the inconsistency i

RE: [RFC] Add middle end hook for stack red zone size

2011-08-01 Thread Jiangning Liu
Hi Jakub, Appreciate for your valuable comments! I think SPARC V9 ABI doesn't have red zone defined, right? So stack_red_zone_size should be defined as zero by default, the scheduler would block moving memory accesses across stack adjustment no matter what the offset is. I don't see any risk here

Re: [PATCH 1/7] Linemap infrastructure for virtual locations

2011-08-01 Thread Jason Merrill
On 07/16/2011 10:37 AM, Dodji Seketeli wrote: As locations of macro locations decrease monotonically we need LINEMAPS_MACRO_HIGHEST_LOCATION (used in linemap_enter_macro) for reasons that are similar to why we need LINEMAPS_ORDINARY_HIGHEST_LOCATION. Ah, I see, I was missing the use in linemap_

[PATCH 0/2] Fix PR47594

2011-08-01 Thread Sebastian Pop
Hi Richi, These two patches passed regstrap on amd64-linux: Use build_zero_cst or build_one_cst. Fix PR47594: Build signed niter expressions Ok for trunk? Thanks, Sebastian

[PATCH 1/2] Use build_zero_cst or build_one_cst.

2011-08-01 Thread Sebastian Pop
--- gcc/tree-ssa-loop-niter.c | 32 1 files changed, 16 insertions(+), 16 deletions(-) diff --git a/gcc/tree-ssa-loop-niter.c b/gcc/tree-ssa-loop-niter.c index 4acfc67..2ee3f6e 100644 --- a/gcc/tree-ssa-loop-niter.c +++ b/gcc/tree-ssa-loop-niter.c @@ -101,7 +101

[PATCH 2/2] Fix PR47594: Build signed niter expressions

2011-08-01 Thread Sebastian Pop
2011-07-23 Sebastian Pop PR middle-end/47594 * graphite-scop-detection.c (graphite_can_represent_scev): Return false on TYPE_UNSIGNED. * graphite-sese-to-poly.c (scan_tree_for_params_int): Do not call double_int_sext. * tree-ssa-loop-niter.c (numb

[RS6000] Fix ICE in reg_save

2011-08-01 Thread Alan Modra
Seen when running binutils testsuite on powerpc-linux. .../ld-elfvers/vers24b.c: In function 'foo': .../ld-elfvers/vers24b.c:5:1: internal compiler error: in reg_save, at dwarf2cfi.c:827 Bootstrapped and regression tested powerpc-linux. Committed as obvious. * config/rs6000/rs6000.c (rs