+/** @file snapshotimp.h
+ * @brief Snapshotting implementation header file..
+ */
+
#ifndef _SNAPSHOTIMP_H
#define _SNAPSHOTIMP_H
#include "snapshot.h"
#define SHARED_MEMORY_DEFAULT ( 100 * ( 1 << 20 ) ) // 100mb for the shared memory
#define STACK_SIZE_DEFAULT ( ( 1 << 20 ) * 20 ) //20 mb out of the above 100 mb for my stack.
-#if USE_CHECKPOINTING
+#if USE_MPROTECT_SNAPSHOT
//Each snapshotrecord lists the firstbackingpage that must be written to revert to that snapshot
struct SnapShotRecord {
unsigned int firstBackingPage;
//Global reference to snapshot data structure
extern struct SnapShot * snapshotrecord;
-void * ReturnPageAlignedAddress( void *);
-void * PageAlignAddressUpward( void *);
#else
-struct Snapshot_t{
+struct Snapshot {
char *mSharedMemoryBase;
char *mStackBase;
size_t mStackSize;
snapshot_id currSnapShotID;
volatile bool mbFinalize;
};
-extern struct Snapshot_t * sTheRecord;
+extern struct Snapshot * sTheRecord;
#endif
#endif