From ed740c6289b0f9f430b57f7bf9428ec106eeba8c Mon Sep 17 00:00:00 2001 From: bdemsky Date: Wed, 26 Jun 2019 10:33:37 -0700 Subject: [PATCH] get rid of some compile errors and warnings --- execution.cc | 3 --- test/condvar.cc | 10 +++++----- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/execution.cc b/execution.cc index d75499f1..2c08711e 100644 --- a/execution.cc +++ b/execution.cc @@ -778,9 +778,6 @@ bool ModelExecution::r_modification_order(ModelAction *curr, const ModelAction * /* Last SC fence in the current thread */ ModelAction *last_sc_fence_local = get_last_seq_cst_fence(curr->get_tid(), NULL); - ModelAction *last_sc_write = NULL; - if (curr->is_seqcst()) - last_sc_write = get_last_seq_cst_write(curr); int tid = curr->get_tid(); ModelAction *prev_same_thread = NULL; diff --git a/test/condvar.cc b/test/condvar.cc index fcfd59a8..0457c414 100644 --- a/test/condvar.cc +++ b/test/condvar.cc @@ -3,11 +3,11 @@ #include "threads.h" #include "librace.h" #include "stdatomic.h" -#include +#include #include -std::mutex * m; -std::condition_variable *v; +cdsc::mutex * m; +cdsc::condition_variable *v; int shareddata; static void a(void *obj) @@ -32,8 +32,8 @@ int user_main(int argc, char **argv) { thrd_t t1, t2; store_32(&shareddata, (unsigned int) 0); - m=new std::mutex(); - v=new std::condition_variable(); + m=new cdsc::mutex(); + v=new cdsc::condition_variable(); thrd_create(&t1, (thrd_start_t)&a, NULL); thrd_create(&t2, (thrd_start_t)&b, NULL); -- 2.34.1