[PATCH] cpuid check code in libgcc, fix cpuinfo code for sandybridge detection

2013-03-07 Thread Sriraman Tallam
Hi, I committed this simple patch to check for sandybridge processors when cpuid model number is 0x2d. This is the model for SandyBridge-E processors : http://software.intel.com/en-us/articles/intel-architecture-and-processor-identification-with-cpuid-model-and-family-numbers Index: config/i

Re: [google][4.7] Minor Function reordering plugin enhancements.

2013-02-13 Thread Sriraman Tallam
Updated patch attached. Thanks Sri On Wed, Feb 13, 2013 at 4:39 PM, Sriraman Tallam wrote: > On Wed, Feb 13, 2013 at 4:32 PM, Xinliang David Li wrote: >> when split_segment is specified but the API does not exist, why not >> making it fatal ? Will it crash at some point when t

Re: [google][4.7] Minor Function reordering plugin enhancements.

2013-02-13 Thread Sriraman Tallam
stered. I will make this fatal too however. Thanks Sri > > David > > On Wed, Feb 13, 2013 at 4:19 PM, Sriraman Tallam wrote: >> Hi, >> >>I have attached a patch for the reordering plugin to display >> appropriate error messages when incorrect options

[google][4.7] Minor Function reordering plugin enhancements.

2013-02-13 Thread Sriraman Tallam
Hi, I have attached a patch for the reordering plugin to display appropriate error messages when incorrect options are passed or when some API is unavailable. The plugin will use the ld_plugin_message linker API to flag errors (fatal or non-fatal) when incorrect options are passed or when t

Re: [PATCH] Multiversioning fixes (PR c++/55742, take 2)

2013-02-13 Thread Sriraman Tallam
On Wed, Feb 13, 2013 at 12:14 PM, Jakub Jelinek wrote: > On Wed, Feb 13, 2013 at 10:57:42AM -0800, Sriraman Tallam wrote: >> I committed a trivial patch to fix this problem. mv12-aux.C is >> auxiliary to mv12.C and should have the same test directives as >> mv12.C. >&

Re: [PATCH] Multiversioning fixes (PR c++/55742, take 2)

2013-02-13 Thread Sriraman Tallam
On Wed, Feb 13, 2013 at 7:46 AM, Sriraman Tallam wrote: > > On Feb 13, 2013 1:21 AM, "Andreas Schwab" wrote: >> >> Sriraman Tallam writes: >> >> > Index: gcc/testsuite/g++.dg/ext/mv12-aux.C >> > =

Sync include/plugin-api.h with the copy in binutils

2013-02-11 Thread Sriraman Tallam
Hi, This patch was approved by Ian: http://sourceware.org/ml/binutils/2013-02/msg00136.html I have synced plugin-api.h * plugin-api.h (enum ld_plugin_level): Assign integers explicitly for all values. Index: include/plugin-api.h ==

Re: [PATCH] Multiversioning fixes (PR c++/55742, take 2)

2013-02-11 Thread Sriraman Tallam
Hi, Is this alright to commit? Thanks Sri On Thu, Feb 7, 2013 at 4:10 PM, Sriraman Tallam wrote: > On Thu, Feb 7, 2013 at 6:29 AM, Jason Merrill wrote: >> On 02/06/2013 08:39 PM, Sriraman Tallam wrote: >>> >>> +// Test to check if an error is generated when vi

Re: [PATCH] Multiversioning fixes (PR c++/55742, take 2)

2013-02-07 Thread Sriraman Tallam
On Thu, Feb 7, 2013 at 6:29 AM, Jason Merrill wrote: > On 02/06/2013 08:39 PM, Sriraman Tallam wrote: >> >> +// Test to check if an error is generated when virtual functions >> +// are multiversioned. > > > This seems like a TODO, rather than something to test for.

Re: [PATCH] Multiversioning fixes (PR c++/55742, take 2)

2013-02-06 Thread Sriraman Tallam
Hi, I have attached a patch documenting Function Multiversioning and added a few more tests. I have also updated the wiki http://gcc.gnu.org/wiki/FunctionMultiVersioning. Please let me know if there are any more tests you specifically want. Please review. Thanks Sri On Wed, Jan 30, 2013 at

Re: [google][4.7] Allow function reordering linker plugin to separate hot and cold code into different ELF segments

2013-01-04 Thread Sriraman Tallam
s invoked. The gold linker has a test case to check if the segment API actually splits segments. Thanks, -Sri. > > David > > > On Fri, Jan 4, 2013 at 2:19 PM, Sriraman Tallam wrote: >> Attached new patch. >> >> Thanks, >> -Sri. >> >> On Fri, Jan

Re: [google][4.7] Allow function reordering linker plugin to separate hot and cold code into different ELF segments

2013-01-04 Thread Sriraman Tallam
the option to something like: >> >> split_segment|nosplit-segment >> or split_segment=yes|no >> >> >> David >> >> On Thu, Jan 3, 2013 at 5:41 PM, Sriraman Tallam wrote: >>> Hi Rong, >>> >>> The following patch modif

Re: [google][4.7] Allow function reordering linker plugin to separate hot and cold code into different ELF segments

