(git:6344619)
Loading...
Searching...
No Matches
dbm_library.h File Reference
#include "dbm_multiply.h"
#include <stdint.h>

Go to the source code of this file.

Macros

#define DBM_NUM_COUNTERS   64

Enumerations

enum  dbm_library_phase {
  DBM_PHASE_SETUP = 0 , DBM_PHASE_PACK = 1 , DBM_PHASE_ALLTOALL = 2 , DBM_PHASE_SORT = 3 ,
  DBM_PHASE_SHIFT = 4 , DBM_PHASE_UPLOAD = 5 , DBM_PHASE_MULTIPLY = 6 , DBM_PHASE_FINISH = 7 ,
  DBM_NUM_PHASES = 8
}
 Phases of dbm_multiply whose duration the stats report per rank. More...

Functions

void dbm_library_init (void)
 Initializes the DBM library.
void dbm_library_finalize (void)
 Finalizes the DBM library.
static int dbm_library_counter_index (const int m, const int n, const int k)
 Internal routine for the stats counter of a block multiplication, i.e., min(3, floor(log10(x))) per m, n, and k.
void dbm_library_counters_add (const int64_t counters[DBM_NUM_COUNTERS])
 Add the calling thread's counts (dbm_library_counter_index) to the stats. Counting locally first avoids a call per block multiplication. This routine is thread-safe.
void dbm_library_phases_add (const double seconds[DBM_NUM_PHASES], const int64_t bytes[DBM_NUM_PHASES])
 Add the durations (seconds) of a multiplication's phases and the bytes sent by them to the stats. Called once per dbm_multiply outside of parallel regions.
void dbm_library_print_stats (const int fortran_comm, void(*print_func)(const char *, int, int), const int output_unit)
 Prints statistics gathered by the DBM library.

Macro Definition Documentation

◆ DBM_NUM_COUNTERS

#define DBM_NUM_COUNTERS   64

Definition at line 26 of file dbm_library.h.

Enumeration Type Documentation

◆ dbm_library_phase

Phases of dbm_multiply whose duration the stats report per rank.

Author
Hans Pabst
Enumerator
DBM_PHASE_SETUP 
DBM_PHASE_PACK 
DBM_PHASE_ALLTOALL 
DBM_PHASE_SORT 
DBM_PHASE_SHIFT 
DBM_PHASE_UPLOAD 
DBM_PHASE_MULTIPLY 
DBM_PHASE_FINISH 
DBM_NUM_PHASES 

Definition at line 53 of file dbm_library.h.

Function Documentation

◆ dbm_library_init()

void dbm_library_init ( void )

Initializes the DBM library.

Author
Ole Schuett

Definition at line 36 of file dbm_library.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dbm_library_finalize()

void dbm_library_finalize ( void )

Finalizes the DBM library.

Author
Ole Schuett

Definition at line 70 of file dbm_library.c.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ dbm_library_counter_index()

int dbm_library_counter_index ( const int m,
const int n,
const int k )
inlinestatic

Internal routine for the stats counter of a block multiplication, i.e., min(3, floor(log10(x))) per m, n, and k.

Author
Ole Schuett

Definition at line 33 of file dbm_library.h.

Here is the caller graph for this function:

◆ dbm_library_counters_add()

void dbm_library_counters_add ( const int64_t counters[DBM_NUM_COUNTERS])

Add the calling thread's counts (dbm_library_counter_index) to the stats. Counting locally first avoids a call per block multiplication. This routine is thread-safe.

Author
Hans Pabst

Add the calling thread's counts (dbm_library_counter_index) to the stats. Counting locally first avoids a call per block multiplication. This routine is thread-safe.

Author
Hans Pabst

Definition at line 93 of file dbm_library.c.

Here is the caller graph for this function:

◆ dbm_library_phases_add()

void dbm_library_phases_add ( const double seconds[DBM_NUM_PHASES],
const int64_t bytes[DBM_NUM_PHASES] )

Add the durations (seconds) of a multiplication's phases and the bytes sent by them to the stats. Called once per dbm_multiply outside of parallel regions.

Author
Hans Pabst

Add the durations (seconds) of a multiplication's phases and the bytes sent by them to the stats. Called once per dbm_multiply outside of parallel regions.

Author
Hans Pabst

Definition at line 106 of file dbm_library.c.

Here is the caller graph for this function:

◆ dbm_library_print_stats()

void dbm_library_print_stats ( const int fortran_comm,
void(* print_func )(const char *, int, int),
const int output_unit )

Prints statistics gathered by the DBM library.

Author
Ole Schuett

Definition at line 129 of file dbm_library.c.

Here is the call graph for this function:
Here is the caller graph for this function: