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
Add method to free all variables at once.
[simgrid.git]
/
src
/
kernel
/
lmm
/
maxmin.cpp
diff --git
a/src/kernel/lmm/maxmin.cpp
b/src/kernel/lmm/maxmin.cpp
index
06822fd
..
05bf4b7
100644
(file)
--- a/
src/kernel/lmm/maxmin.cpp
+++ b/
src/kernel/lmm/maxmin.cpp
@@
-224,6
+224,13
@@
void System::variable_free(Variable* var)
var_free(var);
}
+void System::variable_free_all()
+{
+ Variable* var;
+ while ((var = extract_variable()))
+ variable_free(var);
+}
+
void System::expand(Constraint* cnst, Variable* var, double consumption_weight)
{
modified_ = true;