more precision when printing timings

main
Bryce Allen 3 years ago
parent 124654b576
commit e5e3ca178a

@ -338,7 +338,7 @@ int main(int argc, char** argv)
d_dzdy_numeric = stencil2d_1d_5(d_z, stencil5) * scale; d_dzdy_numeric = stencil2d_1d_5(d_z, stencil5) * scale;
gt::synchronize(); gt::synchronize();
} }
printf("%d/%d exchange time %0.4f\n", world_rank, world_size, total_time / n_iter); printf("%d/%d exchange time %0.8f\n", world_rank, world_size, total_time / n_iter);
gt::copy(d_dzdy_numeric, h_dzdy_numeric); gt::copy(d_dzdy_numeric, h_dzdy_numeric);
// gt::synchronize(); // gt::synchronize();

@ -201,7 +201,7 @@ int main(int argc, char **argv) {
boundary_exchange(MPI_COMM_WORLD, world_size, world_rank, d_y, n_bnd); boundary_exchange(MPI_COMM_WORLD, world_size, world_rank, d_y, n_bnd);
clock_gettime(CLOCK_MONOTONIC, &end); clock_gettime(CLOCK_MONOTONIC, &end);
seconds = ((end.tv_sec - start.tv_sec) + (end.tv_nsec - start.tv_nsec) * 1.0e-9); seconds = ((end.tv_sec - start.tv_sec) + (end.tv_nsec - start.tv_nsec) * 1.0e-9);
printf("%d/%d exchange time %0.4f\n", world_rank, world_size, seconds); printf("%d/%d exchange time %0.8f\n", world_rank, world_size, seconds);
d_dydx_numeric = stencil1d_5(d_y, stencil5) * scale; d_dydx_numeric = stencil1d_5(d_y, stencil5) * scale;

Loading…
Cancel
Save