Merge branch 'charm' of charmgit:charm into charm
authorPritish Jetley <pjetley2@illinois.edu>
Tue, 2 Mar 2010 22:27:09 +0000 (16:27 -0600)
committerPritish Jetley <pjetley2@illinois.edu>
Tue, 2 Mar 2010 22:27:09 +0000 (16:27 -0600)
src/arch/cuda/hybridAPI/cuda-hybrid-api.cu
src/arch/cuda/hybridAPI/wr.h

index f5e1cc26d7ffd90b911546f69bd825c22ec1a66b..9cf8f4b9f0b3ec239988ec9197c3650548f04e8c 100644 (file)
@@ -534,7 +534,7 @@ void gpuProgressFn() {
 #endif
 
 #ifdef GPU_INSTRUMENT_WRS
-    head->startTime = CmiWallTimer(); 
+    head->phaseStartTime = CmiWallTimer(); 
 #endif
 
     allocateBuffers(head); 
@@ -556,7 +556,7 @@ void gpuProgressFn() {
 #ifdef GPU_INSTRUMENT_WRS
       {
         if(initializedInstrument()){
-          double tt = CmiWallTimer()-(head->startTime);
+          double tt = CmiWallTimer()-(head->phaseStartTime);
           int index = head->chareIndex;
           char type = head->compType;
           char phase = head->compPhase;
@@ -586,7 +586,7 @@ void gpuProgressFn() {
       timeIndex++; 
 #endif
 #ifdef GPU_INSTRUMENT_WRS
-      head->startTime = CmiWallTimer(); 
+      head->phaseStartTime = CmiWallTimer(); 
 #endif
 
       //flushPinnedMemQueue();
@@ -608,7 +608,7 @@ void gpuProgressFn() {
 #endif
 
 #ifdef GPU_INSTRUMENT_WRS
-        second->startTime = CmiWallTimer();
+        second->phaseStartTime = CmiWallTimer();
 #endif
        setupData(second); 
        second->state = TRANSFERRING_IN;
@@ -635,7 +635,7 @@ void gpuProgressFn() {
 #ifdef GPU_INSTRUMENT_WRS
       {
         if(initializedInstrument()){
-          double tt = CmiWallTimer()-(head->startTime);
+          double tt = CmiWallTimer()-(head->phaseStartTime);
           int index = head->chareIndex;
           char type = head->compType;
           char phase = head->compPhase;
@@ -663,8 +663,8 @@ void gpuProgressFn() {
        timeIndex++; 
 #endif
 
-#ifdef GPU_INSTRUMENT_MS
-        second->startTime = CmiWallTimer();
+#ifdef GPU_INSTRUMENT_WRS
+        second->phaseStartTime = CmiWallTimer();
 #endif
         
        allocateBuffers(second); 
@@ -685,7 +685,7 @@ void gpuProgressFn() {
 #ifdef GPU_INSTRUMENT_WRS
           {
             if(initializedInstrument()){
-              double tt = CmiWallTimer()-(second->startTime);
+              double tt = CmiWallTimer()-(second->phaseStartTime);
               int index = second->chareIndex;
               char type = second->compType;
               char phase = second->compPhase;
@@ -715,7 +715,7 @@ void gpuProgressFn() {
          timeIndex++; 
 #endif
 #ifdef GPU_INSTRUMENT_WRS
-          second->startTime = CmiWallTimer();
+          second->phaseStartTime = CmiWallTimer();
 #endif
          //        flushPinnedMemQueue();          
           flushDelayedFrees();
@@ -735,7 +735,7 @@ void gpuProgressFn() {
 #endif
 
 #ifdef GPU_INSTRUMENT_WRS
-            third->startTime = CmiWallTimer();
+            third->phaseStartTime = CmiWallTimer();
 #endif
            setupData(third); 
            third->state = TRANSFERRING_IN;     
@@ -754,7 +754,7 @@ void gpuProgressFn() {
       timeIndex++; 
 #endif
 #ifdef GPU_INSTRUMENT_WRS
-      head->startTime = CmiWallTimer(); 
+      head->phaseStartTime = CmiWallTimer(); 
 #endif
       copybackData(head);
       head->state = TRANSFERRING_OUT;
@@ -781,7 +781,7 @@ void gpuProgressFn() {
 #ifdef GPU_INSTRUMENT_WRS
       {
         if(initializedInstrument()){
-          double tt = CmiWallTimer()-(head->startTime);
+          double tt = CmiWallTimer()-(head->phaseStartTime);
           int index = head->chareIndex;
           char type = head->compType;
           char phase = head->compPhase;
index 49bd2b8a5d8fc0821dd975156403fe3435127294..7080b217fd3d8c75b5141096773907bce0f939ae 100644 (file)
@@ -114,10 +114,14 @@ typedef struct workRequest {
   void *userData; 
 
 #ifdef GPU_INSTRUMENT_WRS
-  double startTime;
+  double phaseStartTime;
   int chareIndex;
   char compType;
   char compPhase;
+
+  workRequest(){
+    chareIndex = -1;
+  }
 #endif
 
 } workRequest;