From: Brian Demsky Date: Thu, 4 Oct 2012 00:26:43 +0000 (-0700) Subject: fix low hanging fruit when profiling... X-Git-Tag: pldi2013~108 X-Git-Url: http://plrg.eecs.uci.edu/git/?p=model-checker.git;a=commitdiff_plain;h=85683f798e0955c43cf6cd8099713c45d9ce882b fix low hanging fruit when profiling... dump typo was turning off optimized version of checkpointing...option 2 is by far fastest was spending most of the time freeing an oversized hashtable --- diff --git a/cyclegraph.cc b/cyclegraph.cc index aa3d245..f4d3b93 100644 --- a/cyclegraph.cc +++ b/cyclegraph.cc @@ -174,7 +174,7 @@ bool CycleGraph::checkReachable(const ModelAction *from, const ModelAction *to) */ bool CycleGraph::checkReachable(CycleNode *from, CycleNode *to) { std::vector > queue; - HashTable discovered; + HashTable discovered(64); queue.push_back(from); discovered.put(from, from); diff --git a/snapshot.cc b/snapshot.cc index b889791..f129f4c 100644 --- a/snapshot.cc +++ b/snapshot.cc @@ -283,7 +283,7 @@ snapshot_id takeSnapshot( ){ * @param theID is the snapshot identifier to rollback to. */ void rollBack( snapshot_id theID ){ -#if USE_MPOTECT_SNAPSHOT==2 +#if USE_MPROTECT_SNAPSHOT==2 if (snapshotrecord->lastSnapShot==(theID+1)) { for(unsigned int page=snapshotrecord->snapShots[theID].firstBackingPage; pagelastBackingPage; page++) { memcpy(snapshotrecord->backingRecords[page].basePtrOfPage, &snapshotrecord->backingStore[page], sizeof(struct SnapShotPage));