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
[trace] only one public function for extracting the graph of a platform
[simgrid.git]
/
src
/
instr
/
instr_interface.c
diff --git
a/src/instr/instr_interface.c
b/src/instr/instr_interface.c
index
4472a82
..
00ac548
100644
(file)
--- a/
src/instr/instr_interface.c
+++ b/
src/instr/instr_interface.c
@@
-162,19
+162,16
@@
static void instr_user_srcdst_variable(double time,
}
}
}
}
-
-xbt_graph_t TRACE_platform_graph (void)
-{
- if (!TRACE_is_enabled()) return NULL;
- return instr_routing_platform_graph ();
-}
-
-void TRACE_platform_graph_export_graphviz (xbt_graph_t g, const char *filename)
+int TRACE_platform_graph_export_graphviz (const char *filename)
{
{
+ /* returns 1 if successful, 0 otherwise */
+ if (!TRACE_is_enabled()) return 0;
+ xbt_graph_t g = instr_routing_platform_graph();
+ if (g == NULL) return 0;
instr_routing_platform_graph_export_graphviz (g, filename);
instr_routing_platform_graph_export_graphviz (g, filename);
+ return 1;
}
}
-
/*
* Derived functions that use instr_user_variable and TRACE_user_srcdst_variable.
* They were previously defined as pre-processors directives, but were transformed
/*
* Derived functions that use instr_user_variable and TRACE_user_srcdst_variable.
* They were previously defined as pre-processors directives, but were transformed