From 205441ba422abf722937a60da4a592db6e4956ce Mon Sep 17 00:00:00 2001 From: Jake Egan Date: Wed, 16 Jul 2025 23:52:16 -0400 Subject: [PATCH 1/3] revert --- compiler-rt/lib/asan/asan_descriptions.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/compiler-rt/lib/asan/asan_descriptions.cpp b/compiler-rt/lib/asan/asan_descriptions.cpp index 0c30959b23e28..387c5692991fb 100644 --- a/compiler-rt/lib/asan/asan_descriptions.cpp +++ b/compiler-rt/lib/asan/asan_descriptions.cpp @@ -449,10 +449,12 @@ AddressDescription::AddressDescription(uptr addr, uptr access_size, // are put to the STACK region for unknown reasons. Check global first can // workaround this issue. // TODO: Look into whether there's a different solution to this problem. +#if SANITIZER_AIX if (GetGlobalAddressInformation(addr, access_size, &data.global)) { data.kind = kAddressKindGlobal; return; } +#endif if (GetHeapAddressInformation(addr, access_size, &data.heap)) { data.kind = kAddressKindHeap; @@ -471,6 +473,13 @@ AddressDescription::AddressDescription(uptr addr, uptr access_size, return; } +#if !SANITIZER_AIX + if (GetGlobalAddressInformation(addr, access_size, &data.global)) { + data.kind = kAddressKindGlobal; + return; + } +#endif + data.kind = kAddressKindWild; data.wild.addr = addr; data.wild.access_size = access_size; From 998ec16e6de9cb666c09e2a84db8ada98838dd03 Mon Sep 17 00:00:00 2001 From: Jake Egan Date: Thu, 17 Jul 2025 00:13:57 -0400 Subject: [PATCH 2/3] Fix formatting --- compiler-rt/lib/asan/asan_descriptions.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/compiler-rt/lib/asan/asan_descriptions.cpp b/compiler-rt/lib/asan/asan_descriptions.cpp index 387c5692991fb..3d5cc28fab1ee 100644 --- a/compiler-rt/lib/asan/asan_descriptions.cpp +++ b/compiler-rt/lib/asan/asan_descriptions.cpp @@ -475,8 +475,8 @@ AddressDescription::AddressDescription(uptr addr, uptr access_size, #if !SANITIZER_AIX if (GetGlobalAddressInformation(addr, access_size, &data.global)) { - data.kind = kAddressKindGlobal; - return; + data.kind = kAddressKindGlobal; + return; } #endif From 505360a09a87b193ec8ff38e1f84b82862539479 Mon Sep 17 00:00:00 2001 From: Jake Egan Date: Thu, 17 Jul 2025 14:53:16 -0400 Subject: [PATCH 3/3] Add comment --- compiler-rt/lib/asan/asan_descriptions.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/compiler-rt/lib/asan/asan_descriptions.cpp b/compiler-rt/lib/asan/asan_descriptions.cpp index 3d5cc28fab1ee..18c2a6c571c1f 100644 --- a/compiler-rt/lib/asan/asan_descriptions.cpp +++ b/compiler-rt/lib/asan/asan_descriptions.cpp @@ -473,6 +473,7 @@ AddressDescription::AddressDescription(uptr addr, uptr access_size, return; } +// GetGlobalAddressInformation is called earlier on AIX due to a workaround #if !SANITIZER_AIX if (GetGlobalAddressInformation(addr, access_size, &data.global)) { data.kind = kAddressKindGlobal;