Implement __bb_init_func. This is a fairly straightforward conversion

of the i386 version.
This commit is contained in:
Tim J. Robbins 2004-05-29 01:13:28 +00:00
parent 907cb02fe9
commit 402705521a
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=129825

View File

@ -653,3 +653,22 @@ ENTRY(longjmp)
incl %eax
ret
#endif
/*
* Support for BB-profiling (gcc -a). The kernbb program will extract
* the data from the kernel.
*/
.data
ALIGN_DATA
.globl bbhead
bbhead:
.quad 0
.text
NON_GPROF_ENTRY(__bb_init_func)
movq $1,(%rdi)
movq bbhead,%rax
movq %rax,32(%rdi)
movq %rdi,bbhead
NON_GPROF_RET