[PATCH] D141349: Remove the ThreadLocal template from LLVM.

Owen Anderson via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 9 20:29:09 PST 2023


resistor created this revision.
Herald added subscribers: Moerafaat, zero9178, bzcheeseman, sdasgup3, wenzhicui, wrengr, cota, teijeong, rdzhabarov, tatianashp, msifontes, jurahul, Kayjukh, grosul1, Joonsoo, liufengdb, aartbik, mgester, arpith-jacob, antiagainst, shauheen, rriddle, mehdi_amini, kadircet, arphaman, hiraditya.
Herald added a project: All.
resistor requested review of this revision.
Herald added subscribers: cfe-commits, llvm-commits, stephenneuendorffer, nicolasvasilache.
Herald added projects: MLIR, LLVM, clang-tools-extra.

This has been obsoleted by C++ thread_local for a long time.
As far as I know, Xcode was the last supported toolchain to add
support for C++ thread_local in 2016.

As a precaution, use LLVM_THREAD_LOCAL which provides even greater
backwards compatibility, allowing this to function even pre-C++11
versions of GCC.


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D141349

Files:
  clang-tools-extra/clangd/support/ThreadCrashReporter.cpp
  llvm/include/llvm/Support/ThreadLocal.h
  llvm/lib/Support/CMakeLists.txt
  llvm/lib/Support/CrashRecoveryContext.cpp
  llvm/lib/Support/ThreadLocal.cpp
  llvm/lib/Support/Unix/ThreadLocal.inc
  llvm/lib/Support/Windows/ThreadLocal.inc
  llvm/unittests/Support/CMakeLists.txt
  llvm/unittests/Support/ThreadLocalTest.cpp
  mlir/include/mlir/Support/ThreadLocalCache.h

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D141349.487659.patch
Type: text/x-patch
Size: 15740 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230110/60696241/attachment-0001.bin>


More information about the cfe-commits mailing list