summaryrefslogtreecommitdiffstats
path: root/sys/amd64/include/profile.h
diff options
context:
space:
mode:
authorpaul <paul@FreeBSD.org>1994-09-15 16:27:14 +0000
committerpaul <paul@FreeBSD.org>1994-09-15 16:27:14 +0000
commit8c92b502be26553a5c8efed5f8a08ca339a9f834 (patch)
tree655b6ec5be1d561f2c60cf6130902b9183b65b04 /sys/amd64/include/profile.h
parent0a8a4cff4f1045c0d43f7187c710a932f90104e8 (diff)
downloadFreeBSD-src-8c92b502be26553a5c8efed5f8a08ca339a9f834.zip
FreeBSD-src-8c92b502be26553a5c8efed5f8a08ca339a9f834.tar.gz
Added MCOUNT_ENTER and MCOUNT_EXIT macros to profile.h
Removed inb function since it's more correctly in pio.h Copied write_eflags and read_eflags over from npx.c (Some changes to the macros suggested by Bruce were not made at this time since his suggestions probably apply to all the macros and these inlined/macro definitions need a lot of cleaning up at some point in the future.) Reviewed by: Bruce
Diffstat (limited to 'sys/amd64/include/profile.h')
-rw-r--r--sys/amd64/include/profile.h5
1 files changed, 4 insertions, 1 deletions
diff --git a/sys/amd64/include/profile.h b/sys/amd64/include/profile.h
index 03133aa..9fe27ec 100644
--- a/sys/amd64/include/profile.h
+++ b/sys/amd64/include/profile.h
@@ -31,7 +31,7 @@
* SUCH DAMAGE.
*
* @(#)profile.h 8.1 (Berkeley) 6/11/93
- * $Id: profile.h,v 1.2 1994/08/02 07:38:56 davidg Exp $
+ * $Id: profile.h,v 1.3 1994/08/21 04:55:29 paul Exp $
*/
#ifndef _I386_MACHINE_PROFILE_H_
@@ -59,4 +59,7 @@ extern void mcount() asm("mcount"); void mcount() { \
_mcount(frompcindex, selfpc); \
}
+#define MCOUNT_ENTER save_eflags = read_eflags(); disable_intr()
+#define MCOUNT_EXIT write_eflags(save_eflags)
+
#endif
OpenPOWER on IntegriCloud