PandA-2024.02
|
#include <inttypes.h>
#include <stdlib.h>
#include <mdpi/mdpi_user.h>
Go to the source code of this file.
Data Structures | |
union | vc_t |
Functions | |
char * | readfile (int fd) |
char * | find_section_start (char *s, int n) |
int | parse_string (char *s, char *arr, int n) |
int | parse_uint8_t_array (char *s, uint8_t *arr, int n) |
int | parse_uint16_t_array (char *s, uint16_t *arr, int n) |
int | parse_uint32_t_array (char *s, uint32_t *arr, int n) |
int | parse_uint64_t_array (char *s, uint64_t *arr, int n) |
int | parse_int8_t_array (char *s, int8_t *arr, int n) |
int | parse_int16_t_array (char *s, int16_t *arr, int n) |
int | parse_int32_t_array (char *s, int32_t *arr, int n) |
int | parse_int64_t_array (char *s, int64_t *arr, int n) |
int | parse_float_array (char *s, float *arr, int n) |
int | parse_double_array (char *s, double *arr, int n) |
int | write_string (int fd, char *arr, int n) |
int | write_uint8_t_array (int fd, uint8_t *arr, int n) |
int | write_uint16_t_array (int fd, uint16_t *arr, int n) |
int | write_uint32_t_array (int fd, uint32_t *arr, int n) |
int | write_uint64_t_array (int fd, uint64_t *arr, int n) |
int | write_int8_t_array (int fd, int8_t *arr, int n) |
int | write_int16_t_array (int fd, int16_t *arr, int n) |
int | write_int32_t_array (int fd, int32_t *arr, int n) |
int | write_int64_t_array (int fd, int64_t *arr, int n) |
int | write_float_array (int fd, float *arr, int n) |
int | write_double_array (int fd, double *arr, int n) |
int | write_section_header (int fd) |
void | run_benchmark (void *vargs) |
void | input_to_data (int fd, void *vdata) |
void | data_to_input (int fd, void *vdata) |
void | output_to_data (int fd, void *vdata) |
void | data_to_output (int fd, void *vdata) |
int | check_data (void *vdata) |
Variables | |
int | INPUT_SIZE |
#define __float_recast | ( | in | ) | __out_to_float(__float_to_in(in)) |
Definition at line 140 of file support.h.
Referenced by check_data().
#define __float_to_in | ( | in | ) | in |
Definition at line 130 of file support.h.
Referenced by run_benchmark().
#define __out_to_float | ( | out | ) | out |
Definition at line 131 of file support.h.
Referenced by run_benchmark().
#define __STAC_EXPANDED | ( | f_pfx, | |
t, | |||
f_sfx | |||
) | f_pfx##t##f_sfx |
#define IEEE64_SPEC_ARGS IEEE64_EXP_BITS, IEEE64_FRAC_BITS, IEEE64_EXP_BIAS, IEEE_RND, IEEE_EXC, IEEE_ONE, IEEE_SUBNORM, IEEE_SIGN |
#define IEEE_EXC FLOAT_EXC_STD |
#define IEEE_RND FLOAT_RND_NEVN |
#define MAX_ULP 1.0l |
Definition at line 60 of file support.h.
Referenced by check_data().
#define STAC | ( | f_pfx, | |
t, | |||
f_sfx | |||
) | __STAC_EXPANDED(f_pfx, t, f_sfx) |
#define TEST_EXP_BIAS IEEE64_EXP_BIAS |
#define TEST_EXP_BITS IEEE64_EXP_BITS |
#define TEST_FRAC_BITS IEEE64_FRAC_BITS |
#define TEST_SPEC_ARGS TEST_EXP_BITS, TEST_FRAC_BITS, TEST_EXP_BIAS, TEST_RND, TEST_EXC, TEST_ONE, TEST_SUBNORM, TEST_SIGN |
int check_data | ( | void * | vdata | ) |
Definition at line 92 of file local_support.c.
References __float_recast, bench_args_t::a, bench_args_t::b, bench_args_t::c, vc_t::d, MAX_ULP, TESTS_COUNT, and vc_t::u.
void data_to_input | ( | int | fd, |
void * | vdata | ||
) |
Definition at line 34 of file local_support.c.
References bench_args_t::a, ALEN, bench_args_t::b, bench_args_t::biases1, bench_args_t::biases2, bench_args_t::biases3, BLEN, blockSide, bench_args_t::buf, bench_args_t::C, col_size, bench_args_t::cols, densityFactor, node_t_struct::edge_begin, node_t_struct::edge_end, bench_args_t::edges, bench_args_t::emission, f_size, FFT_SIZE, bench_args_t::filter, bench_args_t::img, bench_args_t::img_twid, bench_args_t::init, bench_args_t::input, input_dimension, bench_args_t::k, L, bench_args_t::m1, bench_args_t::m2, maxNeighbors, N, N_EDGES, N_NODES, N_OBS, bench_args_t::n_points, N_STATES, N_TOKENS, nAtoms, bench_args_t::NL, NNZ, bench_args_t::nodes, nodes, nodes_per_layer, bench_args_t::nzval, bench_args_t::obs, bench_args_t::orig, bench_args_t::pattern, PATTERN_SIZE, bench_args_t::position, bench_args_t::position_x, bench_args_t::position_y, bench_args_t::position_z, possible_outputs, bench_args_t::real, bench_args_t::real_twid, row_size, bench_args_t::rowDelimiters, bench_args_t::seqA, bench_args_t::seqB, SIZE, STAC, bench_args_t::starting_node, STRING_SIZE, TESTS_COUNT, bench_args_t::training_data, training_sets, bench_args_t::training_targets, bench_args_t::transition, TYPE, bench_args_t::val, bench_args_t::vec, bench_args_t::weights1, bench_args_t::weights2, bench_args_t::weights3, bench_args_t::work_x, bench_args_t::work_y, write_double_array(), write_int32_t_array(), write_section_header(), write_string(), write_uint64_t_array(), and write_uint8_t_array().
Referenced by main().
void data_to_output | ( | int | fd, |
void * | vdata | ||
) |
Definition at line 63 of file local_support.c.
References bench_args_t::a, ALEN, bench_args_t::alignedA, bench_args_t::alignedB, bench_args_t::biases1, bench_args_t::biases2, bench_args_t::biases3, BLEN, blockSide, bench_args_t::buf, bench_args_t::c, col_size, densityFactor, FFT_SIZE, bench_args_t::force, bench_args_t::force_x, bench_args_t::force_y, bench_args_t::force_z, bench_args_t::img, input_dimension, bench_args_t::level_counts, N, N_LEVELS, bench_args_t::n_matches, N_OBS, nAtoms, nodes_per_layer, bench_args_t::out, bench_args_t::path, possible_outputs, bench_args_t::prod, bench_args_t::real, row_size, SIZE, bench_args_t::sol, STAC, TESTS_COUNT, TYPE, bench_args_t::weights1, bench_args_t::weights2, bench_args_t::weights3, bench_args_t::work_x, bench_args_t::work_y, write_double_array(), write_int32_t_array(), write_section_header(), write_string(), write_uint64_t_array(), and write_uint8_t_array().
Referenced by main().
char* find_section_start | ( | char * | s, |
int | n | ||
) |
Definition at line 56 of file support.c.
Referenced by generate_test_TYPE_array(), input_to_data(), and output_to_data().
void input_to_data | ( | int | fd, |
void * | vdata | ||
) |
Definition at line 18 of file local_support.c.
References bench_args_t::a, ALEN, bench_args_t::b, bench_args_t::biases1, bench_args_t::biases2, bench_args_t::biases3, BLEN, blockSide, bench_args_t::buf, bench_args_t::C, col_size, bench_args_t::cols, densityFactor, node_t_struct::edge_begin, node_t_struct::edge_end, bench_args_t::edges, bench_args_t::emission, f_size, FFT_SIZE, bench_args_t::filter, find_section_start(), bench_args_t::img, bench_args_t::img_twid, bench_args_t::init, bench_args_t::input, input_dimension, bench_args_t::k, L, bench_args_t::level, bench_args_t::m1, bench_args_t::m2, MAX_LEVEL, maxNeighbors, N, N_EDGES, N_NODES, N_OBS, bench_args_t::n_points, N_STATES, N_TOKENS, nAtoms, bench_args_t::NL, NNZ, bench_args_t::nodes, nodes, nodes_per_layer, bench_args_t::nzval, bench_args_t::obs, bench_args_t::orig, parse_double_array(), parse_int32_t_array(), parse_string(), parse_uint64_t_array(), parse_uint8_t_array(), bench_args_t::pattern, PATTERN_SIZE, bench_args_t::position, bench_args_t::position_x, bench_args_t::position_y, bench_args_t::position_z, possible_outputs, readfile(), bench_args_t::real, bench_args_t::real_twid, row_size, bench_args_t::rowDelimiters, bench_args_t::seqA, bench_args_t::seqB, SIZE, STAC, bench_args_t::starting_node, STRING_SIZE, TESTS_COUNT, bench_args_t::training_data, training_sets, bench_args_t::training_targets, bench_args_t::transition, TYPE, bench_args_t::val, bench_args_t::vec, bench_args_t::weights1, bench_args_t::weights2, bench_args_t::weights3, bench_args_t::work_x, and bench_args_t::work_y.
Referenced by main().
void output_to_data | ( | int | fd, |
void * | vdata | ||
) |
Definition at line 49 of file local_support.c.
References bench_args_t::a, ALEN, bench_args_t::alignedA, bench_args_t::alignedB, bench_args_t::biases1, bench_args_t::biases2, bench_args_t::biases3, BLEN, blockSide, bench_args_t::buf, bench_args_t::c, col_size, densityFactor, FFT_SIZE, find_section_start(), bench_args_t::force, bench_args_t::force_x, bench_args_t::force_y, bench_args_t::force_z, bench_args_t::img, input_dimension, bench_args_t::level_counts, N, N_LEVELS, bench_args_t::n_matches, N_OBS, nAtoms, nodes_per_layer, bench_args_t::out, parse_double_array(), parse_int32_t_array(), parse_string(), parse_uint64_t_array(), parse_uint8_t_array(), bench_args_t::path, possible_outputs, bench_args_t::prod, readfile(), bench_args_t::real, row_size, SIZE, bench_args_t::sol, STAC, TESTS_COUNT, TYPE, bench_args_t::weights1, bench_args_t::weights2, bench_args_t::weights3, bench_args_t::work_x, and bench_args_t::work_y.
Referenced by main().
int parse_double_array | ( | char * | s, |
double * | arr, | ||
int | n | ||
) |
int parse_float_array | ( | char * | s, |
float * | arr, | ||
int | n | ||
) |
int parse_int16_t_array | ( | char * | s, |
int16_t * | arr, | ||
int | n | ||
) |
int parse_int32_t_array | ( | char * | s, |
int32_t * | arr, | ||
int | n | ||
) |
int parse_int64_t_array | ( | char * | s, |
int64_t * | arr, | ||
int | n | ||
) |
int parse_int8_t_array | ( | char * | s, |
int8_t * | arr, | ||
int | n | ||
) |
int parse_string | ( | char * | s, |
char * | arr, | ||
int | n | ||
) |
Definition at line 77 of file support.c.
Referenced by input_to_data(), output_to_data(), and test_strings().
int parse_uint16_t_array | ( | char * | s, |
uint16_t * | arr, | ||
int | n | ||
) |
int parse_uint32_t_array | ( | char * | s, |
uint32_t * | arr, | ||
int | n | ||
) |
int parse_uint64_t_array | ( | char * | s, |
uint64_t * | arr, | ||
int | n | ||
) |
int parse_uint8_t_array | ( | char * | s, |
uint8_t * | arr, | ||
int | n | ||
) |
char* readfile | ( | int | fd | ) |
Definition at line 34 of file support.c.
References read().
Referenced by generate_test_TYPE_array(), input_to_data(), output_to_data(), and test_strings().
void run_benchmark | ( | void * | vargs | ) |
Definition at line 6 of file local_support.c.
References __float_to_in, __out_to_float, bench_args_t::a, aes256_encrypt_ecb(), bench_args_t::alignedA, bench_args_t::alignedB, test_panda::args, bench_args_t::b, backprop(), bbgemm(), bfs(), bench_args_t::biases1, bench_args_t::biases2, bench_args_t::biases3, bench_args_t::bucket, bench_args_t::buf, bench_args_t::c, bench_args_t::C, bench_args_t::cols, bench_args_t::ctx, vc_t::d, double_prec_addition(), double_prec_division(), double_prec_exp(), double_prec_multiplication(), double_prec_pow(), double_prec_sqrt(), double_prec_subtraction(), bench_args_t::edges, ellpack(), bench_args_t::emission, fft(), fft1D_512(), bench_args_t::filter, bench_args_t::force, bench_args_t::force_x, bench_args_t::force_y, bench_args_t::force_z, gemm(), bench_args_t::img, bench_args_t::img_twid, bench_args_t::init, bench_args_t::input, bench_args_t::k, kmp(), bench_args_t::kmpNext, bench_args_t::level, bench_args_t::level_counts, bench_args_t::M, bench_args_t::m1, bench_args_t::m2, md(), md_kernel(), ms_mergesort(), bench_args_t::n_matches, bench_args_t::n_points, needwun(), bench_args_t::NL, bench_args_t::nodes, bench_args_t::nzval, bench_args_t::obs, bench_args_t::orig, bench_args_t::out, bench_args_t::path, bench_args_t::pattern, bench_args_t::position, bench_args_t::position_x, bench_args_t::position_y, bench_args_t::position_z, bench_args_t::prod, bench_args_t::ptr, bench_args_t::real, bench_args_t::real_twid, bench_args_t::rowDelimiters, bench_args_t::seqA, bench_args_t::seqB, bench_args_t::sol, spmv(), ss_sort(), bench_args_t::starting_node, stencil(), stencil3d(), bench_args_t::sum, TESTS_COUNT, bench_args_t::training_data, bench_args_t::training_targets, bench_args_t::transition, vc_t::u, bench_args_t::val, bench_args_t::vec, viterbi(), bench_args_t::weights1, bench_args_t::weights2, bench_args_t::weights3, bench_args_t::work_x, and bench_args_t::work_y.
Referenced by main().
int write_double_array | ( | int | fd, |
double * | arr, | ||
int | n | ||
) |
int write_float_array | ( | int | fd, |
float * | arr, | ||
int | n | ||
) |
int write_int16_t_array | ( | int | fd, |
int16_t * | arr, | ||
int | n | ||
) |
int write_int32_t_array | ( | int | fd, |
int32_t * | arr, | ||
int | n | ||
) |
int write_int64_t_array | ( | int | fd, |
int64_t * | arr, | ||
int | n | ||
) |
int write_int8_t_array | ( | int | fd, |
int8_t * | arr, | ||
int | n | ||
) |
int write_section_header | ( | int | fd | ) |
int write_string | ( | int | fd, |
char * | arr, | ||
int | n | ||
) |
int write_uint16_t_array | ( | int | fd, |
uint16_t * | arr, | ||
int | n | ||
) |
int write_uint32_t_array | ( | int | fd, |
uint32_t * | arr, | ||
int | n | ||
) |
int write_uint64_t_array | ( | int | fd, |
uint64_t * | arr, | ||
int | n | ||
) |
int write_uint8_t_array | ( | int | fd, |
uint8_t * | arr, | ||
int | n | ||
) |
int INPUT_SIZE |
Definition at line 4 of file local_support.c.
Referenced by main().