Re: [buildrobot] ARM: Missing initializers for Cortex A8

2014-04-25 Thread Kyrill Tkachov
On 24/04/14 22:07, Jan-Benedict Glaw wrote: Hi! Seems the new cost model for Cortex A8 is missing two initializer fields: g++ -c -g -O2 -DIN_GCC -DCROSS_DIRECTORY_STRUCTURE -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing

Re: How can I generate a new function at compile time?

2014-04-25 Thread Richard Biener
On Thu, Apr 24, 2014 at 6:00 PM, Benedikt Huber wrote: > Hi! > > I want to uninline some basic blocks to a separate function to aid slp > vectorization. > The new pass runs just before the slp vectorization pass. > As a first try I create an new and empty function. > Which in turn will be filled

Re: [RFC] Meta-description for tree and gimple folding

2014-04-25 Thread Richard Biener
On Thu, 24 Apr 2014, Jeff Law wrote: > On 02/28/14 08:21, Kai Tietz wrote: > > Hmm, this all reminds me about the approach Andrew Pinski and I came > > up with two years ago. All in all I think it might be worth to > > express folding-patterns in a more abstract way. So the md-like Lisp > > syn

RE: [Testsuite] getpid in gcc.c-torture/execute/pr58419.c

2014-04-25 Thread Dhakshinamoorthy, Soundararajan
Hi, I have attached a patch based on the recommendation. Can you please review and apply, if it looks ok ?. I don't have commit access. gcc/testsuite/ChangeLog 2014-04-25 Soundararajan Dhakshinamoorthy * gcc.c-torture/execute/pr58419.c: Adjust the test to work with bare metal tar

IPA: Devirtualization versus placement new

2014-04-25 Thread Andrew Haley
Summary: Devirtualization uses type information to determine if a virtual method is reachable from a call site. If type information indicates that it is not, devirt marks the site as unreachable. I think this is wrong, and it breaks some programs. At least, it should not do this if the user spec

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jonathan Wakely
On 25 April 2014 11:22, Andrew Haley wrote: > Summary: Devirtualization uses type information to determine if a > virtual method is reachable from a call site. If type information > indicates that it is not, devirt marks the site as unreachable. I > think this is wrong, and it breaks some program

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Martin Jambor
Hi, On Fri, Apr 25, 2014 at 11:22:22AM +0100, Andrew Haley wrote: > Summary: Devirtualization uses type information to determine if a > virtual method is reachable from a call site. If type information > indicates that it is not, devirt marks the site as unreachable. I > think this is wrong, an

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Richard Biener
On Fri, Apr 25, 2014 at 1:18 PM, Jonathan Wakely wrote: > On 25 April 2014 11:22, Andrew Haley wrote: >> Summary: Devirtualization uses type information to determine if a >> virtual method is reachable from a call site. If type information >> indicates that it is not, devirt marks the site as unr

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jonathan Wakely
On 25 April 2014 13:01, Richard Biener wrote: > On Fri, Apr 25, 2014 at 1:18 PM, Jonathan Wakely > wrote: >> On 25 April 2014 11:22, Andrew Haley wrote: >>> Summary: Devirtualization uses type information to determine if a >>> virtual method is reachable from a call site. If type information >>>

SPARC LEON3 and CAS instruction

2014-04-25 Thread Sebastian Huber
Hello, recent GCC versions support the C11 atomic operations for the SPARC LEON3 processor via the CASA instruction. GCC emits CASA instructions with an ASI of 0x80. I think this is due to the usage of "cas" if I get the stuff in sync.md right: "(define_insn "*atomic_compare_and_swap_1"

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Andrew Haley
On 04/25/2014 01:01 PM, Richard Biener wrote: > I agree, -fstrict-aliasing has nothing to do with this. Sounds simply like > a genuine bug (please open a bugzilla). http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60965 Andrew.

Stack offset computation for incoming arguments.

2014-04-25 Thread Umesh Kalappa
Hi All, Our private backend has the macro defined as #define FIRST_PARM_OFFSET(FNDECL) (get_frame_size() + STARTING_FRAME_OFFSET + RETURN_BYTES ) #define STARTING_FRAME_OFFSET 1 #define STACK_POINTER_REGNUM10 #define FRAME_POINTER_REGNUM STACK_POINTER_REGNUM #define ARG_POINTER_REGNUM

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Volker Simonis
On Fri, Apr 25, 2014 at 2:05 PM, Jonathan Wakely wrote: >On 25 April 2014 13:01, Richard Biener wrote: >> On Fri, Apr 25, 2014 at 1:18 PM, Jonathan Wakely >> wrote: >>> On 25 April 2014 11:22, Andrew Haley wrote: Summary: Devirtualization uses type information to determine if a virtual

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Andrew Haley
On 04/25/2014 03:14 PM, Volker Simonis wrote: > Could you therefore please re-categorize this as devirt bug. It is an IPA bug. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60965 Andrew.

[GSoC] TYPE stringfied in call to add_operator

2014-04-25 Thread Prathamesh Kulkarni
Hi, I have a daft question to ask. I was looking through genmatch, I couldn't figure out why is tree code class (TYPE) stringified in call to add_operator () ? #define DEFTREECODE (SYM, STRING, TYPE, NARGS) \ add_operator (SYM, #SYM, #TYPE, NARGS) In add_operator() tcc (argument correspo

How to access points-to information for function pointers

