Re: [PATCH] ICF: move readonly decision for variables to the right place

2015-03-01 Thread Jan Hubicka
Hi, this is a variant of patch I commited. It takes care to load the constructor to memory in sem_variable::equals and donot touch it earlier. I also made sem_variable::parse to skip volatile and reigster variables. Bootstrapped/regtested x86_64-linux, lto-bootstrapped with -fmerge-all-constants

Re: [PATCH] PR target/65248: [5 Regression] Copy relocation in PIE against protected symbol

2015-03-01 Thread Uros Bizjak
On Sat, Feb 28, 2015 at 5:42 PM, H.J. Lu wrote: > Ue copy relocation in PIE improves performance. But copy relocation > can't be used to access protected symbols defined in shared libaries > and linker in binutils 2.26 enforces doesn't allow it. GCC doesn't > know if an external definition is pr

Re: [PATCH] PR target/65248: [5 Regression] Copy relocation in PIE against protected symbol

2015-03-01 Thread Alan Modra
On Sun, Mar 01, 2015 at 07:33:14AM -0800, H.J. Lu wrote: > +mcopyreloc-in-pie I'm not calling for a change in the name of the option (*), but technically it isn't completely correct to call your optimisation "copy reloc in pie". What you are really doing is using a linker generated variable (in .

[patch/committed] PR middle-end/65233 make walk-ssa_copies handle empty PHIs

2015-03-01 Thread Aldy Hernandez
As I mention in the PR... What's happening here is that the ipa_polymorphic_call_context constructor is calling walk_ssa_copies on a PHI node that has no arguments. This happens because finalize_jump_threads eventually removes some PHI arguments as it's redirecting some edges, leaving a PHI

Re: [RFC 1/2] Turn RETURN_ADDR_IN_PREVIOUS_FRAME into C expression

2015-03-01 Thread Max Filippov
On Mon, Mar 2, 2015 at 1:07 AM, Joseph Myers wrote: > > On Sat, 28 Feb 2015, Max Filippov wrote: > > > This allows a target to support both windowed and non-windowed ABI. > > > > 2015-02-28 Max Filippov > > > > gcc/ > > * builtins.c (expand_builtin_return_addr): Add > > RETURN_ADDR_

Re: Strengthen ICF hash

2015-03-01 Thread Andi Kleen
Jan Hubicka writes: > > The hash itself is quite simple (borrowing incremental hash for constants > adding > very simple match for other stuff + logic to skip things that may match even > if > they are syntactticaly different). The hash can be strenghtened significantly, > but I suppose we may d

[PATCH][ARM]Automatically add -mthumb for thumb-only target when mode isn't specified

2015-03-01 Thread Terry Guo
Hi there, If target mode isn't specified via either gcc configuration option --with-mode or command line, this patch intends to improve gcc driver to automatically add option -mthumb for thumb-only target. Tested with gcc regression test for various arm targets, no regression. Is it OK? BR, Terry

Re: [PATCH] ICF: move readonly decision for variables to the right place

2015-03-01 Thread Jan Hubicka
Hi, my comments to your patch was not complete. ipa-icf is quite confused about how to get the constructor. This is how it works: In during in_lto_p DECL_INITIAL may be set to error_mark_node and once you really want to have the constructor there is varpool_node->get_constuctor method. Because in

Re: [PATCH] ICF is more strict about non-common function and var, attributes.

2015-03-01 Thread Jan Hubicka
> > >and thus we will hapilly merge types with different TYPE_ALIGN. > > >Should func_checker::types_compatible be extended to compare these? > > >Clearly TYPE_ALIGN matters for vectorizer and other plaes... > > > > But it matters on MEM_REFs only, and you can't use canonical types for that. > >

Re: [PATCH] ICF is more strict about non-common function and var, attributes.

2015-03-01 Thread Jan Hubicka
> >and thus we will hapilly merge types with different TYPE_ALIGN. > >Should func_checker::types_compatible be extended to compare these? > >Clearly TYPE_ALIGN matters for vectorizer and other plaes... > > But it matters on MEM_REFs only, and you can't use canonical types for that. > And we don't

[Patch, Fortran] Fix ATOMIC checks

2015-03-01 Thread Tobias Burnus
This patch changes the coarray/coindexed check to match what the error message already claimed. OK for the trunk? Tobias diff --git a/gcc/fortran/check.c b/gcc/fortran/check.c index 3be4fb1..cdb5ff1 100644 --- a/gcc/fortran/check.c +++ b/gcc/fortran/check.c @@ -1022,7 +1022,7 @@ gfc_check_atomi

[PATCH] Fix PR c++/65154 (ICE on braced initializer)

2015-03-01 Thread Mikhail Maltsev
The following patch is supposed to fix the problem related to initializing an array of aggregates with members, which have user-defined default constructors. Bootstrapped and regtested on x86_64-unknown-linux-gnu. diff --git a/gcc/cp/init.c b/gcc/cp/init.c index 0274663..0f53146 100644 --- a/gcc/

Re: [RFC 1/2] Turn RETURN_ADDR_IN_PREVIOUS_FRAME into C expression

2015-03-01 Thread Joseph Myers
On Sat, 28 Feb 2015, Max Filippov wrote: > This allows a target to support both windowed and non-windowed ABI. > > 2015-02-28 Max Filippov > > gcc/ > * builtins.c (expand_builtin_return_addr): Add > RETURN_ADDR_IN_PREVIOUS_FRAME to 'if' condition. If you change the semantics of a

Re: [PATCH] ubsan: improve bounds checking, add -fsanitize=bounds-strict

2015-03-01 Thread Martin Uecker
Bootstrap and regression tested on x86_64. A ubsan-bootstrap for C and C++ works too (although there are other unrelated runtime errors). I tried a bootstrap with -fsanitize=bounds-strict and there are indeed many additional runtime errors due the struct hack with last array element of size 1

Strengthen ICF hash

2015-03-01 Thread Jan Hubicka
Hi, getting more familiar with ipa-icf I start to understand why it is a compile time hog for firefox. I assumed it spends most of time streaming in bodies and comparing them to see they are equivalent (after all about 10% of all symbols turns out to be and each of that needs to be read to memory)

Re: [Patch, fortran] PR60898 premature release of entry symbols

2015-03-01 Thread Paul Richard Thomas
Dear Mikael, That looks to be OK for 4.8, 4.9 and 5.0. Strange testcase, though... :-) Thanks for the patch Paul On 15 February 2015 at 18:48, Mikael Morin wrote: > Hello, > > I propose a fix for PR60898, where a symbol is freed despite remaining > reachable in the symbol tree. > The problem

