1#include "pseudo_barrier.h"
2#include <thread>
3
4
5pseudo_barrier_t barrier_before;
6pseudo_barrier_t barrier_after;
7
8void break_here() {}
9
10void thread_func() {
11 pseudo_barrier_wait(barrier_before);
12 break_here();
13 pseudo_barrier_wait(barrier_after);
14}
15
16int main() {
17 pseudo_barrier_init(barrier_before, 2);
18 pseudo_barrier_init(barrier_after, 2);
19 std::thread thread(thread_func);
20 pseudo_barrier_wait(barrier_before);
21 pseudo_barrier_wait(barrier_after);
22 thread.join();
23 return 0;
24}
25

source code of lldb/test/API/commands/gui/expand-threads-tree/main.cpp