Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Sep 2009 17:45:29 +0000 (UTC)
From:      Rui Paulo <rpaulo@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r197412 - head/sys/dev/hwpmc
Message-ID:  <200909221745.n8MHjTC0026952@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rpaulo
Date: Tue Sep 22 17:45:28 2009
New Revision: 197412
URL: http://svn.freebsd.org/changeset/base/197412

Log:
  Reserve events for XScale.
  
  Reviewed by:	jkoshy, gnn
  MFC after:	1 week

Modified:
  head/sys/dev/hwpmc/pmc_events.h

Modified: head/sys/dev/hwpmc/pmc_events.h
==============================================================================
--- head/sys/dev/hwpmc/pmc_events.h	Tue Sep 22 16:59:15 2009	(r197411)
+++ head/sys/dev/hwpmc/pmc_events.h	Tue Sep 22 17:45:28 2009	(r197412)
@@ -1979,6 +1979,30 @@ __PMC_EV_ALIAS("SIMD_INT_64.SHUFFLE_MOVE
 #define	PMC_EV_TSC_FIRST	PMC_EV_TSC_TSC
 #define	PMC_EV_TSC_LAST		PMC_EV_TSC_TSC
 
+
+/*
+ * Intel XScale events from "Intel XScale Core Developer's Manual",
+ * January 2004, #27347302
+ */
+#define	__PMC_EV_XSCALE()			\
+	__PMC_EV(XSCALE, IC_FETCH)		\
+	__PMC_EV(XSCALE, IC_MISS)		\
+	__PMC_EV(XSCALE, DATA_DEPENDENCY_STALL)	\
+	__PMC_EV(XSCALE, ITLB_MISS)		\
+	__PMC_EV(XSCALE, DTLB_MISS)		\
+	__PMC_EV(XSCALE, BRANCH_EXECUTED)	\
+	__PMC_EV(XSCALE, BRANCH_MISPRED)	\
+	__PMC_EV(XSCALE, INSTR_EXECUTED)	\
+	__PMC_EV(XSCALE, DC_FULL_CYCLE)		\
+	__PMC_EV(XSCALE, DC_FULL_CONTIG)	\
+	__PMC_EV(XSCALE, DC_ACCESS)		\
+	__PMC_EV(XSCALE, DC_MISS)		\
+	__PMC_EV(XSCALE, DC_WRITEBACK)		\
+	__PMC_EV(XSCALE, PC_CHANGE)
+
+#define	PMC_EV_XSCALE_FIRST	PMC_EV_XSCALE_IC_FETCH
+#define	PMC_EV_XSCALE_LAST	PMC_EV_XSCALE_PC_CHANGE
+
 /*
  * All known PMC events.
  *
@@ -1996,6 +2020,7 @@ __PMC_EV_ALIAS("SIMD_INT_64.SHUFFLE_MOVE
  * 0x11000	0x0080		INTEL Pentium 4 events
  * 0x11080	0x0080		INTEL Pentium MMX events
  * 0x11100	0x0100		INTEL Pentium Pro/P-II/P-III/Pentium-M events
+ * 0x11200	0x00FF		INTEL XScale events
  */
 #define	__PMC_EVENTS()				\
 	__PMC_EV_BLOCK(TSC,	0x01000)	\
@@ -2013,9 +2038,11 @@ __PMC_EV_ALIAS("SIMD_INT_64.SHUFFLE_MOVE
 	__PMC_EV_BLOCK(P5,	0x11080)	\
 	__PMC_EV_P5()				\
 	__PMC_EV_BLOCK(P6,	0x11100)	\
-	__PMC_EV_P6()
+	__PMC_EV_P6()				\
+	__PMC_EV_BLOCK(XSCALE,	0x11200)	\
+	__PMC_EV_XSCALE()
 
 #define	PMC_EVENT_FIRST	PMC_EV_TSC_TSC
-#define	PMC_EVENT_LAST	PMC_EV_P6_LAST
+#define	PMC_EVENT_LAST	PMC_EV_XSCALE_LAST
 
 #endif /* _DEV_HWPMC_PMC_EVENTS_H_ */



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200909221745.n8MHjTC0026952>