This is the mail archive of the gcc@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]

profiling


Hello,

I want to made hardware profiling. For that purposes I need to have
instrumented source code that has to be profiled. At every beginning and end

of function and program loops writing to one register must be inserted. Each

faction write different value in that register. My hardware detects access
to that register, which function had access and time when that access was
happen.

For source code instrumentation I want to use gcc. As gcc is very complex
software, I hope that you can help me.

I read gecko documentation, and it seems to me that -pg or -test-coverage
options can be used for this purpose. Can you please tell me what exactly
these options do? Do they insert some code before compiling or before
linking? Where is it in gcc source code? Can I easy change that code with
writing to some register?  Is it possible to set profiling hierarchy level
(for example: to add extra code only on "main" function instead of whole
source)?

Thank you for your time

Regards
Zdenka Safarzik


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