![]() |
(git:ec11232)
|
#include "dbm_multiply_cpu.h"#include "dbm_hyperparams.h"#include <assert.h>#include <stddef.h>#include <string.h>Go to the source code of this file.
Functions | |
| void | dgemm_ (const char *transa, const char *transb, const int *m, const int *n, const int *k, const double *alpha, const double *a, const int *lda, const double *b, const int *ldb, const double *beta, double *c, const int *ldc) |
| Prototype for BLAS dgemm. | |
| static void | dbm_dgemm (const char transa, const char transb, const int m, const int n, const int k, const double alpha, const double *a, const int lda, const double *b, const int ldb, const double beta, double *c, const int ldc) |
| Private convenient wrapper to hide Fortran nature of dgemm_. | |
| static unsigned int | hash (const dbm_task_t task) |
| Private hash function based on Szudzik's elegant pairing. Using unsigned int to return a positive number even after overflow. https://en.wikipedia.org/wiki/Pairing_function#Other_pairing_functions https://stackoverflow.com/a/13871379 http://szudzik.com/ElegantPairing.pdf. | |
| void | dbm_multiply_cpu_process_batch (int ntasks, const dbm_task_t batch[ntasks], double alpha, const dbm_pack_t *pack_a, const dbm_pack_t *pack_b, dbm_shard_t *shard_c, int options) |
| Internal routine for executing the tasks in given batch on the CPU. | |
| void dgemm_ | ( | const char * | transa, |
| const char * | transb, | ||
| const int * | m, | ||
| const int * | n, | ||
| const int * | k, | ||
| const double * | alpha, | ||
| const double * | a, | ||
| const int * | lda, | ||
| const double * | b, | ||
| const int * | ldb, | ||
| const double * | beta, | ||
| double * | c, | ||
| const int * | ldc | ||
| ) |
Prototype for BLAS dgemm.
|
inlinestatic |
Private convenient wrapper to hide Fortran nature of dgemm_.
Definition at line 38 of file dbm_multiply_cpu.c.
|
inlinestatic |
Private hash function based on Szudzik's elegant pairing. Using unsigned int to return a positive number even after overflow. https://en.wikipedia.org/wiki/Pairing_function#Other_pairing_functions https://stackoverflow.com/a/13871379 http://szudzik.com/ElegantPairing.pdf.
Definition at line 56 of file dbm_multiply_cpu.c.
| void dbm_multiply_cpu_process_batch | ( | int | ntasks, |
| const dbm_task_t | batch[ntasks], | ||
| double | alpha, | ||
| const dbm_pack_t * | pack_a, | ||
| const dbm_pack_t * | pack_b, | ||
| dbm_shard_t * | shard_c, | ||
| int | options | ||
| ) |
Internal routine for executing the tasks in given batch on the CPU.
Definition at line 67 of file dbm_multiply_cpu.c.