- if (not strcmp(optim, "Full")) {
- updateMechanism_ = UM_FULL;
- selectiveUpdate_ = select;
- } else if (not strcmp(optim, "Lazy")) {
- updateMechanism_ = UM_LAZY;
- selectiveUpdate_ = true;
- xbt_assert(select || (xbt_cfg_is_default_value("cpu/maxmin-selective-update")),
- "Disabling selective update while using the lazy update mechanism is dumb!");
+ if (optim == "Full") {
+ setUpdateMechanism(UM_FULL);
+ } else if (optim == "Lazy") {
+ xbt_assert(select || xbt_cfg_is_default_value("cpu/maxmin-selective-update"),
+ "You cannot disable cpu selective update when using the lazy update mechanism");
+ select = true;
+ setUpdateMechanism(UM_LAZY);