diff probes.h @ 200:6db9e4898978

VMS name chgs -- added "WL" "PI" and "int" and split vms.h up
author Me@portablequad
date Sun, 12 Feb 2012 01:49:33 -0800
parents c1784868dcea
children
line diff
     1.1 --- a/probes.h	Sat Feb 11 21:43:43 2012 -0800
     1.2 +++ b/probes.h	Sun Feb 12 01:49:33 2012 -0800
     1.3 @@ -14,15 +14,10 @@
     1.4  
     1.5  #include <sys/time.h>
     1.6  
     1.7 +/*Note on order of include files:  
     1.8 + * This file relies on #defines that appear in other files..
     1.9 + */
    1.10  
    1.11 -   //when STATS__TURN_ON_PROBES is defined allows using probes to measure
    1.12 -   // time intervals.  The probes are macros that only compile to something
    1.13 -   // when STATS__TURN_ON_PROBES is defined.  The probes are saved in the
    1.14 -   // master env -- but only when this is defined.
    1.15 -   //The TSC probes use RDTSC instr, can be unreliable, Dbl uses gettimeofday
    1.16 -#define STATS__TURN_ON_PROBES
    1.17 -//#define STATS__USE_TSC_PROBES
    1.18 -#define STATS__USE_DBL_PROBES
    1.19  
    1.20  //typedef struct _IntervalProbe IntervalProbe; //in VMS.h
    1.21  
    1.22 @@ -50,21 +45,13 @@
    1.23   };
    1.24  
    1.25  
    1.26 -//============================= Statistics ==================================
    1.27 -
    1.28 -   //Frequency of TS counts
    1.29 -   //TODO: change freq for each machine
    1.30 -#define TSCOUNT_FREQ 3180000000
    1.31 -
    1.32 -inline TSCount getTSCount();
    1.33 -
    1.34  
    1.35  //======================== Probes =============================
    1.36  //
    1.37  // Use macros to allow turning probes off with a #define switch
    1.38  #ifdef STATS__ENABLE_PROBES
    1.39  int32
    1.40 -VMS_impl__record_time_point_into_new_probe( char *nameStr,VirtProcr *animPr);
    1.41 +VMS_impl__record_time_point_into_new_probe( char *nameStr,SlaveVP *animPr);
    1.42  #define VMS__record_time_point_into_new_probe( nameStr, animPr ) \
    1.43          VMS_impl__record_time_point_in_new_probe( nameStr, animPr )
    1.44  
    1.45 @@ -75,14 +62,14 @@
    1.46  
    1.47  
    1.48  int32
    1.49 -VMS_impl__create_single_interval_probe( char *nameStr, VirtProcr *animPr );
    1.50 +VMS_impl__create_single_interval_probe( char *nameStr, SlaveVP *animPr );
    1.51  #define VMS__create_single_interval_probe( nameStr, animPr ) \
    1.52          VMS_impl__create_single_interval_probe( nameStr, animPr )
    1.53  
    1.54  
    1.55  int32
    1.56  VMS_impl__create_histogram_probe( int32   numBins, float64    startValue,
    1.57 -               float64 binWidth, char    *nameStr, VirtProcr *animPr );
    1.58 +               float64 binWidth, char    *nameStr, SlaveVP *animPr );
    1.59  #define VMS__create_histogram_probe(      numBins, startValue,              \
    1.60                                            binWidth, nameStr, animPr )       \
    1.61          VMS_impl__create_histogram_probe( numBins, startValue,              \
    1.62 @@ -93,17 +80,17 @@
    1.63          VMS_impl__free_probe( probe )
    1.64  
    1.65  void
    1.66 -VMS_impl__index_probe_by_its_name( int32 probeID, VirtProcr *animPr );
    1.67 +VMS_impl__index_probe_by_its_name( int32 probeID, SlaveVP *animPr );
    1.68  #define VMS__index_probe_by_its_name( probeID, animPr ) \
    1.69          VMS_impl__index_probe_by_its_name( probeID, animPr )
    1.70  
    1.71  IntervalProbe *
    1.72 -VMS_impl__get_probe_by_name( char *probeName, VirtProcr *animPr );
    1.73 +VMS_impl__get_probe_by_name( char *probeName, SlaveVP *animPr );
    1.74  #define VMS__get_probe_by_name( probeID, animPr ) \
    1.75          VMS_impl__get_probe_by_name( probeName, animPr )
    1.76  
    1.77  void
    1.78 -VMS_impl__record_sched_choice_into_probe( int32 probeID, VirtProcr *animPr );
    1.79 +VMS_impl__record_sched_choice_into_probe( int32 probeID, SlaveVP *animPr );
    1.80  #define VMS__record_sched_choice_into_probe( probeID, animPr ) \
    1.81          VMS_impl__record_sched_choice_into_probe( probeID, animPr )
    1.82  
    1.83 @@ -130,7 +117,7 @@
    1.84  
    1.85  #else
    1.86  int32
    1.87 -VMS_impl__record_time_point_into_new_probe( char *nameStr,VirtProcr *animPr);
    1.88 +VMS_impl__record_time_point_into_new_probe( char *nameStr,SlaveVP *animPr);
    1.89  #define VMS__record_time_point_into_new_probe( nameStr, animPr ) \
    1.90         0 /* do nothing */
    1.91  
    1.92 @@ -141,30 +128,30 @@
    1.93  
    1.94  
    1.95  int32
    1.96 -VMS_impl__create_single_interval_probe( char *nameStr, VirtProcr *animPr );
    1.97 +VMS_impl__create_single_interval_probe( char *nameStr, SlaveVP *animPr );
    1.98  #define VMS__create_single_interval_probe( nameStr, animPr ) \
    1.99         0 /* do nothing */
   1.100  
   1.101  
   1.102  int32
   1.103  VMS_impl__create_histogram_probe( int32   numBins, float64    startValue,
   1.104 -               float64 binWidth, char    *nameStr, VirtProcr *animPr );
   1.105 +               float64 binWidth, char    *nameStr, SlaveVP *animPr );
   1.106  #define VMS__create_histogram_probe(      numBins, startValue,              \
   1.107                                            binWidth, nameStr, animPr )       \
   1.108         0 /* do nothing */
   1.109  
   1.110  void
   1.111 -VMS_impl__index_probe_by_its_name( int32 probeID, VirtProcr *animPr );
   1.112 +VMS_impl__index_probe_by_its_name( int32 probeID, SlaveVP *animPr );
   1.113  #define VMS__index_probe_by_its_name( probeID, animPr ) \
   1.114          /* do nothing */
   1.115  
   1.116  IntervalProbe *
   1.117 -VMS_impl__get_probe_by_name( char *probeName, VirtProcr *animPr );
   1.118 +VMS_impl__get_probe_by_name( char *probeName, SlaveVP *animPr );
   1.119  #define VMS__get_probe_by_name( probeID, animPr ) \
   1.120         NULL /* do nothing */
   1.121  
   1.122  void
   1.123 -VMS_impl__record_sched_choice_into_probe( int32 probeID, VirtProcr *animPr );
   1.124 +VMS_impl__record_sched_choice_into_probe( int32 probeID, SlaveVP *animPr );
   1.125  #define VMS__record_sched_choice_into_probe( probeID, animPr ) \
   1.126          /* do nothing */
   1.127