Re: [PATCH] Fix for PR ipa/65245

2015-03-01 Thread Jan Hubicka
Hi, here is a variant of patch I intend to commit after x86_64 bootstrap®test and LTO-bootstrap. What i changed are the ipa-icf-gimple.c bits (dorpping all comparsions relying that external references are already matched and used at same spots). Second change is sem_function::compare_cgraph_refere

New Swedish PO file for 'gcc' (version 5.1-b20150208)

2015-03-01 Thread Translation Project Robot
Hello, gentle maintainer. This is a message from the Translation Project robot. A revised PO file for textual domain 'gcc' has been submitted by the Swedish team of translators. The file is available at: http://translationproject.org/latest/gcc/sv.po (This file, 'gcc-5.1-b20150208.sv.po',

[patch] FreeBSD powerpc64 remove 32-bit soft-float multilibs.

2015-03-01 Thread Andreas Tobler
Hi all, the appended patch removes the soft-float multilib build option from powerpc64-*-freebsd*. These libraries are rarely to never used on 64-bit FreeBSD PowerPC machines. But the build time of these libraries counts. Is this ok for trunk? If yes, at what stage can I commit, 5.0/5.1? T

[SH][committed] Add test case for PR 61142

2015-03-01 Thread Oleg Endo
Hi, This adds a test case for PR 61142. Tested with make -k check-gcc RUNTESTFLAGS="sh.exp=pr61142.c --target_board=sh-sim \{-m2/-ml,-m2/-mb,-m2a/-mb,-m4/-ml,-m4/-mb,-m4a/-ml,-m4a/-mb}" Committed as r221089. Cheers, Oleg gcc/testsuite/ChangeLog: PR target/61142 * gcc.target/sh/s

