From a3c920498fb50d667fe8913fbabbfa8b60ab5c0f Mon Sep 17 00:00:00 2001 From: Arnaud Giersch Date: Thu, 5 Dec 2019 10:32:33 +0100 Subject: [PATCH] Reindent + minor stylistic issues. --- teshsuite/smpi/topo-cart-sub/topo-cart-sub.c | 193 ++++++++++--------- 1 file changed, 99 insertions(+), 94 deletions(-) diff --git a/teshsuite/smpi/topo-cart-sub/topo-cart-sub.c b/teshsuite/smpi/topo-cart-sub/topo-cart-sub.c index fc64b7dcbc..6521ab00e8 100644 --- a/teshsuite/smpi/topo-cart-sub/topo-cart-sub.c +++ b/teshsuite/smpi/topo-cart-sub/topo-cart-sub.c @@ -1,14 +1,14 @@ -/* Copyright (c) 2019. Jonathan Borne. -*/ /* Copyright (c) 2009-2019. The SimGrid Team. * All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ +/* Copyright (c) 2019. Jonathan Borne. */ + +#include #include #include -#include #define DIM 2 #define Q 2 @@ -17,101 +17,106 @@ #define N 3 /* Local matrices size N*N */ -int main(int argc, char **argv){ - /* Nb of nodes in the grid: - initialized by MPI_Comm_size according to commandline -np value */ - int nbNodes; - - /* Communicators */ - MPI_Comm gridComm, lineComm; - /* Current process ranks */ - int rank, gridSize, myGridRank, myLineRank, myColRank; - /* coords: used to get myLineRank and myColRank - initialized by MPI_Cart_coords - */ - int coords[DIM]; - /* dims: Integer array of size ndims specifying the number - of processes in each dimension. - if init value is 0 it is reset by MPI_Dims_create. - */ - int dims[DIM]; - for(int i=0; i