| 80 | } |
| 81 | |
| 82 | T *front() noexcept { |
| 83 | auto const readIdx = readIdx_.load(std::memory_order_relaxed); |
| 84 | if (readIdx == writeIdxCache_) { |
| 85 | writeIdxCache_ = writeIdx_.load(std::memory_order_acquire); |
| 86 | if (writeIdxCache_ == readIdx) { |
| 87 | return nullptr; |
| 88 | } |
| 89 | } |
| 90 | return &slots_[readIdx + kPadding]; |
| 91 | } |
| 92 | |
| 93 | void pop() noexcept { |
| 94 | static_assert(std::is_nothrow_destructible<T>::value, |
no test coverage detected