[PATCH] D20328: [libcxx] Externally threaded libc++ variant

Asiri Rathnayake via cfe-commits cfe-commits at lists.llvm.org
Tue May 17 06:34:59 PDT 2016


rmaprath created this revision.
rmaprath added reviewers: mclow.lists, EricWF, bcraig.
rmaprath added a subscriber: cfe-commits.

This patch builds on the work done under D19412 where all `pthread` dependencies were refactored under a separate thread-support API.

The current patch enables building a new variant of libc++ where all the threading dependencies are exported into a runtime API. This allows platform vendors to  re-target these threading calls in a platform-defined manner (at runtime), paving the way for libc++ on non-pthread platforms.

For running the libc++ test suite, I've introduced a sample implementation of this external-thread-API using pthreads. This implementation should give an idea of what the end goal is.

This patch supersedes the sketch presented in D19415.

http://reviews.llvm.org/D20328

Files:
  CMakeLists.txt
  include/__config
  include/__config_site.in
  include/__threading_support
  include/thread
  lib/CMakeLists.txt
  src/algorithm.cpp
  src/memory.cpp
  src/mutex.cpp
  src/thread.cpp
  test/CMakeLists.txt
  test/libcxx/test/config.py
  test/lit.site.cfg.in
  test/std/thread/thread.condition/thread.condition.condvar/native_handle.pass.cpp
  test/std/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.class/native_handle.pass.cpp
  test/std/thread/thread.mutex/thread.mutex.requirements/thread.mutex.requirements.mutex/thread.mutex.recursive/native_handle.pass.cpp
  test/std/thread/thread.threads/thread.thread.class/thread.thread.member/native_handle.pass.cpp
  test/std/thread/thread.threads/thread.thread.class/types.pass.cpp
  test/support/external_threads.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D20328.57471.patch
Type: text/x-patch
Size: 27536 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20160517/4e1a3aa4/attachment-0001.bin>


More information about the cfe-commits mailing list