Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Restore warning for unit-less values.
[simgrid.git] / src / smpi / internals / smpi_utils.cpp
index ddde90d..ae8df44 100644 (file)
@@ -8,6 +8,7 @@
 #include "xbt/log.h"
 #include "xbt/sysdep.h"
 #include <boost/tokenizer.hpp>
+#include "src/surf/xml/platf_private.hpp"
 
 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(smpi_utils, smpi, "Logging specific to SMPI (utils)");
 
@@ -48,7 +49,7 @@ std::vector<s_smpi_factor_t> parse_factor(const std::string& smpi_coef_string)
         }
       } else {
         try {
-          fact.values.push_back(std::stod(*factor_iter));
+          fact.values.push_back(surf_parse_get_time((*factor_iter).c_str(), "smpi factor", ""));
         } catch (std::invalid_argument& ia) {
           throw std::invalid_argument(std::string("Invalid factor value ") + std::to_string(iteration) + " in chunk " +
                                       std::to_string(smpi_factor.size() + 1) + ": " + *factor_iter);