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
Don't use xbt_os_time() when not needed
[simgrid.git]
/
src
/
simix
/
smx_environment.c
diff --git
a/src/simix/smx_environment.c
b/src/simix/smx_environment.c
index
7317c36
..
8f8e7d4
100644
(file)
--- a/
src/simix/smx_environment.c
+++ b/
src/simix/smx_environment.c
@@
-34,10
+34,11
@@
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(simix_environment, simix,
void SIMIX_create_environment(const char *file)
{
double start, end;
void SIMIX_create_environment(const char *file)
{
double start, end;
-
- start = xbt_os_time();
+ if(XBT_LOG_ISENABLED(simix_environment, xbt_log_priority_debug))
+
start = xbt_os_time();
parse_platform_file(file);
parse_platform_file(file);
- end = xbt_os_time();
+ if(XBT_LOG_ISENABLED(simix_environment, xbt_log_priority_debug))
+ end = xbt_os_time();
XBT_DEBUG("PARSE TIME: %g", (end - start));
}
XBT_DEBUG("PARSE TIME: %g", (end - start));
}