1#include <cassert>
2#include <iostream>
3#include <thread>
4
5void g() { assert(false); }
6
7void f() { g(); }
8
9size_t h() {
10 size_t sum = 0;
11 for (size_t i = 0; i < 1000000; ++i)
12 for (size_t j = 0; j < 1000000; ++j)
13 if ((i * j) % 2 == 0) {
14 sum += 1;
15 }
16 return sum;
17}
18
19int main() {
20 std::thread t1(f);
21
22 size_t x = h();
23
24 t1.join();
25
26 std::cout << "X is " << x << "\n";
27 return 0;
28}
29

source code of lldb/test/API/functionalities/process_save_core_minidump/main.cpp