From 90776cb0ef72d437983c8d29e5a7f2ac264c107d Mon Sep 17 00:00:00 2001 From: Mirko Bonadei Date: Sat, 23 Jan 2021 10:17:02 +0100 Subject: [PATCH] Enable RTC_NO_UNIQUE_ADDRESS on MSan builds. The issue with MSan has been fixed in LLVM in https://reviews.llvm.org/D92727. Bug: webrtc:12218 Change-Id: I73a4831d2ee544948c499ff06c65fe4ce6bee18c Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/203266 Commit-Queue: Tommi Reviewed-by: Tommi Cr-Commit-Position: refs/heads/master@{#33064} --- rtc_base/system/BUILD.gn | 1 - rtc_base/system/no_unique_address.h | 7 +------ 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/rtc_base/system/BUILD.gn b/rtc_base/system/BUILD.gn index 385f2e1d84..9f83c629e2 100644 --- a/rtc_base/system/BUILD.gn +++ b/rtc_base/system/BUILD.gn @@ -57,7 +57,6 @@ rtc_source_set("rtc_export") { rtc_source_set("no_unique_address") { sources = [ "no_unique_address.h" ] - deps = [ "..:sanitizer" ] } if (is_mac || is_ios) { diff --git a/rtc_base/system/no_unique_address.h b/rtc_base/system/no_unique_address.h index eca349c0cc..77e7a99526 100644 --- a/rtc_base/system/no_unique_address.h +++ b/rtc_base/system/no_unique_address.h @@ -11,8 +11,6 @@ #ifndef RTC_BASE_SYSTEM_NO_UNIQUE_ADDRESS_H_ #define RTC_BASE_SYSTEM_NO_UNIQUE_ADDRESS_H_ -#include "rtc_base/sanitizer.h" - // RTC_NO_UNIQUE_ADDRESS is a portable annotation to tell the compiler that // a data member need not have an address distinct from all other non-static // data members of its class. @@ -26,10 +24,7 @@ // should add support for it starting from C++20. Among clang compilers, // clang-cl doesn't support it yet and support is unclear also when the target // platform is iOS. -// -// TODO(bugs.webrtc.org/12218): Re-enable on MSan builds. -#if !RTC_HAS_MSAN && \ - ((defined(__clang__) && !defined(_MSC_VER) && !defined(WEBRTC_IOS)) || \ +#if ((defined(__clang__) && !defined(_MSC_VER) && !defined(WEBRTC_IOS)) || \ __cplusplus > 201703L) // NOLINTNEXTLINE(whitespace/braces) #define RTC_NO_UNIQUE_ADDRESS [[no_unique_address]]