SLATE 2024.05.31
Software for Linear Algebra Targeting Exascale
|
Slate::Debug - helper class used for debugging during development. More...
#include <Debug.hh>
Static Public Member Functions | |
static void | on () |
Enable debugging output. | |
static void | off () |
Disable debugging output. | |
template<typename scalar_t > | |
static void | diffLapackMatrices (int64_t m, int64_t n, scalar_t const *A, int64_t lda, scalar_t const *B, int64_t ldb, int64_t mb, int64_t nb) |
Prints a summary of differences between matrices A and B. | |
template<typename scalar_t > | |
static void | checkTilesLives (BaseMatrix< scalar_t > const &A) |
Prints information about tiles with local instances. | |
template<typename scalar_t > | |
static bool | checkTilesLayout (BaseMatrix< scalar_t > const &A) |
Checks if existing tile instances in matrix have the same layout as the matrix. | |
template<typename scalar_t > | |
static void | printTiles_ (BaseMatrix< scalar_t > const &A, const char *name, int fields, const char *func, const char *file, int line) |
Prints map of all tiles with requested fields. | |
static void | printNumFreeMemBlocks (Memory const &m) |
Prints the number of free blocks for each device. | |
static void | checkHostMemoryLeaks (Memory const &m) |
Checks whether blocks were leaked or freed too many times, for host. | |
static void | checkDeviceMemoryLeaks (Memory const &m, int device) |
Checks whether blocks were leaked or freed too many times, for device. | |
template<typename scalar_t > | |
static void | printNumFreeMemBlocks (BaseMatrix< scalar_t > const &A) |
Slate::Debug - helper class used for debugging during development.
|
static |
Prints a summary of differences between matrices A and B.
Uses "." for small relative error, "#" for large relative error in an entry. For each tile, checks only the four corner 2x2 blocks, marked by letters:
[ a e - - i m ] output as: ----------- [ b f - - j n ] | a e i m | [ - - - - - - ] | b f j n | [ - - - - - - ] | c g k o | [ c g - - k o ] | d h l p | [ d h - - l p ] -----------
|
static |
Prints map of all tiles with requested fields.
The printTiles
macro adds the matrix name, function, file, and line. Example usage:
Debug::printTiles( A, Field_Kind | Field_MOSI )
For each tile (i, j), prints instances, first Host, then device 0, 1, etc. Each instance is a collection of letters as described below.
For all fields:
For Field_Kind:
For Field_MOSI:
For Field_Layout:
For Field_Buffer: