[compiler-rt] [asan] Implement address sanitizer on AIX: shadow memory (PR #136874)

Vitaly Buka via llvm-commits llvm-commits at lists.llvm.org
Fri Apr 10 11:15:34 PDT 2026


================
@@ -341,17 +355,29 @@ void PrintAddressSpaceLayout() {
            (void*)kHighShadowBeg, (void*)kHighShadowEnd);
   }
   if (kMidMemBeg) {
+    // AIX shadowgap is always set to 0 for 64-bit.
+#if !SANITIZER_AIX || SANITIZER_WORDSIZE != 64
     Printf("|| `[%p, %p]` || ShadowGap3 ||\n",
            (void*)kShadowGap3Beg, (void*)kShadowGap3End);
+#endif
     Printf("|| `[%p, %p]` || MidMem     ||\n",
            (void*)kMidMemBeg, (void*)kMidMemEnd);
+#if !SANITIZER_AIX || SANITIZER_WORDSIZE != 64
     Printf("|| `[%p, %p]` || ShadowGap2 ||\n",
            (void*)kShadowGap2Beg, (void*)kShadowGap2End);
+#endif
     Printf("|| `[%p, %p]` || MidShadow  ||\n",
            (void*)kMidShadowBeg, (void*)kMidShadowEnd);
   }
+#if SANITIZER_AIX && SANITIZER_WORDSIZE == 64
----------------
vitalybuka wrote:

what if we live printing as is, for consistently?


https://github.com/llvm/llvm-project/pull/136874


More information about the llvm-commits mailing list