* Generating gimple statements from pragma's
@ 2013-04-26 18:10 Julien Peeters
0 siblings, 0 replies; only message in thread
From: Julien Peeters @ 2013-04-26 18:10 UTC (permalink / raw)
To: gcc-help
Hi ML Readers,
I am looking for help to make a GCC plugin.
The plugin aims to add pragma's to GCC. These pragma's would have the
effect of inserting calls to runtime library functions a very specific
points in the code.
Here is an example:
If I write:
int a, b;
...
#pragma mypragma opt(a, b)
{
int c;
c = b;
a += c;
b = a;
}
the resulting gimple should be equivalent to this:
int a, b;
...
runtime_start ();
runtime_require ( a );
runtime_require ( b );
runtime_check ();
{
int c;
c = b;
a += c;
b = a;
}
runtime_finalize ();
I found in the examples how to add pragma's but I am not sure how can I
detect the block next to the pragma, check that all variable in the opt
option are accessible in the scope of the block and finally how can I
add calls to the runtime functions.
Thanks for helping,
Julien.
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2013-04-26 18:10 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-04-26 18:10 Generating gimple statements from pragma's Julien Peeters
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).