Commit db4c2582 authored by Vitaly Buka's avatar Vitaly Buka
Browse files

[scudo] Check if we use __clang_major__ >= 12

This makes sure we have support for MTE instructions.
Later the check can be extended to support MTE on other compilers.

Reviewed By: pcc

Differential Revision: https://reviews.llvm.org/D105722
parent 9c4baf51
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -18,7 +18,7 @@

namespace scudo {

#if defined(__aarch64__) || defined(SCUDO_FUZZ)
#if (__clang_major__ >= 12 && defined(__aarch64__)) || defined(SCUDO_FUZZ)

// We assume that Top-Byte Ignore is enabled if the architecture supports memory
// tagging. Not all operating systems enable TBI, so we only claim architectural
@@ -55,7 +55,7 @@ inline uint8_t extractTag(uptr Ptr) {

#endif

#if defined(__aarch64__)
#if __clang_major__ >= 12 && defined(__aarch64__)

#if SCUDO_LINUX