diff mbox series

[v5,3/4] x86/mem_sharing: enable mem_share audit mode only in debug builds

Message ID 20190516213752.1701-3-tamas@tklengyel.com (mailing list archive)
State New, archived
Headers show
Series [v5,1/4] x86/mem_sharing: reorder when pages are unlocked and released | expand

Commit Message

Tamas K Lengyel May 16, 2019, 9:37 p.m. UTC
Improves performance for release builds.

Signed-off-by: Tamas K Lengyel <tamas@tklengyel.com>
Cc: Jan Beulich <jbeulich@suse.com>
Cc: Andrew Cooper <andrew.cooper3@citrix.com>
Cc: Wei Liu <wei.liu2@citrix.com>
Cc: Roger Pau Monne <roger.pau@citrix.com>
---
 xen/include/asm-x86/mem_sharing.h | 4 ++++
 1 file changed, 4 insertions(+)

Comments

Tamas K Lengyel June 17, 2019, 12:24 p.m. UTC | #1
On Thu, May 16, 2019 at 11:38 PM Tamas K Lengyel <tamas@tklengyel.com> wrote:
>
> Improves performance for release builds.
>
> Signed-off-by: Tamas K Lengyel <tamas@tklengyel.com>

Patch ping. Unclear whose Ack is strictly needed as this is only
touching mem_sharing code and nothing else.

Thanks,
Tamas
diff mbox series

Patch

diff --git a/xen/include/asm-x86/mem_sharing.h b/xen/include/asm-x86/mem_sharing.h
index 9f9f7e93e3..afd0c17292 100644
--- a/xen/include/asm-x86/mem_sharing.h
+++ b/xen/include/asm-x86/mem_sharing.h
@@ -25,7 +25,11 @@ 
 #include <public/memory.h>
 
 /* Auditing of memory sharing code? */
+#ifndef NDEBUG
 #define MEM_SHARING_AUDIT 1
+#else
+#define MEM_SHARING_AUDIT 0
+#endif
 
 typedef uint64_t shr_handle_t;