cvs commit: src/sys/ia64/ia64 support.S src/sys/ia64/include asm.h
cpu.h profile.h src/lib/libc/ia64/gen Makefile.inc _mcount.S
Marcel Moolenaar
marcel at FreeBSD.org
Wed Aug 25 00:42:35 PDT 2004
marcel 2004-08-25 07:42:34 UTC
FreeBSD src repository
Modified files:
sys/ia64/ia64 support.S
sys/ia64/include asm.h cpu.h profile.h
lib/libc/ia64/gen Makefile.inc
Added files:
lib/libc/ia64/gen _mcount.S
Log:
Make profiling actually work. The gcc compiler emits a call to the
_mcount() stub when profiling is enabled. Emit this code sequence
for assembly routines as welli (MCOUNT definition in <machine/asm.h>.
We do not pass the GOT entry however as the 4th argument, because it's
not used. The _mcount() stub calls __mcount(), which does the actual
work. Define _MCOUNT_DECL to define __mcount. We do not have an
implementation of mcount(), so we define MCOUNT as empty, but have a
weak alias to _mcount() in _mcount.S.
Note that the _mcount() stub in the kernel is slightly different from
the stub in userland. This is because we do not have to worry about
nested routines in the kernel.
Revision Changes Path
1.13 +4 -4 src/lib/libc/ia64/gen/Makefile.inc
1.1 +75 -0 src/lib/libc/ia64/gen/_mcount.S (new)
1.22 +42 -0 src/sys/ia64/ia64/support.S
1.11 +9 -6 src/sys/ia64/include/asm.h
1.45 +5 -0 src/sys/ia64/include/cpu.h
1.9 +29 -88 src/sys/ia64/include/profile.h
More information about the cvs-src
mailing list