From 0f5828869a4c6d79018e8eca27a10d0fe51979e5 Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Sat, 24 Mar 2018 21:35:42 +0100 Subject: [PATCH] Kill typedef lmm_system_t --- include/simgrid/forward.h | 1 - include/simgrid/kernel/resource/Model.hpp | 4 ++-- include/simgrid/kernel/routing/ClusterZone.hpp | 2 +- include/simgrid/plugins/live_migration.h | 3 +-- include/simgrid/plugins/load.h | 3 +-- src/instr/instr_paje_events.cpp | 3 +-- src/kernel/lmm/fair_bottleneck.cpp | 5 ++--- src/kernel/lmm/lagrange.cpp | 6 +++--- src/kernel/lmm/maxmin.cpp | 6 +++--- src/kernel/lmm/maxmin.hpp | 8 ++++---- src/msg/msg_legacy.cpp | 2 +- src/plugins/vm/VirtualMachineImpl.cpp | 5 ++--- src/plugins/vm/s4u_VirtualMachine.cpp | 2 +- src/simgrid/sg_config.cpp | 2 +- src/smpi/bindings/smpi_mpi.cpp | 2 +- src/surf/StorageImpl.cpp | 4 ++-- src/surf/StorageImpl.hpp | 7 +++---- src/surf/network_cm02.cpp | 4 ++-- src/surf/network_cm02.hpp | 4 ++-- src/surf/network_interface.hpp | 2 +- src/surf/ptask_L07.cpp | 4 ++-- src/surf/ptask_L07.hpp | 4 ++-- src/surf/storage_n11.cpp | 4 ++-- src/surf/storage_n11.hpp | 2 +- src/surf/trace_mgr.cpp | 3 +-- src/surf/xml/surfxml_parseplatf.cpp | 3 +-- teshsuite/surf/lmm_usage/lmm_usage.cpp | 9 ++++----- teshsuite/surf/maxmin_bench/maxmin_bench.cpp | 2 +- 28 files changed, 48 insertions(+), 58 deletions(-) diff --git a/include/simgrid/forward.h b/include/simgrid/forward.h index 7851a6022e..8f71d15f34 100644 --- a/include/simgrid/forward.h +++ b/include/simgrid/forward.h @@ -102,7 +102,6 @@ typedef simgrid::surf::StorageImpl* surf_storage_t; typedef simgrid::kernel::lmm::Element* lmm_element_t; typedef const simgrid::kernel::lmm::Element* const_lmm_element_t; typedef simgrid::kernel::lmm::ConstraintLight* lmm_constraint_light_t; -typedef simgrid::kernel::lmm::System* lmm_system_t; #else diff --git a/include/simgrid/kernel/resource/Model.hpp b/include/simgrid/kernel/resource/Model.hpp index a67f1fecdb..5de68af026 100644 --- a/include/simgrid/kernel/resource/Model.hpp +++ b/include/simgrid/kernel/resource/Model.hpp @@ -50,7 +50,7 @@ public: ActionLmmListPtr getModifiedSet() const; /** @brief Get the maxmin system of the current Model */ - lmm_system_t getMaxminSystem() const { return maxmin_system_; } + lmm::System* getMaxminSystem() const { return maxmin_system_; } /** * @brief Get the update mechanism of the current Model @@ -94,7 +94,7 @@ public: virtual bool nextOccuringEventIsIdempotent() { return true; } protected: - lmm_system_t maxmin_system_ = nullptr; + lmm::System* maxmin_system_ = nullptr; private: e_UM_t update_mechanism_ = UM_UNDEFINED; diff --git a/include/simgrid/kernel/routing/ClusterZone.hpp b/include/simgrid/kernel/routing/ClusterZone.hpp index f07b371ff6..f44aba36b0 100644 --- a/include/simgrid/kernel/routing/ClusterZone.hpp +++ b/include/simgrid/kernel/routing/ClusterZone.hpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2013-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2013-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/include/simgrid/plugins/live_migration.h b/include/simgrid/plugins/live_migration.h index a75cac28be..bfdf1f843b 100644 --- a/include/simgrid/plugins/live_migration.h +++ b/include/simgrid/plugins/live_migration.h @@ -1,5 +1,4 @@ -/* Copyright (c) 2017-2018. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2017-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/include/simgrid/plugins/load.h b/include/simgrid/plugins/load.h index d6d09b9c35..734752aa2a 100644 --- a/include/simgrid/plugins/load.h +++ b/include/simgrid/plugins/load.h @@ -1,5 +1,4 @@ -/* Copyright (c) 2017-2018. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2017-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/instr/instr_paje_events.cpp b/src/instr/instr_paje_events.cpp index 49c8d77ee6..4037df7975 100644 --- a/src/instr/instr_paje_events.cpp +++ b/src/instr/instr_paje_events.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2012-2017. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2012-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/kernel/lmm/fair_bottleneck.cpp b/src/kernel/lmm/fair_bottleneck.cpp index 83bd007663..cd43352447 100644 --- a/src/kernel/lmm/fair_bottleneck.cpp +++ b/src/kernel/lmm/fair_bottleneck.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2007-2011, 2013-2017. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2007-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -18,7 +17,7 @@ XBT_LOG_EXTERNAL_DEFAULT_CATEGORY(surf_maxmin); #define SHOW_EXPR_D(expr) XBT_DEBUG(#expr " = %d", expr); #define SHOW_EXPR_P(expr) XBT_DEBUG(#expr " = %p", expr); -void simgrid::kernel::lmm::bottleneck_solve(lmm_system_t sys) +void simgrid::kernel::lmm::bottleneck_solve(lmm::System* sys) { if (not sys->modified) return; diff --git a/src/kernel/lmm/lagrange.cpp b/src/kernel/lmm/lagrange.cpp index d08d85c9b9..7d2afe0e98 100644 --- a/src/kernel/lmm/lagrange.cpp +++ b/src/kernel/lmm/lagrange.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2007-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2007-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -37,7 +37,7 @@ double (*func_fpi_def)(const Variable&, double); * Local prototypes to implement the Lagrangian optimization with optimal step, also called dichotomy. */ // solves the proportional fairness using a Lagrangian optimization with dichotomy step -void lagrange_solve(lmm_system_t sys); +void lagrange_solve(kernel::lmm::System* sys); // computes the value of the dichotomy using a initial values, init, with a specific variable or constraint static double dichotomy(double init, double diff(double, const Constraint&), const Constraint& cnst, double min_error); // computes the value of the differential of constraint cnst applied to lambda @@ -137,7 +137,7 @@ static double dual_objective(const VarList& var_list, const CnstList& cnst_list) return obj; } -void lagrange_solve(lmm_system_t sys) +void lagrange_solve(kernel::lmm::System* sys) { /* Lagrange Variables. */ int max_iterations = 100; diff --git a/src/kernel/lmm/maxmin.cpp b/src/kernel/lmm/maxmin.cpp index 879813e0ec..c3b1668b0b 100644 --- a/src/kernel/lmm/maxmin.cpp +++ b/src/kernel/lmm/maxmin.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2004-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2004-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -412,7 +412,7 @@ static inline void saturated_constraints_update(double usage, int cnst_light_num } static inline void saturated_variable_set_update(ConstraintLight* cnst_light_tab, - const dyn_light_t& saturated_constraints, lmm_system_t sys) + const dyn_light_t& saturated_constraints, System* sys) { /* Add active variables (i.e. variables that need to be set) from the set of constraints to saturate * (cnst_light_tab)*/ @@ -690,7 +690,7 @@ template void System::solve(CnstList& cnst_list) delete[] cnst_light_tab; } -void lmm_solve(lmm_system_t sys) +void lmm_solve(System* sys) { sys->solve(); } diff --git a/src/kernel/lmm/maxmin.hpp b/src/kernel/lmm/maxmin.hpp index f294e72252..65a2cd186e 100644 --- a/src/kernel/lmm/maxmin.hpp +++ b/src/kernel/lmm/maxmin.hpp @@ -139,10 +139,10 @@ namespace lmm { * @brief Solve the lmm system * @param sys The lmm system to solve */ -XBT_PUBLIC void lmm_solve(lmm_system_t sys); +XBT_PUBLIC void lmm_solve(lmm::System* sys); -XBT_PUBLIC void lagrange_solve(lmm_system_t sys); -XBT_PUBLIC void bottleneck_solve(lmm_system_t sys); +XBT_PUBLIC void lagrange_solve(lmm::System* sys); +XBT_PUBLIC void bottleneck_solve(lmm::System* sys); /** Default functions associated to the chosen protocol. When using the lagrangian approach. */ @@ -603,7 +603,7 @@ public: simgrid::kernel::resource::ActionLmmListPtr modified_set_ = nullptr; - void (*solve_fun)(lmm_system_t self); + void (*solve_fun)(lmm::System* self); private: bool selective_update_active; /* flag to update partially the system only selecting changed portions */ diff --git a/src/msg/msg_legacy.cpp b/src/msg/msg_legacy.cpp index 0e9e819718..849f1517c5 100644 --- a/src/msg/msg_legacy.cpp +++ b/src/msg/msg_legacy.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2004-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2004-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/plugins/vm/VirtualMachineImpl.cpp b/src/plugins/vm/VirtualMachineImpl.cpp index f4c0dd642c..69070f01d2 100644 --- a/src/plugins/vm/VirtualMachineImpl.cpp +++ b/src/plugins/vm/VirtualMachineImpl.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2013-2017. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2013-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -98,7 +97,7 @@ double VMModel::nextOccuringEvent(double now) XBT_DEBUG("assign %f to vm %s @ pm %s", solved_value, ws_vm->getCname(), ws_vm->getPm()->getCname()); xbt_assert(cpu->model() == surf_cpu_model_vm); - lmm_system_t vcpu_system = cpu->model()->getMaxminSystem(); + kernel::lmm::System* vcpu_system = cpu->model()->getMaxminSystem(); vcpu_system->update_constraint_bound(cpu->constraint(), virt_overhead * solved_value); } diff --git a/src/plugins/vm/s4u_VirtualMachine.cpp b/src/plugins/vm/s4u_VirtualMachine.cpp index e5b209e456..5dfaf837c6 100644 --- a/src/plugins/vm/s4u_VirtualMachine.cpp +++ b/src/plugins/vm/s4u_VirtualMachine.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2015-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2015-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/simgrid/sg_config.cpp b/src/simgrid/sg_config.cpp index 19e7b14506..cff2376d4f 100644 --- a/src/simgrid/sg_config.cpp +++ b/src/simgrid/sg_config.cpp @@ -1,4 +1,4 @@ -/* Copyright (c) 2009-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2009-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/smpi/bindings/smpi_mpi.cpp b/src/smpi/bindings/smpi_mpi.cpp index 483f17dce3..09ed6729c1 100644 --- a/src/smpi/bindings/smpi_mpi.cpp +++ b/src/smpi/bindings/smpi_mpi.cpp @@ -1,4 +1,4 @@ -/* Copyright ,(c) 2007-2017. The SimGrid Team. All rights reserved. */ +/* Copyright (c) 2007-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license ,(GNU LGPL) which comes with this package. */ diff --git a/src/surf/StorageImpl.cpp b/src/surf/StorageImpl.cpp index 56ad247a9a..1cdd353b3d 100644 --- a/src/surf/StorageImpl.cpp +++ b/src/surf/StorageImpl.cpp @@ -44,8 +44,8 @@ StorageModel::~StorageModel() * Resource * ************/ -StorageImpl::StorageImpl(kernel::resource::Model* model, std::string name, lmm_system_t maxminSystem, double bread, - double bwrite, std::string type_id, std::string content_name, sg_size_t size, +StorageImpl::StorageImpl(kernel::resource::Model* model, std::string name, kernel::lmm::System* maxminSystem, + double bread, double bwrite, std::string type_id, std::string content_name, sg_size_t size, std::string attach) : Resource(model, name.c_str(), maxminSystem->constraint_new(this, std::max(bread, bwrite))) , piface_(name, this) diff --git a/src/surf/StorageImpl.hpp b/src/surf/StorageImpl.hpp index 1f3d1702a6..5027331d51 100644 --- a/src/surf/StorageImpl.hpp +++ b/src/surf/StorageImpl.hpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2004-2018. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2004-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -86,8 +85,8 @@ public: class StorageImpl : public kernel::resource::Resource, public PropertyHolder { public: /** @brief Storage constructor */ - StorageImpl(kernel::resource::Model* model, std::string name, lmm_system_t maxminSystem, double bread, double bwrite, - std::string type_id, std::string content_name, sg_size_t size, std::string attach); + StorageImpl(kernel::resource::Model* model, std::string name, kernel::lmm::System* maxminSystem, double bread, + double bwrite, std::string type_id, std::string content_name, sg_size_t size, std::string attach); ~StorageImpl() override; diff --git a/src/surf/network_cm02.cpp b/src/surf/network_cm02.cpp index b84a7a0275..c5d3c9dc00 100644 --- a/src/surf/network_cm02.cpp +++ b/src/surf/network_cm02.cpp @@ -158,7 +158,7 @@ NetworkCm02Model::NetworkCm02Model() maxmin_system_->modified_set_ = new kernel::resource::ActionLmmList(); } -NetworkCm02Model::NetworkCm02Model(void (*specificSolveFun)(lmm_system_t self)) : NetworkCm02Model() +NetworkCm02Model::NetworkCm02Model(void (*specificSolveFun)(kernel::lmm::System* self)) : NetworkCm02Model() { maxmin_system_->solve_fun = specificSolveFun; } @@ -349,7 +349,7 @@ kernel::resource::Action* NetworkCm02Model::communicate(s4u::Host* src, s4u::Hos * Resource * ************/ NetworkCm02Link::NetworkCm02Link(NetworkCm02Model* model, const std::string& name, double bandwidth, double latency, - e_surf_link_sharing_policy_t policy, lmm_system_t system) + e_surf_link_sharing_policy_t policy, kernel::lmm::System* system) : LinkImpl(model, name, system->constraint_new(this, sg_bandwidth_factor * bandwidth)) { bandwidth_.scale = 1.0; diff --git a/src/surf/network_cm02.hpp b/src/surf/network_cm02.hpp index 07486aa6f9..f9904fd58d 100644 --- a/src/surf/network_cm02.hpp +++ b/src/surf/network_cm02.hpp @@ -36,7 +36,7 @@ namespace surf { class NetworkCm02Model : public NetworkModel { public: NetworkCm02Model(); - explicit NetworkCm02Model(void (*solve_fun)(lmm_system_t self)); + explicit NetworkCm02Model(void (*solve_fun)(kernel::lmm::System* self)); virtual ~NetworkCm02Model() = default; LinkImpl* createLink(const std::string& name, double bandwidth, double latency, e_surf_link_sharing_policy_t policy) override; @@ -52,7 +52,7 @@ public: class NetworkCm02Link : public LinkImpl { public: NetworkCm02Link(NetworkCm02Model* model, const std::string& name, double bandwidth, double latency, - e_surf_link_sharing_policy_t policy, lmm_system_t system); + e_surf_link_sharing_policy_t policy, kernel::lmm::System* system); virtual ~NetworkCm02Link() = default; void apply_event(tmgr_trace_event_t event, double value) override; void setBandwidth(double value) override; diff --git a/src/surf/network_interface.hpp b/src/surf/network_interface.hpp index 373bc7a9d3..e1e88ee1c0 100644 --- a/src/surf/network_interface.hpp +++ b/src/surf/network_interface.hpp @@ -68,7 +68,7 @@ public: * * @param system The lmm_system_t to solve */ - void (*f_networkSolve)(lmm_system_t) = simgrid::kernel::lmm::lmm_solve; + void (*f_networkSolve)(kernel::lmm::System*) = kernel::lmm::lmm_solve; /** * @brief Get the right multiplicative factor for the latency. diff --git a/src/surf/ptask_L07.cpp b/src/surf/ptask_L07.cpp index 00be08649f..87778c7ab3 100644 --- a/src/surf/ptask_L07.cpp +++ b/src/surf/ptask_L07.cpp @@ -46,7 +46,7 @@ HostL07Model::~HostL07Model() delete surf_cpu_model_pm; } -CpuL07Model::CpuL07Model(HostL07Model* hmodel, lmm_system_t sys) : CpuModel(), hostModel_(hmodel) +CpuL07Model::CpuL07Model(HostL07Model* hmodel, kernel::lmm::System* sys) : CpuModel(), hostModel_(hmodel) { maxmin_system_ = sys; } @@ -56,7 +56,7 @@ CpuL07Model::~CpuL07Model() maxmin_system_ = nullptr; } -NetworkL07Model::NetworkL07Model(HostL07Model* hmodel, lmm_system_t sys) : NetworkModel(), hostModel_(hmodel) +NetworkL07Model::NetworkL07Model(HostL07Model* hmodel, kernel::lmm::System* sys) : NetworkModel(), hostModel_(hmodel) { maxmin_system_ = sys; loopback_ = NetworkL07Model::createLink("__loopback__", 498000000, 0.000015, SURF_LINK_FATPIPE); diff --git a/src/surf/ptask_L07.hpp b/src/surf/ptask_L07.hpp index b783d559a5..90de6a9f6e 100644 --- a/src/surf/ptask_L07.hpp +++ b/src/surf/ptask_L07.hpp @@ -46,7 +46,7 @@ public: class CpuL07Model : public CpuModel { public: - CpuL07Model(HostL07Model* hmodel, lmm_system_t sys); + CpuL07Model(HostL07Model* hmodel, kernel::lmm::System* sys); ~CpuL07Model(); Cpu *createCpu(simgrid::s4u::Host *host, std::vector *speedPerPstate, int core) override; @@ -55,7 +55,7 @@ public: class NetworkL07Model : public NetworkModel { public: - NetworkL07Model(HostL07Model* hmodel, lmm_system_t sys); + NetworkL07Model(HostL07Model* hmodel, kernel::lmm::System* sys); ~NetworkL07Model(); LinkImpl* createLink(const std::string& name, double bandwidth, double latency, e_surf_link_sharing_policy_t policy) override; diff --git a/src/surf/storage_n11.cpp b/src/surf/storage_n11.cpp index 05cde1816c..4ee0d4a68e 100644 --- a/src/surf/storage_n11.cpp +++ b/src/surf/storage_n11.cpp @@ -96,8 +96,8 @@ void StorageN11Model::updateActionsState(double /*now*/, double delta) * Resource * ************/ -StorageN11::StorageN11(StorageModel* model, std::string name, lmm_system_t maxminSystem, double bread, double bwrite, - std::string type_id, std::string content_name, sg_size_t size, std::string attach) +StorageN11::StorageN11(StorageModel* model, std::string name, kernel::lmm::System* maxminSystem, double bread, + double bwrite, std::string type_id, std::string content_name, sg_size_t size, std::string attach) : StorageImpl(model, name, maxminSystem, bread, bwrite, type_id, content_name, size, attach) { XBT_DEBUG("Create resource with Bread '%f' Bwrite '%f' and Size '%llu'", bread, bwrite, size); diff --git a/src/surf/storage_n11.hpp b/src/surf/storage_n11.hpp index c38ec744e2..09ddf63861 100644 --- a/src/surf/storage_n11.hpp +++ b/src/surf/storage_n11.hpp @@ -39,7 +39,7 @@ public: class StorageN11 : public StorageImpl { public: - StorageN11(StorageModel* model, std::string name, lmm_system_t maxminSystem, double bread, double bwrite, + StorageN11(StorageModel* model, std::string name, kernel::lmm::System* maxminSystem, double bread, double bwrite, std::string type_id, std::string content_name, sg_size_t size, std::string attach); virtual ~StorageN11() = default; StorageAction* read(sg_size_t size); diff --git a/src/surf/trace_mgr.cpp b/src/surf/trace_mgr.cpp index 2e2743ff2c..9fd46209b2 100644 --- a/src/surf/trace_mgr.cpp +++ b/src/surf/trace_mgr.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2004-2005, 2007, 2009-2014, 2016-2017. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2004-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/src/surf/xml/surfxml_parseplatf.cpp b/src/surf/xml/surfxml_parseplatf.cpp index de90f8d12b..a8d085c5cc 100644 --- a/src/surf/xml/surfxml_parseplatf.cpp +++ b/src/surf/xml/surfxml_parseplatf.cpp @@ -1,5 +1,4 @@ -/* Copyright (c) 2006-2017. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2006-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ diff --git a/teshsuite/surf/lmm_usage/lmm_usage.cpp b/teshsuite/surf/lmm_usage/lmm_usage.cpp index c4ea52e51f..acac3e1e0d 100644 --- a/teshsuite/surf/lmm_usage/lmm_usage.cpp +++ b/teshsuite/surf/lmm_usage/lmm_usage.cpp @@ -1,7 +1,6 @@ /* A few tests for the maxmin library */ -/* Copyright (c) 2007-2018s. The SimGrid Team. - * All rights reserved. */ +/* Copyright (c) 2007-2018. The SimGrid Team. All rights reserved. */ /* This program is free software; you can redistribute it and/or modify it * under the terms of the license (GNU LGPL) which comes with this package. */ @@ -98,7 +97,7 @@ static void test1(method_t method) set_default_protocol_function(simgrid::kernel::lmm::func_reno_f, simgrid::kernel::lmm::func_reno_fpi, simgrid::kernel::lmm::func_reno_fpi); - lmm_system_t Sys = new simgrid::kernel::lmm::System(true); + simgrid::kernel::lmm::System* Sys = new simgrid::kernel::lmm::System(true); simgrid::kernel::lmm::Constraint* L1 = Sys->constraint_new(nullptr, a); simgrid::kernel::lmm::Constraint* L2 = Sys->constraint_new(nullptr, b); simgrid::kernel::lmm::Constraint* L3 = Sys->constraint_new(nullptr, a); @@ -186,7 +185,7 @@ static void test2(method_t method) set_default_protocol_function(simgrid::kernel::lmm::func_reno_f, simgrid::kernel::lmm::func_reno_fp, simgrid::kernel::lmm::func_reno_fpi); - lmm_system_t Sys = new simgrid::kernel::lmm::System(true); + simgrid::kernel::lmm::System* Sys = new simgrid::kernel::lmm::System(true); simgrid::kernel::lmm::Constraint* CPU1 = Sys->constraint_new(nullptr, 200.0); simgrid::kernel::lmm::Constraint* CPU2 = Sys->constraint_new(nullptr, 100.0); @@ -259,7 +258,7 @@ static void test3(method_t method) set_default_protocol_function(simgrid::kernel::lmm::func_reno_f, simgrid::kernel::lmm::func_reno_fp, simgrid::kernel::lmm::func_reno_fpi); - lmm_system_t Sys = new simgrid::kernel::lmm::System(true); + simgrid::kernel::lmm::System* Sys = new simgrid::kernel::lmm::System(true); /* Creates the constraints */ simgrid::kernel::lmm::Constraint** tmp_cnst = new simgrid::kernel::lmm::Constraint*[15]; diff --git a/teshsuite/surf/maxmin_bench/maxmin_bench.cpp b/teshsuite/surf/maxmin_bench/maxmin_bench.cpp index 108223882f..2b22d14a70 100644 --- a/teshsuite/surf/maxmin_bench/maxmin_bench.cpp +++ b/teshsuite/surf/maxmin_bench/maxmin_bench.cpp @@ -44,7 +44,7 @@ static void test(int nb_cnst, int nb_var, int nb_elem, unsigned int pw_base_limi simgrid::kernel::lmm::Variable* var[nb_var]; int used[nb_cnst]; - lmm_system_t Sys = new simgrid::kernel::lmm::System(true); + simgrid::kernel::lmm::System* Sys = new simgrid::kernel::lmm::System(true); for (int i = 0; i < nb_cnst; i++) { cnst[i] = Sys->constraint_new(NULL, float_random(10.0)); -- 2.20.1