2014-04-25 Thread Swati Rathi
Hello, I am trying to print points-to information for SSA variables as below. for (i = 1; i < num_ssa_names; i++) { tree ptr = ssa_name (i); struct ptr_info_def *pi; if (ptr == NULL_TREE || SSA_NAME_IN_FREE_LIST (ptr)) continue; pi = SSA_NAME_PTR

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jan Hubicka
> Summary: Devirtualization uses type information to determine if a > virtual method is reachable from a call site. If type information > indicates that it is not, devirt marks the site as unreachable. I > think this is wrong, and it breaks some programs. At least, it should > not do this if the

Re: Stack offset computation for incoming arguments.

2014-04-25 Thread Eric Botcazou
> #define FIRST_PARM_OFFSET(FNDECL) (get_frame_size() + > STARTING_FRAME_OFFSET + RETURN_BYTES ) I don't think that you can define FIRST_PARM_OFFSET like so, you need to have a fixed FIRST_PARM_OFFSET (for some definition of fixed) and eliminate the argument pointer during reload. -- Eric Bo

Re: SPARC LEON3 and CAS instruction

2014-04-25 Thread Eric Botcazou
> recent GCC versions support the C11 atomic operations for the SPARC LEON3 > processor via the CASA instruction. GCC emits CASA instructions with an ASI > of 0x80. I think this is due to the usage of "cas" if I get the stuff in > sync.md right: > > "(define_insn "*atomic_compare_and_swap_1" >

Re: SPARC LEON3 and CAS instruction

2014-04-25 Thread Daniel Gutson
On Fri, Apr 25, 2014 at 1:31 PM, Eric Botcazou wrote: >> recent GCC versions support the C11 atomic operations for the SPARC LEON3 >> processor via the CASA instruction. GCC emits CASA instructions with an ASI >> of 0x80. I think this is due to the usage of "cas" if I get the stuff in >> sync.md

Re: [GSoC] TYPE stringfied in call to add_operator

2014-04-25 Thread Richard Biener
On April 25, 2014 4:54:28 PM CEST, Prathamesh Kulkarni wrote: >Hi, >I have a daft question to ask. I was looking through genmatch, I >couldn't figure out why is tree code class (TYPE) stringified in call >to add_operator () ? > >#define DEFTREECODE (SYM, STRING, TYPE, NARGS) \ >add_operat

Re: [GSoC] TYPE stringfied in call to add_operator

2014-04-25 Thread Prathamesh Kulkarni
On Fri, Apr 25, 2014 at 10:12 PM, Richard Biener wrote: > On April 25, 2014 4:54:28 PM CEST, Prathamesh Kulkarni > wrote: >>Hi, >>I have a daft question to ask. I was looking through genmatch, I >>couldn't figure out why is tree code class (TYPE) stringified in call >>to add_operator () ? >>

Re: How to access points-to information for function pointers

2014-04-25 Thread Richard Biener
On April 25, 2014 5:54:09 PM CEST, Swati Rathi wrote: >Hello, > >I am trying to print points-to information for SSA variables as below. > > for (i = 1; i < num_ssa_names; i++) > { > tree ptr = ssa_name (i); > struct ptr_info_def *pi; > > if (ptr == NULL_TREE > ||

Re: [GSoC] TYPE stringfied in call to add_operator

2014-04-25 Thread Richard Biener
On April 25, 2014 6:56:00 PM CEST, Prathamesh Kulkarni wrote: >On Fri, Apr 25, 2014 at 10:12 PM, Richard Biener > wrote: >> On April 25, 2014 4:54:28 PM CEST, Prathamesh Kulkarni > wrote: >>>Hi, >>>I have a daft question to ask. I was looking through genmatch, I >>>couldn't figure out why is

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jan Hubicka
> On 04/25/2014 03:14 PM, Volker Simonis wrote: > > Could you therefore please re-categorize this as devirt bug. > > It is an IPA bug. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60965 Now when I have interest from ubsan direction, I wanted to ask. Would it make sense to turn those unreachables

Variadic functions arguments passing

2014-04-25 Thread Umesh Kalappa
Hi All, In our private port ,we define function_arg hook to pass the first three args in the reg and rest will go to stack. But for variadic functions the arguments need to pass through the stack. How we can achieve this ?? Any inputs will be appreciate. Thank you ~Umesh

Re: Stack offset computation for incoming arguments.

2014-04-25 Thread Umesh Kalappa
Thank you Eric for the inputs and will make the required changes. Thank you Again ~Umesh On Fri, Apr 25, 2014 at 9:58 PM, Eric Botcazou wrote: >> #define FIRST_PARM_OFFSET(FNDECL) (get_frame_size() + >> STARTING_FRAME_OFFSET + RETURN_BYTES ) > > I don't think that you can define FIRST_PARM_OFF

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jakub Jelinek
On Fri, Apr 25, 2014 at 08:23:22PM +0200, Jan Hubicka wrote: > > On 04/25/2014 03:14 PM, Volker Simonis wrote: > > > Could you therefore please re-categorize this as devirt bug. > > > > It is an IPA bug. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60965 > > Now when I have interest from ubsan di

Re: IPA: Devirtualization versus placement new

2014-04-25 Thread Jan Hubicka
> On Fri, Apr 25, 2014 at 08:23:22PM +0200, Jan Hubicka wrote: > > > On 04/25/2014 03:14 PM, Volker Simonis wrote: > > > > Could you therefore please re-categorize this as devirt bug. > > > > > > It is an IPA bug. http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60965 > > > > Now when I have interest

Re: Variadic functions arguments passing

2014-04-25 Thread Ian Lance Taylor
On Fri, Apr 25, 2014 at 11:27 AM, Umesh Kalappa wrote: > > In our private port ,we define function_arg hook to pass the first > three args in the reg and rest will go to stack. > > But for variadic functions the arguments need to pass through the stack. > > How we can achieve this ?? Any inp