This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: profiling on sh
- From: Daniel Jacobowitz <drow at mvista dot com>
- To: kewarken at qnx dot com
- Cc: Stephen Clarke <Stephen dot Clarke at st dot com>, aoliva at redhat dot com,gcc at gcc dot gnu dot org
- Date: Sat, 16 Mar 2002 12:53:00 -0500
- Subject: Re: profiling on sh
- References: <3C929869.AC4B66D1@st.com> <200203161351.IAA30154@hub.ott.qnx.com>
On Sat, Mar 16, 2002 at 01:46:46PM -0000, kewarken@qnx.com wrote:
> That was part of my original question. What exactly is the trapa supposed to
> be doing? I don't see a handler for that anywhere or know of how to set it
> up. I'd love to just be able to set trapa #33 to call mcount but I don't
> know where that would be done...OS level or code level.
Presumably, the trapa #33 calls a profile handler in some SH embedded
OS. You can't do it that way for something heavier-weight like Linux,
so you do need to emit the call to _mcount - however that is done.
Perhaps write a tiny C program that actually calls _mcount and just
mimic what it does? It may not have the same calling convention as
normal functions, however.
--
Daniel Jacobowitz Carnegie Mellon University
MontaVista Software Debian GNU/Linux Developer