/none/tests/freebsd/fexecve
/none/tests/freebsd/hello_world
/none/tests/freebsd/452275
+/none/tests/freebsd/sanity_level_thread
/none/tests/freebsd/usrstack
/none/tests/freebsd/proc_pid_file
osrel.vgtest \
osrel.stderr.exp \
osrel.stdout.exp \
- swapcontext.vgtest \
- swapcontext.stderr.exp \
- swapcontext.stdout.exp \
fexecve_hw1.vgtest \
fexecve_hw1.stdout.exp \
fexecve_hw1.stderr.exp \
fexecve_txt.stderr.exp \
452275.vgtest \
452275.stderr.exp \
- usrstack.vgtest \
- usrstack.stderr.exp \
- usrstack.stdout.exp \
proc_pid_file.vgtest \
proc_pid_file.stderr.exp \
bash_test.vgtest \
ksh_test.ksh \
ksh_test.stderr.exp \
ksh_test.stdout.exp \
+ sanity_level_thread.vgtest \
+ sanity_level_thread.stderr.exp \
+ swapcontext.vgtest \
+ swapcontext.stderr.exp \
+ swapcontext.stdout.exp \
umtx_op_timeout.vgtest \
- umtx_op_timeout.stderr.exp
+ umtx_op_timeout.stderr.exp \
+ usrstack.vgtest \
+ usrstack.stderr.exp \
+ usrstack.stdout.exp
check_PROGRAMS = \
auxv osrel swapcontext hello_world fexecve 452275 usrstack \
- proc_pid_file
+ proc_pid_file sanity_level_thread
AM_CFLAGS += $(AM_FLAG_M3264_PRI)
AM_CXXFLAGS += $(AM_FLAG_M3264_PRI)
hello_world_SOURCES = hello_world.cpp
proc_pid_file_SOURCES = proc_pid_file.cpp
+
+sanity_level_thread_SOURCES = sanity_level_thread.cpp
+sanity_level_thread_LDFLAGS = ${AM_LDFLAGS} -pthread
--- /dev/null
+#include <string>
+#include <fstream>
+#include <thread>
+
+using namespace std;
+
+ofstream output("output.txt");
+
+void task(string msg)
+{
+ output << "task msg: " << msg;
+}
+
+int main()
+{
+ thread t1(task, "Hello\n");
+ thread t2(task, "World\n");
+
+ t1.join();
+ t2.join();
+}