model: add read-acquire/fence-release support
[c11tester.git] / threads.cc
index 7f515159f78052727180b1be6d82ba1df7e9ebac..3b793cff0c443f6f70f6d156e6ec456f40fdbe67 100644 (file)
@@ -4,9 +4,9 @@
 
 #include <string.h>
 
-#include "libthreads.h"
+#include <threads.h>
 #include "common.h"
-#include "threads.h"
+#include "threads-model.h"
 
 /* global "model" object */
 #include "model.h"
@@ -34,8 +34,6 @@ Thread * thread_current(void)
  * Provides a startup wrapper for each thread, allowing some initial
  * model-checking data to be recorded. This method also gets around makecontext
  * not being 64-bit clean
- * @todo We should make the START event always immediately follow the
- * CREATE event, so we don't get redundant traces...
  */
 void thread_startup()
 {
@@ -161,7 +159,7 @@ Thread::Thread(thrd_t *t, void (*func)(void *), void *a) :
        /* Initialize state */
        ret = create_context();
        if (ret)
-               printf("Error in create_context\n");
+               model_print("Error in create_context\n");
 
        id = model->get_next_id();
        *user_thread = id;