Hi, folks! I'm back again. I installed GCC's from source in Linux Fedora 15, 32 bits (I had problems with other distros and versions). Now I need to proceed to my real work: to change the source code in a way that I can have the use of memory of a program in the profiling reports (flat profile and call graph). First I need to find out where GCC instruments the source code which is being compiled to generate the gmon.out file. Then I have to add a function call to get the memory used by the process (maybe via a system call). After that, I'll have to create a new field in the gmon.out structure to store this memory use (in hist.c, cg_print.c and gprof.c too, I think). But I need some help. I have only 1 month to get it done, and I'm quite at the begining of the works. So any tips will be welcome, like: 1) Where gcc.c calls the entry point for instrumentation when I compile a program with -pg (for profiling)? 2) Which function or system command should I call to get the process memory use? 3) I think this calling should affect the samples time measuring. Is there a way to avoid or reduce this impact? 4) Which structures do I have to change to add the new field (to store the memory use)? Is 'struct sym' in symtab.h one of them? As I said, any tip will help a lot. Thanks! Luiz Henrique Kiehn