Lines 48-53
Link Here
|
48 |
#endif |
48 |
#endif |
49 |
#include <i386/isa/timerreg.h> |
49 |
#include <i386/isa/timerreg.h> |
50 |
|
50 |
|
|
|
51 |
#include <machine/asmacros.h> |
52 |
|
51 |
#ifdef GUPROF |
53 |
#ifdef GUPROF |
52 |
#define CPUTIME_CLOCK_UNINITIALIZED 0 |
54 |
#define CPUTIME_CLOCK_UNINITIALIZED 0 |
53 |
#define CPUTIME_CLOCK_I8254 1 |
55 |
#define CPUTIME_CLOCK_I8254 1 |
Lines 77-83
Link Here
|
77 |
# \n\ |
79 |
# \n\ |
78 |
# Check that we are profiling. Do it early for speed. \n\ |
80 |
# Check that we are profiling. Do it early for speed. \n\ |
79 |
# \n\ |
81 |
# \n\ |
80 |
cmpl $GMON_PROF_OFF,__gmonparam+GM_STATE \n\ |
82 |
cmpl $GMON_PROF_OFF," __XSTRING(CNAME(_gmonparam)) "+GM_STATE \n\ |
81 |
je Lmcount_exit \n\ |
83 |
je Lmcount_exit \n\ |
82 |
# \n\ |
84 |
# \n\ |
83 |
# __mcount is the same as mcount except the caller \n\ |
85 |
# __mcount is the same as mcount except the caller \n\ |
Lines 88-96
Link Here
|
88 |
jmp Lgot_frompc \n\ |
90 |
jmp Lgot_frompc \n\ |
89 |
\n\ |
91 |
\n\ |
90 |
.align 4,0x90 \n\ |
92 |
.align 4,0x90 \n\ |
91 |
.globl mcount \n\ |
93 |
.globl " __XSTRING(HIDENAME(mcount)) " \n\ |
92 |
mcount: \n\ |
94 |
" __XSTRING(HIDENAME(mcount)) ": \n\ |
93 |
cmpl $GMON_PROF_OFF,__gmonparam+GM_STATE \n\ |
95 |
cmpl $GMON_PROF_OFF," __XSTRING(CNAME(_gmonparam)) "+GM_STATE \n\ |
94 |
je Lmcount_exit \n\ |
96 |
je Lmcount_exit \n\ |
95 |
# \n\ |
97 |
# \n\ |
96 |
# The caller's stack frame has already been built, so \n\ |
98 |
# The caller's stack frame has already been built, so \n\ |
Lines 109-115
Link Here
|
109 |
pushl %eax \n\ |
111 |
pushl %eax \n\ |
110 |
pushl %edx \n\ |
112 |
pushl %edx \n\ |
111 |
cli \n\ |
113 |
cli \n\ |
112 |
call _mcount \n\ |
114 |
call " __XSTRING(CNAME(mcount)) " \n\ |
113 |
addl $8,%esp \n\ |
115 |
addl $8,%esp \n\ |
114 |
popfl \n\ |
116 |
popfl \n\ |
115 |
Lmcount_exit: \n\ |
117 |
Lmcount_exit: \n\ |