[c-family] Fix -fdump-ada-spec ICEs

2015-03-01 Thread Eric Botcazou
They were introduced by the latest tree structure re-shuffling. Tested on x86_64-suse-linux, applied on the mainline as obvious. 2015-03-01 Eric Botcazou * c-ada-spec.c (is_tagged_type): Add guard for DECL_VINDEX. (dump_template_types): Adjust DECL_TEMPLATE_INSTANTIATIONS and

Re: [PATCH] Fix for PR ipa/65245

2015-03-01 Thread Jan Hubicka
> >From 7cedbe5e3736b9eb7b2fab1b931a7bc9ed269f37 Mon Sep 17 00:00:00 2001 > From: mliska > Date: Fri, 27 Feb 2015 22:42:49 +0100 > Subject: [PATCH 2/4] ICF: Do not consider variable aliases for merge > operation. > > gcc/ChangeLog: > > 2015-02-28 Martin Liska > Jan Hubicka > >

Re: ipa-icf::merge TLC

2015-03-01 Thread Christophe Lyon
On 27 February 2015 at 21:49, Jan Hubicka wrote: >> >> ../sysdeps/gnu/siglist.c:72:1: internal compiler error: in >> address_matters_p, at symtab.c:1908 >> versioned_symbol (libc, __new_sys_sigabbrev, sys_sigabbrev, GLIBC_2_3_3); >> ^ >> 0x66a080 symtab_node::address_matters_p() >> /scr

Re: [PATCH] PR target/65248: [5 Regression] Copy relocation in PIE against protected symbol

2015-03-01 Thread H.J. Lu
On Sat, Feb 28, 2015 at 5:27 PM, Sandra Loosemore wrote: > On 02/28/2015 09:42 AM, H.J. Lu wrote: >> >> @@ -22704,6 +22705,13 @@ For systems that use the GNU C Library, the >> default is on. >> Specify that the assembler should encode SSE instructions with VEX >> prefix. The option @option{-m

Re: [PATCH] Fix for PR ipa/65245

2015-03-01 Thread Martin Liška
On 02/28/2015 11:41 PM, Jan Hubicka wrote: >> Hello. >> >> Following patch skips all variable aliases as potential merge candidates. >> Tested on x86_64-linux. >> >> Ready for trunk? >> Thanks, >> Martin > >> >From fbde2e98f98a71105d18cf3e91e8032d0c657139 Mon Sep 17 00:00:00 2001 >> From: mliska

Re: [PING] [wwwdocs, patch] Add libgccjit to gcc-5/changes.html

2015-03-01 Thread Gerald Pfeifer
On Sun, 1 Mar 2015, Tobias Burnus wrote: >> Ping re: https://gcc.gnu.org/ml/gcc-patches/2015-02/msg00371.html > While it would be nice if Gerald could find the time to review the patch, > I recall that he once said that maintainers don't need approvals for > release-notes changes of their part of

Re: [PING] [wwwdocs, patch] Add libgccjit to gcc-5/changes.html

2015-03-01 Thread Tobias Burnus
David Malcolm wrote: On Thu, 2015-02-05 at 21:47 -0500, David Malcolm wrote: This patch adds an -level section about libgccjit between the sections on languages and targets. It has various links to the documentation (now that that's on the website), and to a couple of 3rd party repos (the Pytho

Re: [PATCH] ICF is more strict about non-common function and var, attributes.

2015-03-01 Thread Richard Biener
On March 1, 2015 1:09:50 AM CET, Jan Hubicka wrote: >> > >> > Half of FAILs are gone, but the rest is correctly merged (alignment >matches). Thus I would omit ICF >> > in this testcase. I'm going to install the patch. > >Richard, I wonder what happens with TYPE_ALIGN at LTO. It is not part >of c