Skip to content

Commit c884db3

Browse files
committed
crimson/os/alienstore: use homebrew counting_semaphore
std::counting_semaphore has the bug: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104928, go back to our homebrew version Signed-off-by: Xuehan Xu <[email protected]>
1 parent 8aba1b1 commit c884db3

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

src/crimson/os/alienstore/thread_pool.h

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,10 @@
1515
#include <seastar/core/semaphore.hh>
1616
#include <seastar/core/sharded.hh>
1717

18-
#if __cplusplus > 201703L
19-
#include <semaphore>
20-
namespace crimson {
21-
using std::counting_semaphore;
22-
}
23-
#else
18+
// std::counting_semaphore is buggy in libstdc++-11
19+
// (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=104928),
20+
// so we switch back to the homebrew version for now.
2421
#include "semaphore.h"
25-
#endif
2622

2723
namespace crimson::os {
2824

0 commit comments

Comments
 (0)