int create_gate_tau (void *msg) { ssize_t rc; ZERO_PADDING(msg, tag); ZERO_PADDING(msg, start); rc = pread(Msg_fd, msg, sizeof(msg_s), MSG_CREATE_GATE); RTN(rc); }
int write_data_tau (ki_t key, unint length, const void *start, unint offset) { msg_s m; ssize_t rc; ZERO_PADDING( &m, start); m.q.q_start = (void *)start; m.q.q_length = length; m.q.q_offset = offset; rc = pread(Msg_fd, &m, sizeof(m), MAKE_ARG(key, MSG_WRITE_DATA)); RTN(rc); }
int putdata_tau (ki_t key, void *msg, unint length, const void *start) { msg_s *m = msg; ssize_t rc; ZERO_PADDING(msg, start); m->q.q_type = READ_DATA; m->q.q_start = (void *)start; m->q.q_length = length; rc = pread(Msg_fd, msg, sizeof(msg_s), MAKE_ARG(key, MSG_CALL)); RTN(rc); }
int read_data_tau (ki_t key, unint length, void *start, unint offset) { msg_s m; ssize_t rc; ZERO_PADDING( &m, start); m.q.q_start = start; m.q.q_length = length; m.q.q_offset = offset; rc = pread(Msg_fd, &m, sizeof(m), MAKE_ARG(key, MSG_READ_DATA)); RTN(rc); }
double benchmark2() { double t0=omp_get_wtime(); for(int test=0; test<num_test; test++) { #pragma omp parallel for for(int i=0;i<num_data; i+=NB) { ZERO_PADDING(&(data1[i]), &(result[i]), n_bit); } } double t1= omp_get_wtime()-t0; TearDown(); return t1/num_test; }