[all-commits] [llvm/llvm-project] 3a6340: [libc++] Make __atomic_base into an implementation...
Louis Dionne via All-commits
all-commits at lists.llvm.org
Tue Nov 19 15:35:35 PST 2024
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 3a63407686313f46f9abc664fd10b01f4359ee27
https://github.com/llvm/llvm-project/commit/3a63407686313f46f9abc664fd10b01f4359ee27
Author: Louis Dionne <ldionne.2 at gmail.com>
Date: 2024-11-20 (Wed, 20 Nov 2024)
Changed paths:
M libcxx/include/CMakeLists.txt
M libcxx/include/__atomic/atomic.h
R libcxx/include/__atomic/atomic_base.h
M libcxx/include/atomic
M libcxx/include/barrier
M libcxx/include/latch
M libcxx/include/module.modulemap
M libcxx/include/semaphore
M libcxx/src/barrier.cpp
Log Message:
-----------
[libc++] Make __atomic_base into an implementation detail of std::atomic (#115764)
The __atomic_base base class is only useful to conditionalize the
operations we provide inside std::atomic. It shouldn't be used directly
from other places in the library which can use std::atomic directly
instead.
Since we've granularized our includes, using std::atomic directly should
not make much of a difference compile-time wise.
This patch starts using std::atomic directly from other classes like
std::barrier and std::latch. Changing this shouldn't be an ABI break
since both classes have the same size and layout.
The benefits of this patch are isolating other parts of the code base
from implementation details of std::atomic and simplifying the mental
model for std::atomic's layers of implementation by making it clear that
__atomic_base is only an implementation detail of std::atomic.
To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications
More information about the All-commits
mailing list