From bf4d7e27a9c9c2d1b01115741f03995b386eb234 Mon Sep 17 00:00:00 2001 From: Martin Quinson Date: Fri, 1 Feb 2019 21:54:07 +0100 Subject: [PATCH] tidy some #includes in MC --- src/mc/ObjectInformation.hpp | 8 +++---- src/mc/checker/simgrid_mc.cpp | 23 +++----------------- src/mc/mc_unw.hpp | 1 - src/mc/remote/Channel.cpp | 8 +++---- src/mc/remote/Client.cpp | 19 ++++------------- src/mc/remote/RemoteClient.cpp | 39 ++++++---------------------------- src/mc/remote/mc_protocol.cpp | 13 ------------ 7 files changed, 19 insertions(+), 92 deletions(-) diff --git a/src/mc/ObjectInformation.hpp b/src/mc/ObjectInformation.hpp index c9249a0fb4..c59369bb58 100644 --- a/src/mc/ObjectInformation.hpp +++ b/src/mc/ObjectInformation.hpp @@ -12,12 +12,10 @@ #include #include -#include "xbt/base.h" - -#include "src/xbt/memory_map.hpp" -#include "src/mc/mc_forward.hpp" -#include "src/mc/Type.hpp" #include "src/mc/Frame.hpp" +#include "src/mc/Type.hpp" +#include "src/mc/mc_forward.hpp" +#include "src/xbt/memory_map.hpp" #include "src/smpi/include/private.hpp" diff --git a/src/mc/checker/simgrid_mc.cpp b/src/mc/checker/simgrid_mc.cpp index 5394fbe3e7..e8c0ca82b2 100644 --- a/src/mc/checker/simgrid_mc.cpp +++ b/src/mc/checker/simgrid_mc.cpp @@ -4,29 +4,12 @@ /* 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. */ -#include - -#include -#include -#include - -#include - -#include - -#include - #include "simgrid/sg_config.hpp" -#include "src/xbt_modinter.h" - -#include "src/mc/Session.hpp" #include "src/mc/checker/Checker.hpp" -#include "src/mc/mc_base.h" -#include "src/mc/mc_comm_pattern.hpp" #include "src/mc/mc_exit.hpp" -#include "src/mc/mc_private.hpp" -#include "src/mc/mc_safety.hpp" -#include "src/mc/remote/mc_protocol.h" + +#include +#include XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_main, mc, "Entry point for simgrid-mc"); diff --git a/src/mc/mc_unw.hpp b/src/mc/mc_unw.hpp index 4c302c894e..466b3dfe04 100644 --- a/src/mc/mc_unw.hpp +++ b/src/mc/mc_unw.hpp @@ -30,7 +30,6 @@ #include #include -#include namespace simgrid { namespace unw { diff --git a/src/mc/remote/Channel.cpp b/src/mc/remote/Channel.cpp index 7594e5e68b..3a0c4ebb02 100644 --- a/src/mc/remote/Channel.cpp +++ b/src/mc/remote/Channel.cpp @@ -4,16 +4,14 @@ /* 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. */ +#include "src/mc/remote/Channel.hpp" +#include + #include #include - #include #include -#include - -#include "src/mc/remote/Channel.hpp" - XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_Channel, mc, "MC interprocess communication"); namespace simgrid { diff --git a/src/mc/remote/Client.cpp b/src/mc/remote/Client.cpp index ada56e0be0..ffbbfae6ab 100644 --- a/src/mc/remote/Client.cpp +++ b/src/mc/remote/Client.cpp @@ -3,28 +3,17 @@ /* 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. */ +#include "src/mc/remote/Client.hpp" +#include "src/internal_config.h" +#include + #include #include #include - #include #include #include -#include -#include -#include - -#include - -#include "src/internal_config.h" - -#include "src/mc/mc_request.hpp" -#include "src/mc/remote/Client.hpp" -#include "src/mc/remote/mc_protocol.h" - -#include "src/smpi/include/private.hpp" - // We won't need those once the separation MCer/MCed is complete: #include "src/mc/mc_smx.hpp" diff --git a/src/mc/remote/RemoteClient.cpp b/src/mc/remote/RemoteClient.cpp index 28721c0047..6d239f296c 100644 --- a/src/mc/remote/RemoteClient.cpp +++ b/src/mc/remote/RemoteClient.cpp @@ -3,45 +3,18 @@ /* 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. */ -#define _FILE_OFFSET_BITS 64 /* needed for pread_whole to work as expected on 32bits */ - -#include -#include -#include -#include -#include -#include -#include - -#include - -#include - -#include -#include // PROT_* -#include -#include - -#include - -#include - -#include -#include +#include "src/mc/remote/RemoteClient.hpp" -#include "xbt/base.h" #include "xbt/file.hpp" #include "xbt/log.h" -#include - #include "src/mc/mc_smx.hpp" -#include "src/mc/mc_unw.hpp" #include "src/mc/sosp/mc_snapshot.hpp" -#include "src/mc/AddressSpace.hpp" -#include "src/mc/ObjectInformation.hpp" -#include "src/mc/Variable.hpp" -#include "src/mc/remote/RemoteClient.hpp" +#define _FILE_OFFSET_BITS 64 /* needed for pread_whole to work as expected on 32bits */ + +#include +#include +#include // PROT_* using simgrid::mc::remote; diff --git a/src/mc/remote/mc_protocol.cpp b/src/mc/remote/mc_protocol.cpp index 7aed21630c..f014ece663 100644 --- a/src/mc/remote/mc_protocol.cpp +++ b/src/mc/remote/mc_protocol.cpp @@ -4,21 +4,8 @@ /* 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. */ -#include -#include // std::size_t -#include // perror -#include - -#include -#include - -#include - -#include "src/mc/remote/Client.hpp" #include "src/mc/remote/mc_protocol.h" -XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_protocol, mc, "Generic MC protocol logic"); - const char* MC_message_type_name(e_mc_message_type type) { switch (type) { -- 2.20.1