This is the mail archive of the
mailing list for the GCC project.
Mapping calls to declarations
- To: <gcc at gcc dot gnu dot org>
- Subject: Mapping calls to declarations
- From: James Montgomerie <jrmg at dcs dot ed dot ac dot uk>
- Date: Mon, 13 Aug 2001 15:09:06 +0100
Since I've had no on-list responses to my mail of last week
(http://gcc.gnu.org/ml/gcc/2001-08/msg00407.html), I thought I'd phrase my
question in vauger terms in the hope of provoking a suggestion :-)
I need to be able to, in the function call instruction patterns (or
functions called by them), map from a function call to a declaration. I
first tried looking up the SYMBOL_REF in the symbol table, but this does not
work*. My next thought was to get the declaration via get_callee_fndecl,
somehow getting the tree for the call expression first, but I can't see a
way to do that.
If none of this is possible, some other way of deducing the register modes
for the arguments in the call would also suffice.
Does anyone have any suggestions? Is anyone prepared to stick their neck
out and say it actually can't be done within the current framework?
* I tried using lookup_name directly, but the information I require is
either not in the symbol table - see