[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] Some fixes to the performance counters code.



# HG changeset patch
# User kaf24@xxxxxxxxxxxxxxxxxxxx
# Node ID a66a41032226503302ec390a158b38d8a5632c8a
# Parent  6b48b53b682d5fa8bc61ceb727a346d25148c1e9
Some fixes to the performance counters code.
Signed-off-by: Ross McIlroy <mcilrorc@xxxxxxxxxxxxx>

diff -r 6b48b53b682d -r a66a41032226 tools/misc/cpuperf/cpuperf.c
--- a/tools/misc/cpuperf/cpuperf.c      Tue Aug 30 16:53:40 2005
+++ b/tools/misc/cpuperf/cpuperf.c      Tue Aug 30 17:00:26 2005
@@ -243,16 +243,12 @@
     }
 
     if (read) {
-        while((cpu_mask&1)) {
-            int i;
-            for (i=0x300;i<0x312;i++) {
-                printf("%010llu ",cpus_rdmsr( cpu_mask, i ) );
-            }
-            printf("\n");
-            cpu_mask>>=1;
-        }
+        int i;
+        for (i=0x300;i<0x312;i++)
+            printf("%010llu ",cpus_rdmsr( cpu_mask, i ) );
+        printf("\n");
         exit(1);
-    } 
+    }
     
     if (!escr) {
         fprintf(stderr, "Need an ESCR.\n");
diff -r 6b48b53b682d -r a66a41032226 xen/include/xen/perfc.h
--- a/xen/include/xen/perfc.h   Tue Aug 30 16:53:40 2005
+++ b/xen/include/xen/perfc.h   Tue Aug 30 17:00:26 2005
@@ -4,6 +4,7 @@
 
 #ifdef PERF_COUNTERS
 
+#include <xen/lib.h>
 #include <asm/atomic.h>
 
 /* 
@@ -87,7 +88,7 @@
  * Histogram: special treatment for 0 and 1 count. After that equally spaced 
  * with last bucket taking the rest.
  */
-#ifdef PERFC_ARRAYS
+#ifdef PERF_ARRAYS
 #define perfc_incr_histo(_x,_v,_n)                                          \
     do {                                                                    \
         if ( (_v) == 0 )                                                    \

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.