On screen performance output.
More...
#include <CalcServer/Performance.h>
|
| Performance (const std::string tool_name, const std::string color="white", bool bold=false, const std::string output_file="") |
| Constructor.
|
|
| ~Performance () |
| Destructor.
|
|
void | setup () |
| Initialize the tool.
|
|
void | execute () |
| Launch _execute() without measuring the elapsed time.
|
|
| Report (const std::string tool_name, const std::string fields, unsigned int ipf=1, float fps=0.f) |
| Constructor.
|
|
virtual | ~Report () |
| Destructor.
|
|
virtual void | setup () |
| Initialize the tool.
|
|
const std::string | data (bool with_title=true, bool with_names=true) |
| Return the text string of the data to be printed.
|
|
| Tool (const std::string tool_name, bool once=false) |
|
virtual | ~Tool () |
|
void | name (const std::string tool_name) |
|
const std::string | name () |
|
virtual void | setup () |
|
virtual void | execute () |
| Execute the tool measuring the elapsed time.
|
|
virtual Tool * | next_tool () |
|
size_t | allocatedMemory () const |
|
unsigned int | used_times () const |
|
float | elapsedTime (bool averaged=true) const |
|
float | elapsedTimeVariance () const |
|
float | elapsedTimeDeviation () const |
|
virtual const int | scope_modifier () |
|
|
static std::vector< cl_kernel > | compile (const std::string source, const std::vector< std::string > names, const std::string flags="") |
| Compile an OpenCL source code and generate the corresponding kernel.
|
|
static cl_kernel | compile_kernel (const std::string source, const std::string kernel_name, const std::string flags="") |
| Compile an OpenCL source code and generate the corresponding kernel.
|
|
On screen performance output.
Performance will print the following data:
- Allocated memory in the computational device
- The average CPU time consumend of each tool (GPU time can be taken with the profiling tools of each vendor)
- See also
- Aqua::InputOutput::Logger
◆ Performance()
Aqua::CalcServer::Reports::Performance::Performance |
( |
const std::string |
tool_name, |
|
|
const std::string |
color = "white" , |
|
|
bool |
bold = false , |
|
|
const std::string |
output_file = "" |
|
) |
| |
Constructor.
- Parameters
-
tool_name | Tool name |
color | Color to print the report. Valid colors are:
- "white"
- "green"
- "blue"
- "yellow"
- "red"
- "magenta"
- "cyan"
|
bold | false if the report should not be highlighted with bolded font, true otherwise |
output_file | Path of the output file. Several scape strings can be used, as described in Aqua::newFilePath() |
◆ ~Performance()
Aqua::CalcServer::Reports::Performance::~Performance |
( |
| ) |
|
◆ _execute()
cl_event Aqua::CalcServer::Reports::Performance::_execute |
( |
const std::vector< cl_event > |
events | ) |
|
|
protectedvirtual |
Execute the tool
- Parameters
-
events | List of events that shall be waited before safe execution |
- Returns
- OpenCL event to be waited before accessing the dependencies
Reimplemented from Aqua::CalcServer::Tool.
◆ computeAllocatedMemory()
size_t Aqua::CalcServer::Reports::Performance::computeAllocatedMemory |
( |
| ) |
|
|
protected |
Get the allocated memory.
- Returns
- Allocated memory in the computational device.
◆ execute()
void Aqua::CalcServer::Reports::Performance::execute |
( |
| ) |
|
|
inlinevirtual |
Launch _execute() without measuring the elapsed time.
This tool is measuring the total time elapsed during a single time step computation, and comparing it with the time consumed by the other tools. Hence we should override the overloaded time measuring capabilities
- See also
- Aqua::CalcServer::Tool
Reimplemented from Aqua::CalcServer::Tool.
◆ setup()
void Aqua::CalcServer::Reports::Performance::setup |
( |
| ) |
|
|
virtual |
The documentation for this class was generated from the following files:
- /home/pepe/SPH/Code/aquagpusph/include/CalcServer/Reports/Performance.h
- /home/pepe/SPH/Code/aquagpusph/src/CalcServer/Reports/Performance.cpp