From 41f201dce67effdcae5bf02d142e5cbe113b1d3a Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Tue, 27 Dec 2011 00:21:33 +0100 Subject: [PATCH] more verbose debug messages --- examples/smpi/dsend.c | 4 +++- src/smpi/smpi_bench.c | 3 +++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/examples/smpi/dsend.c b/examples/smpi/dsend.c index 511cf32a04..f7bc825cb3 100644 --- a/examples/smpi/dsend.c +++ b/examples/smpi/dsend.c @@ -12,19 +12,21 @@ int main(int argc, char *argv[]) { int rank; int data=11; + MPI_Init(&argc, &argv); MPI_Comm_rank(MPI_COMM_WORLD, &rank); if (rank==1) { data=22; MPI_Send(&data,1,MPI_INT,(rank+1)%2,666,MPI_COMM_WORLD); +// smpi_sleep(1000); } else { MPI_Recv(&data,1,MPI_INT,-1,666,MPI_COMM_WORLD,NULL); if (data !=22) { printf("rank %d: Damn, data does not match (got %d)\n",rank, data); } } - + printf("rank %d: data exchanged\n", rank); MPI_Finalize(); return 0; diff --git a/src/smpi/smpi_bench.c b/src/smpi/smpi_bench.c index ca1d8666a9..d69573014f 100644 --- a/src/smpi/smpi_bench.c +++ b/src/smpi/smpi_bench.c @@ -148,6 +148,9 @@ static void smpi_execute(double duration) smpi_execute_flops(duration * xbt_cfg_get_double(_surf_cfg_set, "smpi/running_power")); + } else { + XBT_DEBUG("Real computation took %f while threshold is set to %f; ignore it", + duration, xbt_cfg_get_double(_surf_cfg_set, "smpi/cpu_threshold")); } } -- 2.20.1