profiling with cc

Andreas Tobler toa at
Mon Feb 6 13:02:10 PST 2006

Marius Strobl wrote:

> As far as I understand MCOUNT refers to the symbol generated by the
> compiler and _MCOUNT_DECL to the name of the real function in libc.
> As the compiler apparently generates calls to _mcount() on sparc64
> the MCOUNT macro should define _mcount() for userland and _MCOUNT_DECL
> mcount() or maybe better __mcount(). I'm not sure wheter the NetBSD
> asm applies to FreeBSD.
> If you let _MCOUNT_DECL define _mcount() as in your snippet above
> you'll bypass the wrapper on sparc64 altogether.

Ok, my naive assumption that this will be easy, has gone :)

I do not yet understand the build process. Jumping into a 
/usr/src/lib/libc and do a make picks up the system headers and not my 
modified machine/profile.h. Going to /usr/src and do a make -DNO_CLEAN 
all doesn't pick it up either.

What step do I miss? This is on CURRENT.


P.S, even a pointer to read all through would be good.

More information about the freebsd-sparc64 mailing list