getting non-global variable names from RTL
Josef Zlomek
zlomj9am@artax.karlin.mff.cuni.cz
Sun Feb 22 21:09:00 GMT 2004
> I am writing a small optimization pass for gcc-3.3.1, and I would need to
> be able to identify the arguments that were passed to the current
> function on the stack with their counterparts from the source code (i.e.,
> in RTL, I would have those variables in virtual-incoming-args +0, +4, +8,
> etc, and I can see what registers they are extracted into; but what I
> would like to know is that this function was called like f (a, b, c), so I
> know that virtual-incoming-args + 8 is "a", virtual-incoming-args + 4 is
> "b", and virtual-incoming-args + 0 is "c").
I'm not sure I understood you correctly but have a look at
var-tracking.c:vt_add_function_parameters on mainline.
Josef
More information about the Gcc
mailing list