This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: [plugins-ici-cloning-instrumentation] new GCC plugin developements


Hi Basile,

Well, the point of ICI is actually not to hardwire specific events at the beginning 
but allow users/researchers easily add their own hooks referenced by any string 
to simplify prototyping of new ideas. Then if they see that it is useful and they
can persuade the community about that, those hooks go to the mainline and are hardwired
in the PLUGIN_* event ...

We found such usage very convenient in the last few years and during that
time got a considerable feedback about ICI - it is also being used at the moment
in multiple projects that's why we are now trying to add it to the mainline
to help our colleagues use it directly in the mainline GCC and continue research...

Again, several thousands of lines of code in ICI have been related just to manage
event referencing by the string (with hashing, etc) + clean API but it doesn't really
change GCC too much. Actually, I am thinking that maybe we should actually
make ICI as a library and provide only a few necessary hooks/changes to GCC 
to support it. 

Joern and Zbigniew, what do you think about that?..

Cheers,
Grigori


> -----Original Message-----
> From: ctuning-discussions@googlegroups.com [mailto:ctuning-discussions@googlegroups.com] On
> Behalf Of Basile STARYNKEVITCH
> Sent: Friday, November 06, 2009 4:55 PM
> To: Joern Rennecke
> Cc: Grigori Fursin; 'Ian Lance Taylor'; 'Yuanjie Huang'; 'Liang Peng'; 'Zbigniew Chamski';
> 'GCC Mailing List'; ctuning-discussions@googlegroups.com; 'Yuri Kashnikoff'; 'Diego Novillo'
> Subject: Re: [plugins-ici-cloning-instrumentation] new GCC plugin developements
> 
> 
> Joern Rennecke wrote:
> > Quoting Grigori Fursin <grigori.fursin@inria.fr>:
> >
> >> Sure, thanks for the info, Ian.
> >>
> >> The ICI changes are very small and seems that they already had been
> >> pre-reviewed.
> >> Joern is taking care of that now.
> >
> > After the pass-name changes are taken out (this is the pre-reviewed bit
> > I'm currently trying to contribute to mainline), there is about 65 KB of
> > unidiff left from the ICI 2.0 branch.  That code needs a bit of GNU
> > reformatting, so I doubt it has been reviewed in its entirety.
> > As it looks like the pass-name changes can go into mainline soon, I want
> > to hold off creating a branch for the rest of the code till the former
> > changes are in mainline.
> 
> 
> My suggestion would be to try pushing the minimal missing plugin hooks needed for ICI into the
> trunk (that could perhaps
> happen in gcc 4.5 timeframe), and adjust your ICI 2.x branch to make it a plugin (perhaps
> dlopen-ing itself other code).
> What I am thinking of is just adding a few more PLUGIN_* events. Even adding a single event
> take much time in practice.
> http://gcc.gnu.org/ml/gcc/2009-10/msg00547.html http://gcc.gnu.org/ml/gcc/2009-
> 10/msg00548.html
> 
> You'll need to
> 
> 1.) convince the GCC community that your event is useful. This is sometimes not as easy as it
> seems.
> (and I Basile did try a bit to explain what possible hooks could be useful to *ICI* & also
> MELT).
> http://gcc.gnu.org/ml/gcc/2009-10/msg00549.html
> 
> 2.) propose a small patch to add it
>     2.1) add your PLUGIN_* event in gcc/gcc-plugin.h & gcc/plugin.c
>     2.2) just a call to invoke_plugin_callbacks (at the place you need).
>     2.3) document it in gcc/doc/plugins.texi
>     2.4) make a testcase [this means understanding dejagnu]
> 
> 3.) wait for your patch to be accepted.
> 
> My feeling is that ICI should have a small steps strategy to add the minimal hooks required,
> and be [like MELT] mostly a
> plugin and/or an experimental branch nobody really cares about.
> I am not sure it is realistic to try to push (at least for gcc 4.5, and perhaps even gcc 4.6)
> a multithousand lines ICI
> patch.... Better push several smaller patches, each adding a PLUGIN_* event, and make most of
> ICI a plugin itself.
> 
> Regards.
> 
> --
> Basile STARYNKEVITCH         http://starynkevitch.net/Basile/
> email: basile<at>starynkevitch<dot>net mobile: +33 6 8501 2359
> 8, rue de la Faiencerie, 92340 Bourg La Reine, France
> *** opinions {are only mines, sont seulement les miennes} ***
> 
> --~--~---------~--~----~------------~-------~--~----~
> You received this message because you are subscribed to the Google Groups "ctuning-
> discussions" group.
> To post to this group, send email to ctuning-discussions@googlegroups.com
> To unsubscribe from this group, send email to ctuning-discussions+unsubscribe@googlegroups.com
> For more options, visit this group at http://groups.google.com/group/ctuning-discussions?hl=en
> -~----------~----~----~----~------~----~------~--~---


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]