Page MenuHomeFreeBSD

D40946.id124368.diff
No OneTemporary

D40946.id124368.diff

diff --git a/sys/sys/kassert.h b/sys/sys/kassert.h
--- a/sys/sys/kassert.h
+++ b/sys/sys/kassert.h
@@ -38,6 +38,16 @@
extern bool panicked;
#define KERNEL_PANICKED() __predict_false(panicked)
+/*
+ * Try to trap accesses.
+ * TODO: use kmsan if available
+ */
+#ifdef INVARIANTS
+#define DEBUG_POISON_POINTER(x) ({ x = (void *)(UINTPTR_MAX - 4096); })
+#else
+#define DEBUG_POISON_POINTER(x)
+#endif
+
#ifdef INVARIANTS /* The option is always available */
#define VNASSERT(exp, vp, msg) do { \
if (__predict_false(!(exp))) { \

File Metadata

Mime Type
text/plain
Expires
Fri, Apr 3, 11:37 AM (21 h, 48 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30755883
Default Alt Text
D40946.id124368.diff (546 B)

Event Timeline