repo.or.cz
/
valgrind.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
regtest: broaden none/tests/linux/bug498317 suppression for PPC
[valgrind.git]
/
none
/
tests
/
freebsd
/
sanity_level_thread.cpp
blob
c45cbeadeea8761779be26007a7d5f810a38a65f
1
#include <string>
2
#include <fstream>
3
#include <thread>
4
5
using namespace
std
;
6
7
ofstream
output
(
"output.txt"
);
8
9
void
task
(
string msg
)
10
{
11
output
<<
"task msg: "
<<
msg
;
12
}
13
14
int
main
()
15
{
16
thread
t1
(
task
,
"Hello
\n
"
);
17
thread
t2
(
task
,
"World
\n
"
);
18
19
t1
.
join
();
20
t2
.
join
();
21
}