diff VMS.c @ 169:d1dd9e6ee72c

VMS preprocessor definitions moved to VMS_defs.h and changes to measurement
author Merten Sach <msach@mailbox.tu-berlin.de>
date Fri, 16 Dec 2011 20:00:21 +0100
parents cb7277bac147
children bfaebdf60df3
line diff
     1.1 --- a/VMS.c	Thu Oct 06 16:25:59 2011 +0200
     1.2 +++ b/VMS.c	Fri Dec 16 20:00:21 2011 +0100
     1.3 @@ -100,7 +100,8 @@
     1.4  
     1.5  
     1.6        //Make the master env, which holds everything else
     1.7 -   _VMSMasterEnv = malloc( sizeof(MasterEnv) );
     1.8 +   _VMSMasterEnv = malloc(   sizeof(MasterEnv) );
     1.9 +   memset( _VMSMasterEnv, 0, sizeof(MasterEnv) );
    1.10  
    1.11          //Very first thing put into the master env is the free-list, seeded
    1.12          // with a massive initial chunk of memory.
    1.13 @@ -681,6 +682,7 @@
    1.14     //forAllInDynArrayDo( _VMSMasterEnv->measHistsInfo, (DynArrayFnPtr)&printHist );
    1.15     //forAllInDynArrayDo( _VMSMasterEnv->measHistsInfo, (DynArrayFnPtr)&saveHistToFile);
    1.16     //forAllInDynArrayDo( _VMSMasterEnv->measHistsInfo, &freeHistExt );
    1.17 +/*
    1.18     #ifdef MEAS__TIME_PLUGIN
    1.19     printHist( _VMSMasterEnv->reqHdlrLowTimeHist );
    1.20     saveHistToFile( _VMSMasterEnv->reqHdlrLowTimeHist );
    1.21 @@ -712,6 +714,7 @@
    1.22        freeSchedSlots( allSchedSlots[ coreIdx ] );
    1.23      }
    1.24     #endif
    1.25 + */
    1.26     #ifdef MEAS__TIME_STAMP_SUSP
    1.27     printHist( _VMSMasterEnv->pluginTimeHist );
    1.28     for( coreIdx = 0; coreIdx < NUM_CORES; coreIdx++ )
    1.29 @@ -770,3 +773,15 @@
    1.30     exit(1);
    1.31   }
    1.32  
    1.33 +//=======================  Measurement  =======================
    1.34 +#ifdef MEAS__TIME_2011_SYS
    1.35 +uint64
    1.36 +VMS__give_num_plugin_cycles()
    1.37 + { return _VMSMasterEnv->totalPluginCycles;
    1.38 + }
    1.39 +
    1.40 +uint32
    1.41 +VMS__give_num_plugin_animations()
    1.42 + { return _VMSMasterEnv->numPluginAnimations;
    1.43 + }
    1.44 +#endif