# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1213283499 -3600
# Node ID 882eb6186c2dbc7f73280f3aca3600faad44fbf0
# Parent a3319f32496fd93a545fc354ce3944072cc32e5e
x86: add perf counter for pointless updates of writable pages through a
hypercall
Signed-off-by: Jan Beulich <jbeulich@xxxxxxxxxx>
---
xen/arch/x86/mm.c | 2 ++
xen/include/asm-x86/perfc_defn.h | 1 +
2 files changed, 3 insertions(+)
diff -r a3319f32496f -r 882eb6186c2d xen/arch/x86/mm.c
--- a/xen/arch/x86/mm.c Thu Jun 12 16:09:08 2008 +0100
+++ b/xen/arch/x86/mm.c Thu Jun 12 16:11:39 2008 +0100
@@ -2602,6 +2602,8 @@ int do_mmu_update(
if ( unlikely(!get_page_type(page, PGT_writable_page)) )
break;
+ perfc_incr(writable_mmu_updates);
+
okay = paging_write_guest_entry(v, va, req.val, _mfn(mfn));
put_page_type(page);
diff -r a3319f32496f -r 882eb6186c2d xen/include/asm-x86/perfc_defn.h
--- a/xen/include/asm-x86/perfc_defn.h Thu Jun 12 16:09:08 2008 +0100
+++ b/xen/include/asm-x86/perfc_defn.h Thu Jun 12 16:11:39 2008 +0100
@@ -23,6 +23,7 @@ PERFCOUNTER(num_mmuext_ops,
PERFCOUNTER(num_mmuext_ops, "mmuext ops")
PERFCOUNTER(calls_to_mmu_update, "calls to mmu_update")
PERFCOUNTER(num_page_updates, "page updates")
+PERFCOUNTER(writable_mmu_updates, "mmu_updates of writable pages")
PERFCOUNTER(calls_to_update_va, "calls to update_va_map")
PERFCOUNTER(page_faults, "page faults")
PERFCOUNTER(copy_user_faults, "copy_user faults")
_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog
|