[commit: ghc] master: rts: delint/detab/dewhitespace Papi.c (42f3bdf)

git at git.haskell.org git at git.haskell.org
Mon Jul 28 14:36:42 UTC 2014


Repository : ssh://git@git.haskell.org/ghc

On branch  : master
Link       : http://ghc.haskell.org/trac/ghc/changeset/42f3bdf3267c2cb3f741de1550507c88c860673f/ghc

>---------------------------------------------------------------

commit 42f3bdf3267c2cb3f741de1550507c88c860673f
Author: Austin Seipp <austin at well-typed.com>
Date:   Mon Jul 21 20:30:16 2014 -0500

    rts: delint/detab/dewhitespace Papi.c
    
    Signed-off-by: Austin Seipp <austin at well-typed.com>


>---------------------------------------------------------------

42f3bdf3267c2cb3f741de1550507c88c860673f
 rts/Papi.c | 74 +++++++++++++++++++++++++++++++-------------------------------
 1 file changed, 37 insertions(+), 37 deletions(-)

diff --git a/rts/Papi.c b/rts/Papi.c
index 62f5d0d..3da612e 100644
--- a/rts/Papi.c
+++ b/rts/Papi.c
@@ -64,7 +64,7 @@ struct _papi_events {
 #define PAPI_CHECK(CALL) \
   if((papi_error=(CALL)) != PAPI_OK) { \
    debugBelch("PAPI function failed in module %s at line %d with error code %d\n", \
-	      __FILE__,__LINE__,papi_error);				\
+              __FILE__,__LINE__,papi_error);                            \
   }
 
 /* While PAPI reporting is going on this flag is on */
@@ -130,24 +130,24 @@ init_countable_events(void)
 #define PAPI_ADD_EVENT(EVENT) papi_add_event(#EVENT,EVENT)
 
     if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_BRANCH) {
-	PAPI_ADD_EVENT(FR_BR);
-	PAPI_ADD_EVENT(FR_BR_MIS);
-	/* Docs are wrong? Opteron does not count indirect branch misses exclusively */
-	PAPI_ADD_EVENT(FR_BR_MISCOMPARE);
+        PAPI_ADD_EVENT(FR_BR);
+        PAPI_ADD_EVENT(FR_BR_MIS);
+        /* Docs are wrong? Opteron does not count indirect branch misses exclusively */
+        PAPI_ADD_EVENT(FR_BR_MISCOMPARE);
     } else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_STALLS) {
-	PAPI_ADD_EVENT(FR_DISPATCH_STALLS);
-	PAPI_ADD_EVENT(FR_DISPATCH_STALLS_BR);
-	PAPI_ADD_EVENT(FR_DISPATCH_STALLS_FULL_LS);
+        PAPI_ADD_EVENT(FR_DISPATCH_STALLS);
+        PAPI_ADD_EVENT(FR_DISPATCH_STALLS_BR);
+        PAPI_ADD_EVENT(FR_DISPATCH_STALLS_FULL_LS);
     } else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_CACHE_L1) {
-	PAPI_ADD_EVENT(PAPI_L1_DCA);
-	PAPI_ADD_EVENT(PAPI_L1_DCM);
+        PAPI_ADD_EVENT(PAPI_L1_DCA);
+        PAPI_ADD_EVENT(PAPI_L1_DCM);
     } else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_CACHE_L2) {
-	PAPI_ADD_EVENT(PAPI_L2_DCA);
-	PAPI_ADD_EVENT(PAPI_L2_DCM);
+        PAPI_ADD_EVENT(PAPI_L2_DCA);
+        PAPI_ADD_EVENT(PAPI_L2_DCM);
     } else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_CB_EVENTS) {
-	PAPI_ADD_EVENT(DC_L2_REFILL_MOES);
-	PAPI_ADD_EVENT(DC_SYS_REFILL_MOES);
-	PAPI_ADD_EVENT(FR_BR_MIS);
+        PAPI_ADD_EVENT(DC_L2_REFILL_MOES);
+        PAPI_ADD_EVENT(DC_SYS_REFILL_MOES);
+        PAPI_ADD_EVENT(FR_BR_MIS);
     } else if (RtsFlags.PapiFlags.eventType==PAPI_USER_EVENTS) {
         nat i;
         char *name;
@@ -167,24 +167,24 @@ init_countable_events(void)
           papi_add_event(name, code);
         }
     } else {
-	// PAPI_ADD_EVENT(PAPI_L1_DCA); // L1 data cache accesses
-	// PAPI_ADD_EVENT(PAPI_L1_ICR); // L1 instruction cache reads
-	// PAPI_ADD_EVENT(PAPI_L1_ICM); // L1 instruction cache misses
-	// PAPI_ADD_EVENT(PAPI_L1_STM); // L1 store misses
-	// PAPI_ADD_EVENT(PAPI_L1_DCM); // L1 data cache misses
-	// PAPI_ADD_EVENT(PAPI_L1_LDM); // L1 load misses
-	// PAPI_ADD_EVENT(PAPI_L2_TCM); // L2 cache misses
-	// PAPI_ADD_EVENT(PAPI_L2_STM); // L2 store misses
-	// PAPI_ADD_EVENT(PAPI_L2_DCW); // L2 data cache writes
-	// PAPI_ADD_EVENT(PAPI_L2_DCR); // L2 data cache reads
-	// PAPI_ADD_EVENT(PAPI_L2_TCW); // L2 cache writes
-	// PAPI_ADD_EVENT(PAPI_L2_TCR); // L2 cache reads
-	// PAPI_ADD_EVENT(PAPI_CA_CLN); // exclusive access to clean cache line
-	// PAPI_ADD_EVENT(PAPI_TLB_DM); // TLB misses
+        // PAPI_ADD_EVENT(PAPI_L1_DCA); // L1 data cache accesses
+        // PAPI_ADD_EVENT(PAPI_L1_ICR); // L1 instruction cache reads
+        // PAPI_ADD_EVENT(PAPI_L1_ICM); // L1 instruction cache misses
+        // PAPI_ADD_EVENT(PAPI_L1_STM); // L1 store misses
+        // PAPI_ADD_EVENT(PAPI_L1_DCM); // L1 data cache misses
+        // PAPI_ADD_EVENT(PAPI_L1_LDM); // L1 load misses
+        // PAPI_ADD_EVENT(PAPI_L2_TCM); // L2 cache misses
+        // PAPI_ADD_EVENT(PAPI_L2_STM); // L2 store misses
+        // PAPI_ADD_EVENT(PAPI_L2_DCW); // L2 data cache writes
+        // PAPI_ADD_EVENT(PAPI_L2_DCR); // L2 data cache reads
+        // PAPI_ADD_EVENT(PAPI_L2_TCW); // L2 cache writes
+        // PAPI_ADD_EVENT(PAPI_L2_TCR); // L2 cache reads
+        // PAPI_ADD_EVENT(PAPI_CA_CLN); // exclusive access to clean cache line
+        // PAPI_ADD_EVENT(PAPI_TLB_DM); // TLB misses
         PAPI_ADD_EVENT(PAPI_TOT_INS); // Total instructions
         PAPI_ADD_EVENT(PAPI_TOT_CYC); // Total instructions
-	// PAPI_ADD_EVENT(PAPI_CA_SHR); // exclusive access to shared cache line
-	// PAPI_ADD_EVENT(PAPI_RES_STL); // Cycles stalled on any resource
+        // PAPI_ADD_EVENT(PAPI_CA_SHR); // exclusive access to shared cache line
+        // PAPI_ADD_EVENT(PAPI_RES_STL); // Cycles stalled on any resource
 
     }
 
