From d15971f784c68e45199ee9052773d6546af131aa Mon Sep 17 00:00:00 2001
From: Brian Demsky <bdemsky@uci.edu>
Date: Thu, 20 Jun 2019 22:31:45 -0700
Subject: [PATCH] performance improvements

---
 execution.cc | 2 +-
 snapshot.cc  | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/execution.cc b/execution.cc
index 52af5212..c32b6288 100644
--- a/execution.cc
+++ b/execution.cc
@@ -783,7 +783,7 @@ bool ModelExecution::r_modification_order(ModelAction *curr, const ModelAction *
 	int tid = curr->get_tid();
 	ModelAction *prev_same_thread = NULL;
 	/* Iterate over all threads */
-	for (i = 0;i < thrd_lists->size();i++, tid = ((tid+1) == thrd_lists->size()) ? 0: tid + 1) {
+	for (i = 0;i < thrd_lists->size();i++, tid = (((unsigned int)(tid+1)) == thrd_lists->size()) ? 0: tid + 1) {
 		/* Last SC fence in thread tid */
 		ModelAction *last_sc_fence_thread_local = NULL;
 		if (i != 0)
diff --git a/snapshot.cc b/snapshot.cc
index ca54c785..bada736d 100644
--- a/snapshot.cc
+++ b/snapshot.cc
@@ -248,7 +248,7 @@ static void mprot_roll_back(snapshot_id theID)
 
 #else	/* !USE_MPROTECT_SNAPSHOT */
 
-#define SHARED_MEMORY_DEFAULT  (100 * ((size_t)1 << 20))	// 100mb for the shared memory
+#define SHARED_MEMORY_DEFAULT  (200 * ((size_t)1 << 20))	// 100mb for the shared memory
 #define STACK_SIZE_DEFAULT      (((size_t)1 << 20) * 20)	// 20 mb out of the above 100 mb for my stack
 
 struct fork_snapshotter {
-- 
2.34.1