diff options
author | bde <bde@FreeBSD.org> | 2002-01-31 13:49:55 +0000 |
---|---|---|
committer | bde <bde@FreeBSD.org> | 2002-01-31 13:49:55 +0000 |
commit | f4e7e770db8cd0720ea1b1864f732ec87390b893 (patch) | |
tree | a3096cb4e25f6b6dc5a29aa09e6c756260552d80 | |
parent | 02a885aab729802f4ccaf60b80bfeac26934af6d (diff) | |
download | FreeBSD-src-f4e7e770db8cd0720ea1b1864f732ec87390b893.zip FreeBSD-src-f4e7e770db8cd0720ea1b1864f732ec87390b893.tar.gz |
Finish revs.1.23 and 1.24 so that MCOUNT_ENTER really actually compiles
for SMP in the plain profiling case. It seems to work too.
This error was not detected by LINT because LINT only compiles the
GUPROF profiling case, which is is a superset of the plain profiling
case for !SMP but which is so broken for SMP that the buggy code is
not compiled.
-rw-r--r-- | sys/amd64/include/profile.h | 1 | ||||
-rw-r--r-- | sys/i386/include/profile.h | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/sys/amd64/include/profile.h b/sys/amd64/include/profile.h index 82ff603..bd8a7da 100644 --- a/sys/amd64/include/profile.h +++ b/sys/amd64/include/profile.h @@ -64,6 +64,7 @@ #else #define MCOUNT_DECL(s) u_long s; #ifdef SMP +extern int mcount_lock; #define MCOUNT_ENTER(s) { s = read_eflags(); disable_intr(); \ while (!atomic_cmpset_acq_int(&mcount_lock, 0, 1)) \ /* nothing */ ; } diff --git a/sys/i386/include/profile.h b/sys/i386/include/profile.h index 82ff603..bd8a7da 100644 --- a/sys/i386/include/profile.h +++ b/sys/i386/include/profile.h @@ -64,6 +64,7 @@ #else #define MCOUNT_DECL(s) u_long s; #ifdef SMP +extern int mcount_lock; #define MCOUNT_ENTER(s) { s = read_eflags(); disable_intr(); \ while (!atomic_cmpset_acq_int(&mcount_lock, 0, 1)) \ /* nothing */ ; } |