All Classes Namespaces Files Functions Variables Typedefs Enumerator Macros Groups Pages
Classes | Namespaces | Macros | Typedefs | Functions
MeterPU.h File Reference
#include <nvml.h>
#include <cpucounters.h>
#include <stdio.h>
#include <stdlib.h>
#include <pthread.h>
#include <vector>
#include <iostream>
#include <fstream>
#include <string>
#include <iomanip>
#include <unistd.h>
#include <assert.h>
Include dependency graph for MeterPU.h:

Go to the source code of this file.

Classes

struct  MeterPU::Meter_Traits< Type >
 Traits Interface. More...
 
struct  MeterPU::NVML_Energy< device_id >
 GPU Energy Traits. More...
 
struct  MeterPU::NVML_Energy_Measurement_Controller< device_id >
 CUDA-enabled GPU Energy Measurement Controller. More...
 
struct  MeterPU::System_Energy< gpu_ids >
 System Energy Traits. More...
 
struct  MeterPU::System_Energy_Measurement_Controller< gpu_device_ids >
 System Energy Measurement Controller. More...
 
class  MeterPU::Meter< Type >
 The software multi-meters. More...
 
struct  MeterPU::Meter_Traits< Type >
 Traits Interface. More...
 
struct  MeterPU::CPU_Time
 Time Traits. More...
 
struct  MeterPU::CUDA_Time
 Cuda Timer Traits. More...
 
struct  MeterPU::PCM_Energy
 PCM Energy Traits. More...
 
struct  MeterPU::NVML_Energy< device_id >
 GPU Energy Traits. More...
 
struct  MeterPU::System_Energy< gpu_ids >
 System Energy Traits. More...
 
struct  MeterPU::Container_Traits< Type >
 
struct  MeterPU::Power_Vector_Container
 
struct  MeterPU::Hp_Power_Vector_Container
 
struct  MeterPU::Time_Vector_Container
 
struct  MeterPU::Environment_Init
 Library Initializer Interface. More...
 
struct  MeterPU::CPU_Time_Environment_Init
 CPU Time Library Initializer. More...
 
struct  MeterPU::CUDA_Time_Environment_Init
 GPU Time Library Initializer. More...
 
struct  MeterPU::PCM_Energy_Environment_Init
 CPU Energy Library Initializer. More...
 
struct  MeterPU::NVML_Energy_Environment_Init
 GPU Energy Library Initializer. More...
 
class  MeterPU::NVML_Energy_Environment_Init::NVML_Manager
 NVML library init and teardown. More...
 
struct  MeterPU::System_Energy_Environment_Init
 System Energy Library Initializer. More...
 
struct  MeterPU::Measurement_Controller
 Measurement Controller Interface. More...
 
struct  MeterPU::CPU_Time_Measurement_Controller
 CPU Time Measurement Controller. More...
 
struct  MeterPU::CUDA_Time_Measurement_Controller
 CUDA-enabled GPU Time Measurement Controller. More...
 
struct  MeterPU::PCM_Energy_Measurement_Controller
 CPU and DRAME Energy Measurement Controller. More...
 
struct  MeterPU::NVML_Energy_Measurement_Controller< device_id >
 CUDA-enabled GPU Energy Measurement Controller. More...
 
struct  MeterPU::NVML_Energy_Measurement_Controller< device_id >::NVML_Energy_Device_Init< device_id_value >
 
class  MeterPU::NVML_Energy_Measurement_Controller< device_id >::Sampling_Thread_Controller
 Sampling Thread Controller. More...
 
struct  MeterPU::System_Energy_Measurement_Controller< gpu_device_ids >
 System Energy Measurement Controller. More...
 

Namespaces

 MeterPU
 

Macros

#define PRINT_FUNC_NAME(message)   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<__func__<<"():] "<<message<<std::endl
 
#define PRINT_FUNC_NAME_CONT   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<__func__<<"():] "
 
#define DECLARE_CLASS_NAME(name)   static std::string class_name(){return name;}
 
#define PRINT_CLASS_FUNC_NAME(message)   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<class_name()<<" "<<__func__<<"():] "<<message<<std::endl
 
#define PRINT_CLASS_FUNC_NAME_CONT   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<class_name()<<" "<<__func__<<"():] "
 
#define METERPU_TIME_MEASURE(x)   clock_gettime(CLOCK_MONOTONIC, x)
 
#define POINTER   ((Meter<NVML_Energy<first_device_id> >*)x[array_index])
 A macro for downcast a void pointer to a NVML Energy Meter. More...
 
#define NOTHING
 
#define LOOPER(name, return_type, base_code, general_code)
 A macro to build variadic template to recursively apply code snippets. More...
 

Typedefs

typedef unsigned int MeterPU::GPU_Device_Id_Type
 

Functions

bool bash_exe (const std::string &cmd, std::vector< std::string > &out)
 
CPU_Time::ResultType MeterPU::operator- (CPU_Time::Time_Unit const &stop_time, CPU_Time::Time_Unit const &start_time)
 Calculate elapsed time between two time stamp. More...
 
bool MeterPU::operator< (CPU_Time::Time_Unit const &small_time, CPU_Time::Time_Unit const &large_time)
 Check if a time stamp is earlier than another. More...
 
bool MeterPU::operator== (CPU_Time::Time_Unit const &small_time, CPU_Time::Time_Unit const &large_time)
 Check if two time stamps are the same. More...
 
bool MeterPU::operator<= (CPU_Time::Time_Unit const &small_time, CPU_Time::Time_Unit const &large_time)
 Check if a time stamp is earlier or equal to another. More...
 
std::ostream & MeterPU::operator<< (std::ostream &out, NVML_Energy<>::Time_Unit ts)
 

Macro Definition Documentation

#define DECLARE_CLASS_NAME (   name)    static std::string class_name(){return name;}
#define METERPU_TIME_MEASURE (   x)    clock_gettime(CLOCK_MONOTONIC, x)
#define PRINT_CLASS_FUNC_NAME (   message)    std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<class_name()<<" "<<__func__<<"():] "<<message<<std::endl
#define PRINT_CLASS_FUNC_NAME_CONT   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<class_name()<<" "<<__func__<<"():] "
#define PRINT_FUNC_NAME (   message)    std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<__func__<<"():] "<<message<<std::endl
#define PRINT_FUNC_NAME_CONT   std::cout<<"["<<__FILE__<<"#"<<__LINE__<<" "<<__func__<<"():] "

Function Documentation

bool bash_exe ( const std::string &  cmd,
std::vector< std::string > &  out 
)

Here is the caller graph for this function: