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
Fix bug in SMPI tracing, where messages were sometimes badly matched.
[simgrid.git]
/
src
/
smpi
/
instr_smpi.cpp
diff --git
a/src/smpi/instr_smpi.cpp
b/src/smpi/instr_smpi.cpp
index
ee21f42
..
19b4545
100644
(file)
--- a/
src/smpi/instr_smpi.cpp
+++ b/
src/smpi/instr_smpi.cpp
@@
-99,7
+99,7
@@
static char *TRACE_smpi_put_key(int src, int dst, char *key, int n)
{
//get the dynar for src#dst
char aux[INSTR_DEFAULT_STR_SIZE];
- snprintf(aux, INSTR_DEFAULT_STR_SIZE, "%d#%d", src, dst);
+ snprintf(aux, INSTR_DEFAULT_STR_SIZE, "
r
%d#%d", src, dst);
xbt_dynar_t d = static_cast<xbt_dynar_t>(xbt_dict_get_or_null(keys, aux));
if(xbt_dynar_is_empty(d) == 0){
@@
-110,6
+110,7
@@
static char *TRACE_smpi_put_key(int src, int dst, char *key, int n)
if (d == nullptr) {
d = xbt_dynar_new(sizeof(char *), &xbt_free_ref);
+ snprintf(aux, INSTR_DEFAULT_STR_SIZE, "s%d#%d", src, dst);
xbt_dict_set(keys, aux, d, nullptr);
}
@@
-128,7
+129,7
@@
static char *TRACE_smpi_put_key(int src, int dst, char *key, int n)
static char *TRACE_smpi_get_key(int src, int dst, char *key, int n)
{
char aux[INSTR_DEFAULT_STR_SIZE];
- snprintf(aux, INSTR_DEFAULT_STR_SIZE, "%d#%d", src, dst);
+ snprintf(aux, INSTR_DEFAULT_STR_SIZE, "
s
%d#%d", src, dst);
xbt_dynar_t d = static_cast<xbt_dynar_t>(xbt_dict_get_or_null(keys, aux));
// sometimes the receive may be posted before the send