[llvm-branch-commits] [compiler-rt] 22b522a - Update sanitizer_tls_get_addr.cpp

via llvm-branch-commits llvm-branch-commits at lists.llvm.org
Wed Sep 11 17:29:25 PDT 2024


Author: Vitaly Buka
Date: 2024-09-11T17:29:21-07:00
New Revision: 22b522a32d76c6c471707ceb6b9b4dcb9407db27

URL: https://github.com/llvm/llvm-project/commit/22b522a32d76c6c471707ceb6b9b4dcb9407db27
DIFF: https://github.com/llvm/llvm-project/commit/22b522a32d76c6c471707ceb6b9b4dcb9407db27.diff

LOG: Update sanitizer_tls_get_addr.cpp

Added: 
    

Modified: 
    compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cpp

Removed: 
    


################################################################################
diff  --git a/compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cpp b/compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cpp
index bf84a2ff60c91c..a1107ff7d24737 100644
--- a/compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cpp
+++ b/compiler-rt/lib/sanitizer_common/sanitizer_tls_get_addr.cpp
@@ -152,8 +152,8 @@ DTLS::DTV *DTLS_on_tls_get_addr(void *arg_void, void *res,
     tls_size = 0;
   }
   if (tls_size) {
-    CHECK_LE(tls_beg, reinterpret_cast<uptr>(res) - kDtvOffset);
-    CHECK_LT(reinterpret_cast<uptr>(res) - kDtvOffset, tls_beg + tls_size);
+    CHECK_LE(tls_beg, reinterpret_cast<uptr>(res));
+    CHECK_LT(reinterpret_cast<uptr>(res), tls_beg + tls_size);
   }
   dtv->beg = tls_beg;
   dtv->size = tls_size;


        


More information about the llvm-branch-commits mailing list