From 844c9dfe70b4323e9e8a2c13a948b5f4d41bc820 Mon Sep 17 00:00:00 2001 From: jihoonl Date: Wed, 6 Jan 2010 07:33:21 +0000 Subject: [PATCH] removing debugging messages --- .../src/Runtime/DSTM/interface_recovery/dstmserver.c | 3 +-- Robust/src/Runtime/DSTM/interface_recovery/mlookup.c | 6 ++++-- Robust/src/Runtime/DSTM/interface_recovery/trans.c | 10 ++++++++-- 3 files changed, 13 insertions(+), 6 deletions(-) diff --git a/Robust/src/Runtime/DSTM/interface_recovery/dstmserver.c b/Robust/src/Runtime/DSTM/interface_recovery/dstmserver.c index 6e6c3168..ef09f187 100644 --- a/Robust/src/Runtime/DSTM/interface_recovery/dstmserver.c +++ b/Robust/src/Runtime/DSTM/interface_recovery/dstmserver.c @@ -457,8 +457,7 @@ void *dstmAccept(void *acceptfd) { } recv_data((int)acceptfd, buffer, size); - - + oid = *((unsigned int *)buffer); size = sizeof(unsigned int); version = *((unsigned short *)(buffer+size)); diff --git a/Robust/src/Runtime/DSTM/interface_recovery/mlookup.c b/Robust/src/Runtime/DSTM/interface_recovery/mlookup.c index fa4cef88..1d19b851 100644 --- a/Robust/src/Runtime/DSTM/interface_recovery/mlookup.c +++ b/Robust/src/Runtime/DSTM/interface_recovery/mlookup.c @@ -221,12 +221,14 @@ int mhashGetDuplicate(void **dupeptr, int backup) { //how big? mhashlistnode_t *node; // go through object store; // track sizes, oids, and num +// printf("%s -> Before mutex lock\n",__func__); pthread_mutex_lock(&mlookup.locktable); +// printf("%s -> After mutex lock\n",__func__); size =0; tempsize =0; - for(i = 0; i < mlookup.size; i++) { + for(i = 0; i < mlookup.size; i++) { if (mlookup.table[i].key != 0) { node = &mlookup.table[i]; while(node != NULL) { // no nodes @@ -245,6 +247,7 @@ int mhashGetDuplicate(void **dupeptr, int backup) { //how big? } } } +// printf("%s -> size = %d\n",__func__,size); pthread_mutex_unlock(&mlookup.locktable); @@ -264,7 +267,6 @@ int mhashGetDuplicate(void **dupeptr, int backup) { //how big? ptr += sizeof(unsigned int); *((int *)(ptr)) = size; ptr += sizeof(int); - void* ttt = *dupeptr; for(i = 0; i < numdupe; i++) { header = mhashSearch(oidsdupe[i]); diff --git a/Robust/src/Runtime/DSTM/interface_recovery/trans.c b/Robust/src/Runtime/DSTM/interface_recovery/trans.c index f69d750b..4f98e5e1 100644 --- a/Robust/src/Runtime/DSTM/interface_recovery/trans.c +++ b/Robust/src/Runtime/DSTM/interface_recovery/trans.c @@ -1761,7 +1761,6 @@ int transComProcess(trans_req_data_t *tdata, trans_commit_data_t *transinfo) { } header->version += 1; - //printf("oid: %u, new header version: %d\n", oidmod[i], header->version); if(header->notifylist != NULL) { #ifdef RECOVERY if(header->isBackup != 0) // if it is primary obj, notify @@ -2501,6 +2500,9 @@ int allHostsLive() { #ifdef RECOVERY void duplicateLostObjects(unsigned int mid){ + printf("Recovery Start"); + time_t st = time(NULL); + time_t fi; #ifndef DEBUG printf("%s-> Start, mid: [%s]\n", __func__, midtoIPString(mid)); #endif @@ -2583,6 +2585,10 @@ void duplicateLostObjects(unsigned int mid){ freeSockWithLock(transPrefetchSockPool, backupMid, sd); } + fi = time(NULL); + + printf("time elapse = %d",fi-st); + #ifndef DEBUG printf("%s-> End\n", __func__); #endif @@ -2804,7 +2810,7 @@ int reqNotify(unsigned int *oidarry, unsigned short *versionarry, unsigned int n return -1; } ndata->numoid = numoid; - printf("%s -> ndata = %d numoid = %d\n",__func__,ndata,numoid); +// printf("%s -> ndata = %d numoid = %d\n",__func__,ndata,numoid); ndata->threadid = threadid; ndata->oidarry = oidarry; ndata->versionarry = versionarry; -- 2.34.1