This is the mail archive of the gcc-help@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: How to find function_decl by identifier in plugin


Thank you for your reply!

>Does it work when GIMPLE representation is already built (just checking)?
It work with built GIMPLE representation (after pass_tm_edges).

> You probably need to use the symbol table. See the 'symbol_table' class
> defined in 'cgraph.h' (there is a global instance of this class, 'symtab').
I have tried to use symtab instance already, but it contains not full
list symbols... for example it doesn't contains some external
functions. You can to see this even on "hello world" program.

But, I have compiled a program with option -fdump-tree-all-all and
have analyzed the *.tu file (translation unit), and it contains the
all external declarations and the type declarations.
I actually don't understand why the symtab doesn't contains it. And
how can I get declarations from external scope?

Thank you!
-Ivan


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