A
lgorithmique
N
umérique
D
istribuée
Public GIT Repository
projects
/
simgrid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
avoid warning by checking index in the right order
[simgrid.git]
/
src
/
smpi
/
colls
/
reduce_scatter-ompi.c
diff --git
a/src/smpi/colls/reduce_scatter-ompi.c
b/src/smpi/colls/reduce_scatter-ompi.c
index
bb01dee
..
1f3175b
100644
(file)
--- a/
src/smpi/colls/reduce_scatter-ompi.c
+++ b/
src/smpi/colls/reduce_scatter-ompi.c
@@
-1,4
+1,9
@@
-/* -*- Mode: C; c-basic-offset:4 ; indent-tabs-mode:nil -*- */
+/* Copyright (c) 2013-2014. 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) 2004-2005 The Trustees of Indiana University and Indiana
* University Research and Technology
/*
* Copyright (c) 2004-2005 The Trustees of Indiana University and Indiana
* University Research and Technology
@@
-12,11
+17,8
@@
* All rights reserved.
* Copyright (c) 2008 Sun Microsystems, Inc. All rights reserved.
* Copyright (c) 2009 University of Houston. All rights reserved.
* All rights reserved.
* Copyright (c) 2008 Sun Microsystems, Inc. All rights reserved.
* Copyright (c) 2009 University of Houston. All rights reserved.
- * $COPYRIGHT$
*
* Additional copyrights may follow
*
* Additional copyrights may follow
- *
- * $HEADER$
*/
#include "colls_private.h"
*/
#include "colls_private.h"
@@
-59,6
+61,8
@@
smpi_coll_tuned_reduce_scatter_ompi_basic_recursivehalving(void *sbuf,
size = smpi_comm_size(comm);
XBT_DEBUG("coll:tuned:reduce_scatter_ompi_basic_recursivehalving, rank %d", rank);
size = smpi_comm_size(comm);
XBT_DEBUG("coll:tuned:reduce_scatter_ompi_basic_recursivehalving, rank %d", rank);
+ if(!smpi_op_is_commute(op))
+ THROWF(arg_error,0, " reduce_scatter ompi_basic_recursivehalving can only be used for commutative operations! ");
/* Find displacements and the like */
disps = (int*) xbt_malloc(sizeof(int) * size);
/* Find displacements and the like */
disps = (int*) xbt_malloc(sizeof(int) * size);