@@ -219,16 +219,16 @@ papi_report(long_long counters[])
     }
 
     if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_BRANCH) {
-	PAPI_REPORT_PCT(counters,FR_BR_MIS,FR_BR);
-	PAPI_REPORT_PCT(counters,FR_BR_MISCOMPARE,FR_BR);
+        PAPI_REPORT_PCT(counters,FR_BR_MIS,FR_BR);
+        PAPI_REPORT_PCT(counters,FR_BR_MISCOMPARE,FR_BR);
     }
 
     else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_CACHE_L1) {
-	PAPI_REPORT_PCT(counters,PAPI_L1_DCM,PAPI_L1_DCA);
+        PAPI_REPORT_PCT(counters,PAPI_L1_DCM,PAPI_L1_DCA);
     }
 
     else if (RtsFlags.PapiFlags.eventType==PAPI_FLAG_CACHE_L2) {
-	PAPI_REPORT_PCT(counters,PAPI_L2_DCM,PAPI_L2_DCA);
+        PAPI_REPORT_PCT(counters,PAPI_L2_DCM,PAPI_L2_DCA);
     }
 }
 
@@ -310,10 +310,10 @@ papi_add_events(int EventSet)
   nat i;
   for(i=0;i<n_papi_events;i++) {
     if((papi_error=PAPI_add_event(EventSet,
-				  papi_events[i].event_code))
+                                  papi_events[i].event_code))
        != PAPI_OK)
       debugBelch("Failed adding %s to event set with error code %d\n",
-		 papi_events[i].event_name,papi_error);
+                 papi_events[i].event_name,papi_error);
   }
 }
 



More information about the ghc-commits mailing list