1 //===----------------------------------------------------------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is dual licensed under the MIT and the University of Illinois Open
6 // Source Licenses. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 // UNSUPPORTED: libcpp-has-no-threads
30 G() : alive_(1) {++n_alive;}
31 G(const G& g) : alive_(g.alive_) {++n_alive;}
32 ~G() {alive_ = 0; --n_alive;}
43 bool G::op_run = false;
50 std::thread::id id0 = t0.get_id();
52 std::thread::id id1 = t1.get_id();
53 assert(t0.get_id() == id0);
55 assert(t1.get_id() == std::thread::id());