[all-commits] [llvm/llvm-project] a5ee81: [libc][NFC] Add a platform independent thread supp...

Siva Chandra via All-commits all-commits at lists.llvm.org
Fri Mar 4 10:34:04 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a5ee8183c049d377539c2b6452c8817589dd2df4
      https://github.com/llvm/llvm-project/commit/a5ee8183c049d377539c2b6452c8817589dd2df4
  Author: Siva Chandra Reddy <sivachandra at google.com>
  Date:   2022-03-04 (Fri, 04 Mar 2022)

  Changed paths:
    M libc/include/llvm-libc-types/CMakeLists.txt
    A libc/include/llvm-libc-types/__mutex_type.h
    M libc/include/llvm-libc-types/mtx_t.h
    M libc/src/__support/CMakeLists.txt
    A libc/src/__support/threads/CMakeLists.txt
    A libc/src/__support/threads/linux/CMakeLists.txt
    A libc/src/__support/threads/linux/mutex.h
    A libc/src/__support/threads/mutex.h
    M libc/src/threads/CMakeLists.txt
    M libc/src/threads/linux/CMakeLists.txt
    M libc/src/threads/linux/CndVar.h
    R libc/src/threads/linux/Mutex.h
    M libc/src/threads/linux/cnd_wait.cpp
    R libc/src/threads/linux/mtx_destroy.cpp
    R libc/src/threads/linux/mtx_init.cpp
    R libc/src/threads/linux/mtx_lock.cpp
    R libc/src/threads/linux/mtx_unlock.cpp
    A libc/src/threads/mtx_destroy.cpp
    A libc/src/threads/mtx_init.cpp
    A libc/src/threads/mtx_lock.cpp
    A libc/src/threads/mtx_unlock.cpp

  Log Message:
  -----------
  [libc][NFC] Add a platform independent thread support library.

The idea is that, other parts of the libc which require thread/lock
support will be able to use this platform independent setup.

With this change, only the linux implementation of a mutex type has been
moved to the new library. Because of this, there is some duplication
between the new library and src/threads/linux. A follow up change will
move all of src/threads/linux to the new library. The duplication should
be eliminated with that move.

Reviewed By: lntue

Differential Revision: https://reviews.llvm.org/D120795




More information about the All-commits mailing list