2013-01-03 Thread Sriraman Tallam
, Sriraman Tallam wrote: > I have committed this patch. > > Thanks, > -Sri. > > On Fri, Dec 14, 2012 at 4:16 PM, Rong Xu wrote: >> Looks good to me for google/gcc-4_7 branch. >> >> Thanks, >> >> -Rong >> >> >> On Fri, Dec 14, 201

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2013-01-02 Thread Sriraman Tallam
On Wed, Jan 2, 2013 at 1:01 PM, Jakub Jelinek wrote: > On Wed, Jan 02, 2013 at 12:23:45PM -0800, Sriraman Tallam wrote: >> --- config/i386/i386.c (revision 194817) >> +++ config/i386/i386.c (working copy) >> @@ -29290,7 +29290,7 @@ ix86_get_function_versions_d

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2013-01-02 Thread Sriraman Tallam
On Wed, Jan 2, 2013 at 1:01 PM, Jakub Jelinek wrote: > On Wed, Jan 02, 2013 at 12:23:45PM -0800, Sriraman Tallam wrote: >> --- config/i386/i386.c (revision 194817) >> +++ config/i386/i386.c (working copy) >> @@ -29290,7 +29290,7 @@ ix86_get_function_versions_d

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2013-01-02 Thread Sriraman Tallam
AM, Andreas Schwab wrote: > diff --git a/gcc/ChangeLog b/gcc/ChangeLog > index 148388d..575e03a 100644 > --- a/gcc/ChangeLog > +++ b/gcc/ChangeLog > @@ -1,4 +1,7 @@ > -<<<<<<< .mine > +2012-12-27 Andreas Schwab > + > + * target.def (suppor

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2012-12-27 Thread Sriraman Tallam
+ * target.def (supports_function_versions): Fix typo. > + > 2012-12-26 Sriraman Tallam > > * doc/tm.texi.in (TARGET_OPTION_SUPPORTS_FUNCTION_VERSIONS): Document > @@ -15,12 +18,10 @@ > * (is_function_default_version): Check target strin

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2012-12-26 Thread Sriraman Tallam
I committed this patch with the fix. Thanks, -Sri. On Tue, Dec 18, 2012 at 4:13 PM, Diego Novillo wrote: > On Tue, Dec 18, 2012 at 6:38 PM, Sriraman Tallam wrote: > >> The function versions are now determined purely based on the string >> value and not on DECL_FUNCTION_SPEC

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2012-12-18 Thread Sriraman Tallam
Hi Diego, Thanks for the review. On Tue, Dec 18, 2012 at 8:04 AM, Diego Novillo wrote: > On 2012-11-16 14:55 , Sriraman Tallam wrote: >> >> Hi, >> >> The previous patch was incomplete because the front-end strips off >> invalid target attributes which

Re: [google][4.7] Allow function reordering linker plugin to separate hot and cold code into different ELF segments

2012-12-17 Thread Sriraman Tallam
I have committed this patch. Thanks, -Sri. On Fri, Dec 14, 2012 at 4:16 PM, Rong Xu wrote: > Looks good to me for google/gcc-4_7 branch. > > Thanks, > > -Rong > > > On Fri, Dec 14, 2012 at 3:42 PM, Sriraman Tallam > wrote: >> >> Hi Rong, >> >>

[google][4.7] Allow function reordering linker plugin to separate hot and cold code into different ELF segments

2012-12-14 Thread Sriraman Tallam
Hi Rong, Please review this code. This code allows the function reordering plugin to separate hot and cold code into different ELF segments. This would allow optimizations like mapping the hot code alone to huge pages. With this patch, by default, the plugin maps .text.unlikely sections i

Re: Using -ffunction-sections and -p

2012-12-07 Thread Sriraman Tallam
efetch_loop_arrays > 0) { Thanks, -Sri. On Tue, Dec 4, 2012 at 1:43 PM, Sriraman Tallam wrote: > On Tue, Dec 4, 2012 at 1:31 PM, Jeff Law wrote: >> On 12/03/2012 01:08 PM, Sriraman Tallam wrote: >>> >>> Hi Jeff, >>> >>> Wondering if yo

Re: Using -ffunction-sections and -p

2012-12-04 Thread Sriraman Tallam
On Tue, Dec 4, 2012 at 1:31 PM, Jeff Law wrote: > On 12/03/2012 01:08 PM, Sriraman Tallam wrote: >> >> Hi Jeff, >> >> Wondering if you got a chance to do this? > > Hmm, thinking more about this, it couldn't have been a 32 bit HPUX issue. > First t

Re: [PATCH] Function Multiversioning Bug, checking for function versions

2012-11-16 Thread Sriraman Tallam
Hi, The previous patch was incomplete because the front-end strips off invalid target attributes which I did not consider. The attached updated patch handles this with updated test cases. Thanks, -Sri. On Thu, Nov 15, 2012 at 2:08 PM, Sriraman Tallam wrote: > Hi, > >Currently,

[PATCH] Function Multiversioning Bug, checking for function versions

2012-11-15 Thread Sriraman Tallam
Hi, Currently, function multiversioning determines that two functions are different by comparing the arch type and isa flags that are set after the target string is processed. This leads to cases where the versions become identical when the command-line target options are altered. For example

Re: Using -ffunction-sections and -p

2012-11-14 Thread Sriraman Tallam
On Sun, Nov 4, 2012 at 9:03 PM, Ian Lance Taylor wrote: > On Sun, Nov 4, 2012 at 8:04 PM, Sriraman Tallam wrote: >> >>Currently, using -ffunction-sections and -p together results in a >> warning. I ran into this problem when compiling the kernel. This is >&g

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-11-13 Thread Sriraman Tallam
Patch committed now after making the changes. Thanks, -Sri. On Mon, Nov 12, 2012 at 6:39 PM, Jason Merrill wrote: > On 11/12/2012 08:11 PM, Sriraman Tallam wrote: >> >> + && !targetm.target_option.function_versions (fn, >> +TREE_PURPO

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-11-12 Thread Sriraman Tallam
Hi Jason, Made the changes. Also fixed one more segfault bug when ifunc is not supported. Thanks, -Sri. On Sun, Nov 11, 2012 at 9:04 PM, Jason Merrill wrote: > On 11/09/2012 08:33 PM, Sriraman Tallam wrote: >> >> + /* Skip calling decls_match for vers

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-11-09 Thread Sriraman Tallam
Hi Jason, Made all the changes and attached patch. Ok to commit? Thanks, -Sri. On Tue, Nov 6, 2012 at 7:52 AM, Jason Merrill wrote: > On 11/05/2012 09:38 PM, Sriraman Tallam wrote: >> >> + /* For multi-versioned functions, more than one match is just fine. >

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-11-06 Thread Sriraman Tallam
On Tue, Nov 6, 2012 at 7:52 AM, Jason Merrill wrote: > On 11/05/2012 09:38 PM, Sriraman Tallam wrote: >> >> + /* For multi-versioned functions, more than one match is just fine. >> >> +Call decls_match to make sure they are different because the

Using -ffunction-sections and -p

2012-11-04 Thread Sriraman Tallam
Hi, Currently, using -ffunction-sections and -p together results in a warning. I ran into this problem when compiling the kernel. This is discussed in this thread: http://gcc.gnu.org/ml/gcc-help/2008-11/msg00128.html Ian's reply suggests this warning is no longer necessary and can be removed.

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-10-30 Thread Sriraman Tallam
On Tue, Oct 30, 2012 at 12:10 PM, Jason Merrill wrote: > On 10/27/2012 09:16 PM, Sriraman Tallam wrote: >> >> + /* See if there's a match. For functions that are >> multi-versioned, >> +all the versions match. */ >> if (same_

Re: GCC 4.8.0 Status Report (2012-10-29), Stage 1 to end soon

2012-10-30 Thread Sriraman Tallam
Hi Jakub, My function multiversioning patch is being reviewed and I hope to get this in by Nov. 5. Thanks, -Sri. On Mon, Oct 29, 2012 at 10:56 AM, Jakub Jelinek wrote: > Status > == > > I'd like to close the stage 1 phase of GCC 4.8 development > on Monday, November 5th. If you have st

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-10-29 Thread Sriraman Tallam
On Mon, Oct 29, 2012 at 5:55 AM, Jan Hubicka wrote: >> Index: gcc/cgraph.c >> === >> --- gcc/cgraph.c (revision 192623) >> +++ gcc/cgraph.c (working copy) >> @@ -132,6 +132,74 @@ static GTY(()) struct cgraph_edge *free_edges

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-10-26 Thread Sriraman Tallam
On Fri, Oct 26, 2012 at 9:07 AM, Xinliang David Li wrote: > On Fri, Oct 26, 2012 at 8:54 AM, Jan Hubicka wrote: >> Hi, >> sorry for jumping in late, for too long I did not had chnce to look at my >> TODO. >> I have two comments... >>> Index: gcc/cgraphbuild.c >>>

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-10-05 Thread Sriraman Tallam
On Fri, Oct 5, 2012 at 3:50 PM, Jason Merrill wrote: > On 10/05/2012 05:57 PM, Sriraman Tallam wrote: >> >> In general, the dispatcher is always necessary since it is not known >> what function version will be called at compile time. This is true >> whether it is a

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-10-05 Thread Sriraman Tallam
On Fri, Oct 5, 2012 at 10:43 AM, Jason Merrill wrote: > On 08/24/2012 08:34 PM, Sriraman Tallam wrote: >> >> + /* If the address of a multiversioned function dispatcher is taken, >> + generate the body to dispatch the right function at run-time. This >> >> +

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-09-18 Thread Sriraman Tallam
Ping. On Fri, Aug 24, 2012 at 5:34 PM, Sriraman Tallam wrote: > Hi Jason, > >I have created a new patch to use target hooks for all the > functionality and make the front-end just call the target hooks at the > appropriate places. This is more like what you suggested in a prev

Sync include/plugin-api.h with src/

2012-08-24 Thread Sriraman Tallam
Hi, This patch was approved by Ian: http://sourceware.org/ml/binutils/2012-08/msg00447.html I have synced plugin-api.h with the following patch: * plugin-api.h (ld_plugin_allow_unique_segment_for_sections): New interface. (ld_plugin_unique_segment_for_sections): New in

Re: [wwwdocs] Document Runtime CPU detection builtins

2012-08-21 Thread Sriraman Tallam
/gcc/X86-Built-in-Functions.html#X86-Built-in-Functions Please note that the "_002din" is missing. This makes the link broken, did I miss anything? I verified that I submitted the right link. Thanks, -Sri. On Tue, Aug 21, 2012 at 5:41 AM, Diego Novillo wrote: > On 2012-08-20 22:41 , Sr

Re: [wwwdocs] Document Runtime CPU detection builtins

2012-08-20 Thread Sriraman Tallam
documented in extend.texi. I have attached the patch. If there are no further comments I will submit this tomorrow. Thanks, -Sri. On Mon, Aug 20, 2012 at 1:31 PM, Gerald Pfeifer wrote: > Hi Sriraman, > > On Fri, 10 Aug 2012, Sriraman Tallam wrote: >> I have added a release note f

Re: [wwwdocs] Document Runtime CPU detection builtins

2012-08-20 Thread Sriraman Tallam
Ping. On Tue, Aug 14, 2012 at 11:02 AM, Sriraman Tallam wrote: > +ger...@pfiefer.com > > On Tue, Aug 14, 2012 at 10:51 AM, Sriraman Tallam wrote: >> Hi Gerald, >> >>Is this release note alright? >> >> Thanks, >> -Sri. >> >> On Fri

Re: [wwwdocs] Document Runtime CPU detection builtins

2012-08-14 Thread Sriraman Tallam
+ger...@pfiefer.com On Tue, Aug 14, 2012 at 10:51 AM, Sriraman Tallam wrote: > Hi Gerald, > >Is this release note alright? > > Thanks, > -Sri. > > On Fri, Aug 10, 2012 at 7:20 PM, Sriraman Tallam wrote: >> Hi, >> >>I have added a release

Re: [wwwdocs] Document Runtime CPU detection builtins

2012-08-14 Thread Sriraman Tallam
Hi Gerald, Is this release note alright? Thanks, -Sri. On Fri, Aug 10, 2012 at 7:20 PM, Sriraman Tallam wrote: > Hi, > >I have added a release note for x86 builtins __builtin_cpu_is and > __builtin_cpu_supports. They were checked in to trunk in rev. 186789. > Is th

[wwwdocs] Document Runtime CPU detection builtins

2012-08-10 Thread Sriraman Tallam
Hi, I have added a release note for x86 builtins __builtin_cpu_is and __builtin_cpu_supports. They were checked in to trunk in rev. 186789. Is this ok to submit? Thanks, -Sri. Index: changes.html === RCS file: /cvs/gcc/wwwdocs/htd

[google][gcc-4.7]Revert Old CPU Runtime Detection Implementation (issue6458081)

2012-08-03 Thread Sriraman Tallam
Free Software Foundation, Inc. - Contributed by Sriraman Tallam (tmsri...@google.com) - -This file is part of GCC. - -GCC is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 3,

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-07-30 Thread Sriraman Tallam
On Thu, Jul 19, 2012 at 1:39 PM, Jason Merrill wrote: > > On 07/10/2012 03:14 PM, Sriraman Tallam wrote: >> >> I am using the questions you asked previously >> to explain how I solved each of them. When working on this patch, these >> are the exact questions

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-07-06 Thread Sriraman Tallam
On Fri, Jul 6, 2012 at 2:14 AM, Richard Guenther wrote: > > On Thu, Jun 14, 2012 at 10:13 PM, Sriraman Tallam wrote: > > +cc c++ front-end maintainers > > > > Hi, > > > >C++ Frontend maintainers, Could you please take a look at the > > front-end pa

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-06-19 Thread Sriraman Tallam
Ping. On Thu, Jun 14, 2012 at 1:13 PM, Sriraman Tallam wrote: > +cc c++ front-end maintainers > > Hi, > >   C++ Frontend maintainers, Could you please take a look at the > front-end part when you find the time? > >   Honza, your thoughts on the callgraph part? > >  

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-06-14 Thread Sriraman Tallam
for function versions, along the lines of C++ thunks. Thanks, -Sri. On Mon, Jun 4, 2012 at 11:59 AM, Sriraman Tallam wrote: > Hi, > >   Attaching updated patch for function multiversioning which brings > in plenty of changes. > > * As suggested by Richard earlier, I have ma

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-06-11 Thread Sriraman Tallam
On Wed, Jun 6, 2012 at 6:52 AM, H.J. Lu wrote: > On Tue, Jun 5, 2012 at 3:00 PM, Sriraman Tallam wrote: >> Hi H.J., >> >> I am attaching a patch to add __cpu_indicator_init to the list of >> symbols to be versioned and exported in libgcc_s.so. Also, updating

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-06-05 Thread Sriraman Tallam
PM, Sriraman Tallam wrote: > Patch committed. > > Thanks, > -Sri. > > On Wed, Apr 25, 2012 at 4:52 PM, H.J. Lu wrote: >> On Wed, Apr 25, 2012 at 4:38 PM, Sriraman Tallam wrote: >>> Hi H.J, >>> >>>   Could you please review this patch for AVX2

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-26 Thread Sriraman Tallam
On Sat, May 26, 2012 at 7:06 PM, H.J. Lu wrote: > On Sat, May 26, 2012 at 5:23 PM, Sriraman Tallam wrote: >> On Sat, May 26, 2012 at 4:56 PM, H.J. Lu wrote: >>> On Sat, May 26, 2012 at 3:34 PM, Sriraman Tallam >>> wrote: >>>> On Fri, May 25, 2012 at 10:0

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-26 Thread Sriraman Tallam
On Sat, May 26, 2012 at 4:56 PM, H.J. Lu wrote: > On Sat, May 26, 2012 at 3:34 PM, Sriraman Tallam wrote: >> On Fri, May 25, 2012 at 10:05 PM, H.J. Lu wrote: >>> On Fri, May 25, 2012 at 8:38 PM, Sriraman Tallam >>> wrote: >>>> >>

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-26 Thread Sriraman Tallam
On Fri, May 25, 2012 at 10:05 PM, H.J. Lu wrote: > On Fri, May 25, 2012 at 8:38 PM, Sriraman Tallam wrote: >> >> On May 25, 2012 7:15 PM, "H.J. Lu" wrote: >>> >>> >>> On May 25, 2012 6:54 PM, "Sriraman Tallam" wrote: >>> &

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-25 Thread Sriraman Tallam
On Fri, May 25, 2012 at 5:27 PM, H.J. Lu wrote: > On Fri, May 25, 2012 at 5:16 PM, Sriraman Tallam wrote: >> Hi H.J., >> >> On Fri, May 25, 2012 at 5:07 PM, H.J. Lu wrote: >>> On Mon, May 14, 2012 at 11:28 AM, Sriraman Tallam >>> wrote: >>>>

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-25 Thread Sriraman Tallam
Hi H.J., On Fri, May 25, 2012 at 5:07 PM, H.J. Lu wrote: > On Mon, May 14, 2012 at 11:28 AM, Sriraman Tallam wrote: >> Hi H.J, >> >>   Attaching new patch with 2 test cases, mv2.C checks ISAs only and >> mv1.C checks ISAs and arches mixed. Right now, checking only

Re: [google][4.7]Port function reordering via linker plugin from google/gcc-4_6 branch (issue6195099)

2012-05-17 Thread Sriraman Tallam
at 6:56 PM, Sriraman Tallam wrote: >> Patch too large to be attached, rejected by gcc-patches. Please see: >> >> http://codereview.appspot.com/download/issue6195099_1.diff >> >> Thanks, >> -Sri. >> >> On Wed, May 16, 2012 at 6:52 PM, Sriraman Tallam

Re: [google][4.7]Port function reordering via linker plugin from google/gcc-4_6 branch (issue6195099)

2012-05-16 Thread Sriraman Tallam
Patch too large to be attached, rejected by gcc-patches. Please see: http://codereview.appspot.com/download/issue6195099_1.diff Thanks, -Sri. On Wed, May 16, 2012 at 6:52 PM, Sriraman Tallam wrote: > Hi, > >  This patch ports function reordering support into google/gcc-4_7 branc

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-07 Thread Sriraman Tallam
On Wed, May 2, 2012 at 11:04 AM, H.J. Lu wrote: > On Wed, May 2, 2012 at 10:44 AM, Sriraman Tallam wrote: >>>>> >>>>> 1.  Since AVX > SSE4 > SSSE3 > SSE3 > SSE2 > SSE, with >>>>> foo for AVX and SSE3, on AVX processors, which fo

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-02 Thread Sriraman Tallam
On Wed, May 2, 2012 at 9:05 AM, H.J. Lu wrote: > On Wed, May 2, 2012 at 8:08 AM, Sriraman Tallam wrote: >> On Wed, May 2, 2012 at 6:42 AM, H.J. Lu wrote: >>> On Tue, May 1, 2012 at 7:45 PM, Sriraman Tallam wrote: >>>> Hi H.J, >>>> >>>>  

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-05-02 Thread Sriraman Tallam
On Wed, May 2, 2012 at 6:42 AM, H.J. Lu wrote: > On Tue, May 1, 2012 at 7:45 PM, Sriraman Tallam wrote: >> Hi H.J, >> >>   Done now. Patch attached. >> >> Thanks, >> -Sri. >> >> On Tue, May 1, 2012 at 5:08 PM, H.J. Lu wrote: >>> On

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-04-27 Thread Sriraman Tallam
On Fri, Apr 27, 2012 at 8:36 AM, H.J. Lu wrote: > On Fri, Apr 27, 2012 at 7:53 AM, Sriraman Tallam wrote: >> On Fri, Apr 27, 2012 at 7:38 AM, H.J. Lu wrote: >>> On Fri, Apr 27, 2012 at 7:35 AM, Sriraman Tallam >>> wrote: >>>> On Fri, Apr 27, 2012 at 6:3

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-04-27 Thread Sriraman Tallam
On Fri, Apr 27, 2012 at 7:38 AM, H.J. Lu wrote: > On Fri, Apr 27, 2012 at 7:35 AM, Sriraman Tallam wrote: >> On Fri, Apr 27, 2012 at 6:38 AM, H.J. Lu wrote: >>> On Thu, Apr 26, 2012 at 10:08 PM, Sriraman Tallam >>> wrote: >>>> Hi, >>>> &

Re: User directed Function Multiversioning via Function Overloading (issue5752064)

2012-04-27 Thread Sriraman Tallam
On Fri, Apr 27, 2012 at 6:38 AM, H.J. Lu wrote: > On Thu, Apr 26, 2012 at 10:08 PM, Sriraman Tallam wrote: >> Hi, >> >>   I have made the following changes in this new patch which is attached: >> >> * Use target attribute itself to create function versions. &g

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-25 Thread Sriraman Tallam
Patch committed. Thanks, -Sri. On Wed, Apr 25, 2012 at 4:52 PM, H.J. Lu wrote: > On Wed, Apr 25, 2012 at 4:38 PM, Sriraman Tallam wrote: >> Hi H.J, >> >>   Could you please review this patch for AVX2 check? >> >>        * config/i386/i386-cpuinfo

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-25 Thread Sriraman Tallam
: Document avx2 support. * testsuite/gcc.target/i386/builtin_target.c: Check avx2. * config/i386/i386.c (fold_builtin_cpu): Add avx2. Thanks, -Sri. On Wed, Apr 25, 2012 at 2:45 PM, Sriraman Tallam wrote: > On Wed, Apr 25, 2012 at 2:28 PM, H.J. Lu wrote: >> On Wed, Apr 25,

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-25 Thread Sriraman Tallam
On Wed, Apr 25, 2012 at 2:28 PM, H.J. Lu wrote: > On Wed, Apr 25, 2012 at 2:25 PM, Sriraman Tallam wrote: >> On Tue, Apr 24, 2012 at 7:39 PM, H.J. Lu wrote: >>> On Tue, Apr 24, 2012 at 7:06 PM, Sriraman Tallam >>> wrote: >>>> On Tue, Apr 24, 2012 at 5:2

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-25 Thread Sriraman Tallam
On Tue, Apr 24, 2012 at 7:39 PM, H.J. Lu wrote: > On Tue, Apr 24, 2012 at 7:06 PM, Sriraman Tallam wrote: >> On Tue, Apr 24, 2012 at 5:24 PM, H.J. Lu wrote: >>> On Tue, Apr 24, 2012 at 5:10 PM, Sriraman Tallam >>> wrote: >>>> Hi, >>>> >

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-24 Thread Sriraman Tallam
On Tue, Apr 24, 2012 at 5:24 PM, H.J. Lu wrote: > On Tue, Apr 24, 2012 at 5:10 PM, Sriraman Tallam wrote: >> Hi, >> >>   Thanks for all the comments. I have made all the changes as >> mentioned and submiited the patch. Summary of changes made: >> >> * Add

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-24 Thread Sriraman Tallam
file. * libgcc/config/i386/t-cpuinfo: New file. * libgcc/config.host: Include t-cpuinfo. * libgcc/config/i386/libgcc-glibc.ver: Version symbol __cpu_model. Thanks, -Sri. On Mon, Apr 23, 2012 at 5:46 PM, H.J. Lu wrote: > On Mon, Apr 23, 2012 at 1:43 PM, Sriraman Tallam wrote: &

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-23 Thread Sriraman Tallam
On Mon, Apr 23, 2012 at 12:16 PM, Uros Bizjak wrote: > On Mon, Apr 23, 2012 at 6:59 PM, Sriraman Tallam wrote: > >>>> i386 maintainers -  Is this patch ok? >>> >>> Has the community reached the consensus on how this kind of >>> functionality has to b

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-23 Thread Sriraman Tallam
On Mon, Apr 23, 2012 at 1:19 AM, Uros Bizjak wrote: > On Tue, Apr 3, 2012 at 9:47 PM, Sriraman Tallam wrote: > >> i386 maintainers -  Is this patch ok? > > Has the community reached the consensus on how this kind of > functionality has to be implemented? I have followed t

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-23 Thread Sriraman Tallam
Hi, On Mon, Apr 23, 2012 at 1:19 AM, Uros Bizjak wrote: > On Tue, Apr 3, 2012 at 9:47 PM, Sriraman Tallam wrote: > >> i386 maintainers -  Is this patch ok? > > Has the community reached the consensus on how this kind of > functionality has to be implemented? I have foll

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-18 Thread Sriraman Tallam
Ping. On Thu, Apr 12, 2012 at 4:14 PM, Sriraman Tallam wrote: > Ping. > > On Tue, Apr 3, 2012 at 12:47 PM, Sriraman Tallam wrote: >> Hi, >> >> i386 maintainers -  Is this patch ok? >> >> Thanks, >> -Sri. >> >> On Mon, Apr 2, 2012 at 5:48

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-12 Thread Sriraman Tallam
Ping. On Tue, Apr 3, 2012 at 12:47 PM, Sriraman Tallam wrote: > Hi, > > i386 maintainers -  Is this patch ok? > > Thanks, > -Sri. > > On Mon, Apr 2, 2012 at 5:48 PM, Sriraman Tallam wrote: >> On Mon, Apr 2, 2012 at 5:38 AM, Richard Guenther >> wrote:

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-09 Thread Sriraman Tallam
On Sun, Apr 8, 2012 at 6:17 AM, Gerald Pfeifer wrote: > On Thu, 29 Mar 2012, Sriraman Tallam wrote: >> Hi, >> >>     I have made a new patch to only have two builtins : >> >> * __builtin_cpu_is ("") >> * __builtin_cpu_supports ("") >&

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-03 Thread Sriraman Tallam
Hi, i386 maintainers - Is this patch ok? Thanks, -Sri. On Mon, Apr 2, 2012 at 5:48 PM, Sriraman Tallam wrote: > On Mon, Apr 2, 2012 at 5:38 AM, Richard Guenther > wrote: >> On Sat, Mar 31, 2012 at 1:03 AM, Sriraman Tallam wrote: >>> On Fri, Mar 30, 2012 at 5:47 AM

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-02 Thread Sriraman Tallam
On Mon, Apr 2, 2012 at 5:38 AM, Richard Guenther wrote: > On Sat, Mar 31, 2012 at 1:03 AM, Sriraman Tallam wrote: >> On Fri, Mar 30, 2012 at 5:47 AM, Michael Matz wrote: >>> Hi, >>> >>> On Thu, 29 Mar 2012, Sriraman Tallam wrote: >>> >>>

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-04-02 Thread Sriraman Tallam
On Mon, Apr 2, 2012 at 5:38 AM, Richard Guenther wrote: > On Sat, Mar 31, 2012 at 1:03 AM, Sriraman Tallam wrote: >> On Fri, Mar 30, 2012 at 5:47 AM, Michael Matz wrote: >>> Hi, >>> >>> On Thu, 29 Mar 2012, Sriraman Tallam wrote: >>> >>>

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-03-30 Thread Sriraman Tallam
On Fri, Mar 30, 2012 at 5:47 AM, Michael Matz wrote: > Hi, > > On Thu, 29 Mar 2012, Sriraman Tallam wrote: > >> +struct __processor_model >> +{ >> +  /* Vendor. */ >> +  unsigned int __cpu_is_amd : 1; >> +  unsigned int __cpu_is_intel : 1

Re: Support for Runtime CPU type detection via builtins (issue5754058)

2012-03-29 Thread Sriraman Tallam
atures : * "cmov" * "mmx" * "popcnt" * "sse" * "sse2" * "sse3" * "ssse3" * "sse4.1" * "sse4.2" As an example, to check if CPU is corei7, call __builtin_cpu_is ("corei7") Comments? Thanks. On Mon, M

Support for Runtime CPU type detection via builtins (issue5754058)

2012-03-29 Thread Sriraman Tallam
8,9 @@ GCC_4.4.0 { GCC_4.5.0 { __extendxftf2 } + +GCC_4.8.0 { + __cpu_model + __cpu_features +} %endif Index: libgcc/config/i386/i386-cpuinfo.c ======= --- libgcc/config/i386/i386-cpuinfo.c (revision 0) +++ libgcc/config/i386/i386-cpuinfo.

Re: [google][4.6]Bump param value of default function size limit for auto cloning

2012-03-21 Thread Sriraman Tallam
Submitted to google/gcc-4_6. Thanks, -Sri. On Wed, Mar 21, 2012 at 11:38 AM, Xinliang David Li wrote: > ok. > > thanks, > > David > > On Wed, Mar 21, 2012 at 11:20 AM, Sriraman Tallam wrote: >> Hi, >> >>  I am bumping up the default param value of  

[google][4.6]Bump param value of default function size limit for auto cloning

2012-03-21 Thread Sriraman Tallam
Hi, I am bumping up the default param value of function size limit for auto cloning. Since auto cloning happens on inlined functions, the original value does not catch some cases in one of our benchmarks. Automatic function versioning is only available in the google/gcc-4_6 branch. I am work

[google][4.6][i386]Support autocloning for corei7 with -mvarch= option to remove LCP stalls in loops (issue5865043)

2012-03-20 Thread Sriraman Tallam
This patch adds support to version for corei7 with -mvarch option. The versioning supported is in the case where a loop generates a LCP stalling instruction in corei7. In such cases, on corei7, limiting the unroll factor to try to keep the unrolled loop body small enough to fit in the Corei7's l

[google][4.6] Bug fixes to function reordering linker plugin to handle local and comdat functions. (issue5851044)

2012-03-20 Thread Sriraman Tallam
=== --- callgraph.h (revision 185543) +++ callgraph.h (working copy) @@ -1,6 +1,7 @@ /* Callgraph implementation. Copyright (C) 2011 Free Software Foundation, Inc. - Contributed by Sriraman Tallam (tmsri...@google.com). + Contributed by Sriraman Tallam (tmsri...@google.com) + and

Re: [google][4.6]Make option -freorder-functions= invoke function reordering linker plugin (issue 5825054)

2012-03-18 Thread Sriraman Tallam
Updated doc/invoke.texi and submitted. Thanks, -Sri. On Sat, Mar 17, 2012 at 11:58 PM, wrote: > > Ok for google branches after updating the doc/invoke.texi file. > > David > > > http://codereview.appspot.com/5825054/

Re: [google][4.6]Make option -freorder-functions= invoke function reordering linker plugin (issue5825054)

2012-03-14 Thread Sriraman Tallam
On Wed, Mar 14, 2012 at 6:56 PM, Sriraman Tallam wrote: > Made the following changes: > > * -ffunction-sections turned on with -freorder-functions= > * Change name from cgedge to callgraph. > * The plugin should not dump final layout to file by default. > > >

[google][4.6]Make option -freorder-functions= invoke function reordering linker plugin (issue5825054)

2012-03-14 Thread Sriraman Tallam
Made the following changes: * -ffunction-sections turned on with -freorder-functions= * Change name from cgedge to callgraph. * The plugin should not dump final layout to file by default. * cgraphbuild.c (remove_cgraph_callee_edges): Replace flag_callgraph_profiles_sections with

Re: [google][4.6]Make option -freorder-functions= invoke function reordering linker plugin (issue5825054)

2012-03-14 Thread Sriraman Tallam
On Wed, Mar 14, 2012 at 1:56 PM, Sriraman Tallam wrote: > This patch overloads GCC option -freorder-functions with -freoder-functions=* > which will invoke the linker plugin libfunction_reordering_plugin.so. For > now, the only accepted option is -freoder-functions=cgedge,

[google][4.6]Make option -freorder-functions= invoke function reordering linker plugin (issue5825054)

2012-03-14 Thread Sriraman Tallam
f (!is_api_exist) -return LDPS_OK; + /* Plugin APIs are supported if this is called. */ + assert (is_api_exist); if (is_callgraph_empty ()) return LDPS_OK; Index: function_reordering_plugin/ChangeLog.google-4_6 === --- function_reordering_plugin/ChangeLog.google-4_6 (revisi

Re: Swap SECTION_EXCLUDE and SECTION_MACH_DEP

2012-03-12 Thread Sriraman Tallam
Already submitted by gjl in rev. 185259. -Sri. On Mon, Mar 12, 2012 at 10:27 AM, Richard Henderson wrote: > On 03/12/12 10:26, Sriraman Tallam wrote: >> Hi Richard, >> >>   Is this ok for trunk? Asking you because you approved the patch the >> first time around. >

Re: Swap SECTION_EXCLUDE and SECTION_MACH_DEP

2012-03-12 Thread Sriraman Tallam
Hi Richard, Is this ok for trunk? Asking you because you approved the patch the first time around. Thanks, -Sri. On Fri, Mar 9, 2012 at 3:10 PM, Sriraman Tallam wrote: > Please see: > http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52545 > > SECTION_EXCLUDE should not take up bits

Re: Swap SECTION_EXCLUDE and SECTION_MACH_DEP

2012-03-09 Thread Sriraman Tallam
0x400 /* subsequent bits reserved for target */ Ok to submit? Thanks. -Sri. On Fri, Mar 9, 2012 at 3:07 PM, Sriraman Tallam wrote: >

Swap SECTION_EXCLUDE and SECTION_MACH_D

2012-03-09 Thread Sriraman Tallam

Re: Support for getting CPU type and feature information at run-time (issue5715051)

2012-03-07 Thread Sriraman Tallam
I committed this patch to google/main. I have created a new patch for review for trunk here : http://gcc.gnu.org/ml/gcc-patches/2012-03/msg00458.html Thanks, -Sri. On Thu, Mar 1, 2012 at 2:08 PM, Sriraman Tallam wrote: > Removing [google] prefix from the subject line. > > On Thu, Mar 1

Support for Runtime CPU type detection via builtins (issue5754058)

2012-03-06 Thread Sriraman Tallam
uinfo.c (revision 0) +++ libgcc/config/i386/i386-cpuinfo.c (revision 0) @@ -0,0 +1,306 @@ +/* Get CPU type and Features for x86 processors. + Copyright (C) 2011 Free Software Foundation, Inc. + Contributed by Sriraman Tallam (tmsri...@google.com) + +This file is part of GCC. + +GCC is free softwa

Support for getting CPU type and feature information at run-time (issue5715051)

2012-03-01 Thread Sriraman Tallam
Removing [google] prefix from the subject line. On Thu, Mar 1, 2012 at 12:54 PM, Xinliang David Li wrote: > Sri, probably need to remove the [google] prefix in the subject line > to prevent this from being filtered. > > David > > On Thu, Mar 1, 2012 at 12:45 PM, Sriraman Talla

[google]Support for getting CPU type and feature information at run-time (issue5715051)

2012-03-01 Thread Sriraman Tallam
(revision 0) +++ libgcc/config/i386/i386-cpuinfo.c (revision 0) @@ -0,0 +1,306 @@ +/* Get CPU type and Features for x86 processors. + Copyright (C) 2011 Free Software Foundation, Inc. + Contributed by Sriraman Tallam (tmsri...@google.com) + +This file is part of GCC. + +GCC is free software; y

<    1   2   3   4   >