This is an automated email from the ASF dual-hosted git repository.

jiashunzhu pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/brpc.git


The following commit(s) were added to refs/heads/master by this push:
     new 1b486c6f fix compiler optimize thread local variable access on x86_64 
(#2248)
1b486c6f is described below

commit 1b486c6f2b7f2bfe2843fb4100cb1a76bcb3864b
Author: Adonis Ling <[email protected]>
AuthorDate: Mon Jun 5 04:57:21 2023 +0800

    fix compiler optimize thread local variable access on x86_64 (#2248)
---
 src/butil/thread_local.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/butil/thread_local.h b/src/butil/thread_local.h
index 4f77e958..74f9533b 100644
--- a/src/butil/thread_local.h
+++ b/src/butil/thread_local.h
@@ -46,7 +46,7 @@
     var_name = v;                                                              
\
   }
 
-#if defined(__clang__) && (defined(__aarch64__) || defined(__arm64__))
+#if defined(__clang__)
 // Clang compiler is incorrectly caching the address of thread_local variables
 // across a suspend-point. The following macros used to disable the volatile
 // thread local access optimization.


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to