Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Remove features marked with DEPRECATED_v324.
authorArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Tue, 25 Jun 2019 14:25:13 +0000 (16:25 +0200)
committerArnaud Giersch <arnaud.giersch@univ-fcomte.fr>
Wed, 26 Jun 2019 08:05:15 +0000 (10:05 +0200)
18 files changed:
doc/Doxyfile.in
docs/source/Doxyfile
include/simgrid/Exception.hpp
include/simgrid/s4u/Activity.hpp
include/simgrid/s4u/Actor.hpp
include/simgrid/s4u/Comm.hpp
include/simgrid/s4u/Exec.hpp
include/simgrid/s4u/Io.hpp
include/simgrid/simix.h
include/smpi/mpif.h.in
include/smpi/smpi.h
include/xbt/base.h
src/kernel/actor/ActorImpl.cpp
src/s4u/s4u_Actor.cpp
src/simix/smx_deployment.cpp
src/simix/smx_environment.cpp [deleted file]
src/smpi/internals/smpi_dvfs.cpp
tools/cmake/DefinePackages.cmake

index 40bde05..b641cb4 100644 (file)
@@ -1442,7 +1442,6 @@ PREDEFINED             = __cplusplus \
                         XBT_PRIVATE= \
                         XBT_ATTRIB_NORETURN= \
                         XBT_ATTRIB_UNUSED= \
-                         XBT_ATTRIB_DEPRECATED_v324(m)= \
                          XBT_ATTRIB_DEPRECATED_v325(m)= \
                          XBT_ATTRIB_DEPRECATED_v327(m)=
 
index 7165a2a..509c698 100644 (file)
@@ -40,6 +40,5 @@ PREDEFINED             += \
     XBT_PRIVATE= \
     XBT_ATTRIB_NORETURN= \
     XBT_ATTRIB_UNUSED= \
-    XBT_ATTRIB_DEPRECATED_v324(m)= \
     XBT_ATTRIB_DEPRECATED_v325(m)= \
     XBT_ATTRIB_DEPRECATED_v327(m)=
index 0012ee0..685f36d 100644 (file)
@@ -87,6 +87,7 @@ private:
  *  @ref WithContextException base class. We should deprecate it and replace it
  *  with either C++ different exceptions or `std::system_error` which already
  *  provides this (category + error code) logic.
+ *  TODO ^^
  *
  *  @ingroup XBT_ex_c
  */
index de5b14a..a464c20 100644 (file)
@@ -94,10 +94,6 @@ public:
 
   kernel::activity::ActivityImpl* get_impl() const { return pimpl_.get(); }
 
-#ifndef DOXYGEN
-  XBT_ATTRIB_DEPRECATED_v324("Please use Activity::wait_for()") virtual void wait(double timeout) = 0;
-#endif
-
 private:
   kernel::activity::ActivityImplPtr pimpl_ = nullptr;
   Activity::State state_                   = Activity::State::INITED;
index 141a49f..3c12abc 100644 (file)
@@ -464,9 +464,6 @@ XBT_PUBLIC void migrate(Host* new_host);
 #ifndef DOXYGEN
 XBT_ATTRIB_DEPRECATED_v325("Please use std::function<void(bool)> for first parameter.") XBT_PUBLIC
     void on_exit(const std::function<void(int, void*)>& fun, void* data);
-
-/** @deprecated See this_actor::exit() */
-XBT_ATTRIB_DEPRECATED_v324("Please use this_actor::exit()") XBT_PUBLIC void kill();
 #endif
 }
 
index 467dd88..8f767a3 100644 (file)
@@ -122,10 +122,6 @@ public:
   size_t get_dst_data_size();
 
   Actor* get_sender();
-
-#ifndef DOXYGEN
-  XBT_ATTRIB_DEPRECATED_v324("Please use Comm::wait_for()") void wait(double t) override { wait_for(t); }
-#endif
 };
 } // namespace s4u
 } // namespace simgrid
index 6515064..6aeb5fc 100644 (file)
@@ -68,8 +68,6 @@ public:
   Exec* cancel() override;
   const std::string& get_name() const { return name_; }
   const char* get_cname() const { return name_.c_str(); }
-
-  XBT_ATTRIB_DEPRECATED_v324("Please use Exec::wait_for()") void wait(double t) override { wait_for(t); }
 };
 
 class XBT_PUBLIC ExecSeq : public Exec {
index 50cf48d..d486b34 100644 (file)
@@ -50,10 +50,6 @@ public:
 
   double get_remaining() override;
   sg_size_t get_performed_ioops();
-
-#ifndef DOXYGEN
-  XBT_ATTRIB_DEPRECATED_v324("Please use Io::wait_for()") void wait(double t) override { wait_for(t); }
-#endif
 };
 
 } // namespace s4u
index ba069df..303093b 100644 (file)
@@ -94,18 +94,8 @@ XBT_PUBLIC double SIMIX_timer_get_date(smx_timer_t timer);
 XBT_PUBLIC void SIMIX_display_process_status();
 SG_END_DECL()
 
-/******************************* Environment **********************************/
-SG_BEGIN_DECL()
-XBT_ATTRIB_DEPRECATED_v324("Please use simgrid_load_platform()") XBT_PUBLIC
-    void SIMIX_create_environment(const char* file);
-SG_END_DECL()
-
 /******************************** Deployment **********************************/
 SG_BEGIN_DECL()
-XBT_ATTRIB_DEPRECATED_v324("Please use simgrid_register_function()") XBT_PUBLIC
-    void SIMIX_function_register(const char* name, xbt_main_func_t code);
-XBT_ATTRIB_DEPRECATED_v324("Please use simgrid_load_deployment()") XBT_PUBLIC
-    void SIMIX_launch_application(const char* file);
 XBT_PUBLIC void SIMIX_function_register_default(xbt_main_func_t code);
 
 XBT_PUBLIC void SIMIX_init_application();
@@ -187,9 +177,6 @@ XBT_PUBLIC bool simcall_execution_test(const smx_activity_t& execution);
 
 /**************************** Process simcalls ********************************/
 SG_BEGIN_DECL()
-XBT_ATTRIB_DEPRECATED_v324("Please use ActorImpl::throw_exception") XBT_PUBLIC
-    void SIMIX_process_throw(smx_actor_t process, xbt_errcat_t cat, int value, const char* mesg);
-
 void simcall_process_set_data(smx_actor_t process, void* data);
 /* Process handling */
 XBT_PUBLIC void simcall_process_suspend(smx_actor_t process);
index a482089..96f726c 100644 (file)
       double precision smpi_get_host_power_peak_at
       double precision smpi_get_host_current_power_peak
       integer smpi_get_host_nb_pstates
+      integer smpi_get_host_pstate
       double precision smpi_get_host_consumed_energy
 @MODULE_MPIF_OUT@
index 8b0e629..309804a 100644 (file)
@@ -975,16 +975,6 @@ XBT_PUBLIC void smpi_execute_flops(double flops);
 XBT_PUBLIC void smpi_execute(double duration);
 XBT_PUBLIC void smpi_execute_benched(double duration);
 
-// PLEASE NOTE: If you remove these functions, the entire smpi_dvfs.cpp file can be removed as well!!
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_get_pstate_speed(sg_host_self(), pstate_index) instead") XBT_PUBLIC double smpi_get_host_power_peak_at(int pstate_index);
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_speed(sg_host_self()) instead") XBT_PUBLIC double smpi_get_host_current_power_peak();
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_get_nb_pstates(sg_host_self()) instead") XBT_PUBLIC int smpi_get_host_nb_pstates();
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_set_pstate(sg_host_self(), pstate_index) instead") XBT_PUBLIC void smpi_set_host_pstate(int pstate_index);
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_get_pstate(sg_host_self()) instead") XBT_PUBLIC int smpi_get_host_pstate();
-
-XBT_ATTRIB_DEPRECATED_v324("Please use sg_host_get_consumed_energy(sg_host_self()) instead") XBT_PUBLIC double smpi_get_host_consumed_energy();
-
-
 XBT_PUBLIC unsigned long long smpi_rastro_resolution();
 XBT_PUBLIC unsigned long long smpi_rastro_timestamp();
 XBT_PUBLIC void smpi_sample_1(int global, const char* file, int line, int iters, double threshold);
index 3b71784..8c934d2 100644 (file)
@@ -71,8 +71,6 @@
 #define XBT_ATTRIB_DEPRECATED(mesg) __attribute__((deprecated(mesg)))
 #endif
 
-#define XBT_ATTRIB_DEPRECATED_v324(mesg)                                                                               \
-  XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped in v3.24)") /* Will be dropped in v3.24 */
 #define XBT_ATTRIB_DEPRECATED_v325(mesg)                                                                               \
   XBT_ATTRIB_DEPRECATED(mesg " (this compatibility wrapper will be dropped in v3.25)") /* Will be dropped in v3.25 */
 #define XBT_ATTRIB_DEPRECATED_v327(mesg)                                                                               \
index c42d015..ab52d77 100644 (file)
@@ -528,16 +528,6 @@ smx_actor_t SIMIX_process_attach(const char* name, void* data, const char* hostn
   return simgrid::kernel::actor::ActorImpl::attach(name, data, sg_host_by_name(hostname), properties).get();
 }
 
-/** @deprecated When this function gets removed, also remove the xbt_ex class, that is only there to help users to
- * transition */
-void SIMIX_process_throw(smx_actor_t actor, xbt_errcat_t cat, int value, const char* msg)
-{
-  xbt_ex e(XBT_THROW_POINT, msg);
-  e.category = cat;
-  e.value    = value;
-  actor->throw_exception(std::make_exception_ptr(e));
-}
-
 void simcall_HANDLER_process_suspend(smx_simcall_t simcall, smx_actor_t actor)
 {
   smx_activity_t sync_suspend = actor->suspend(simcall->issuer);
index 7a66c4b..0db6b20 100644 (file)
@@ -442,11 +442,6 @@ void migrate(Host* new_host)
   SIMIX_process_self()->iface()->migrate(new_host);
 }
 
-void kill() /* deprecated */
-{
-  exit();
-}
-
 } // namespace this_actor
 } // namespace s4u
 } // namespace simgrid
index 2f2ff22..7819665 100644 (file)
@@ -56,11 +56,6 @@ void SIMIX_launch_application(const std::string& file)
   }
 }
 
-void SIMIX_launch_application(const char* file) // deprecated
-{
-  simgrid_load_deployment(file);
-}
-
 // Wrap a main() function into a ActorCodeFactory:
 static simgrid::simix::ActorCodeFactory toActorCodeFactory(xbt_main_func_t code)
 {
@@ -88,11 +83,6 @@ void SIMIX_function_register(const std::string& name, void (*code)(std::vector<s
   simix_global->registered_functions[name] = toActorCodeFactory(code);
 }
 
-void SIMIX_function_register(const char* name, xbt_main_func_t code) // deprecated
-{
-  simgrid_register_function(name, code);
-}
-
 /**
  * @brief Registers a #xbt_main_func_t code as default value.
  *
diff --git a/src/simix/smx_environment.cpp b/src/simix/smx_environment.cpp
deleted file mode 100644 (file)
index e7f2c29..0000000
+++ /dev/null
@@ -1,12 +0,0 @@
-/* Copyright (c) 2007-2019. 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. */
-
-#include <simgrid/engine.h>
-#include <simgrid/simix.h>
-
-void SIMIX_create_environment(const char* file) // XBT_ATTRIB_DEPRECATED_v324
-{
-  simgrid_load_platform(file);
-}
index 85a4cc1..1347c24 100644 (file)
 
 #include "src/internal_config.h"
 
-XBT_LOG_NEW_DEFAULT_SUBCATEGORY(smpi_dvfs, smpi, "Logging specific to SMPI (experimental DVFS support)");
+#if SMPI_FORTRAN
+
+// FIXME: rework these bindings, or kill them completely
+
+#if defined(__alpha__) || defined(__sparc64__) || defined(__x86_64__) || defined(__ia64__)
+typedef int integer;
+#else
+typedef long int integer;
+#endif
+typedef double doublereal;
 
 /**
  * @brief Return the speed of the processor (in flop/s) at a given pstate
@@ -22,9 +31,10 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY(smpi_dvfs, smpi, "Logging specific to SMPI (expe
  * @param pstate_index pstate to test
  * @return Returns the processor speed associated with pstate_index
  */
-double smpi_get_host_power_peak_at(int pstate_index)
+extern "C" XBT_PUBLIC doublereal smpi_get_host_power_peak_at_(integer* pstate_index);
+doublereal smpi_get_host_power_peak_at_(integer *pstate_index)
 {
-  return sg_host_self()->get_pstate_speed(pstate_index);
+  return static_cast<doublereal>(sg_host_self()->get_pstate_speed(static_cast<int>(*pstate_index)));
 }
 
 /**
@@ -32,17 +42,19 @@ double smpi_get_host_power_peak_at(int pstate_index)
  *
  * @return Returns the current processor speed
  */
-double smpi_get_host_current_power_peak()
+extern "C" XBT_PUBLIC doublereal smpi_get_host_current_power_peak_();
+doublereal smpi_get_host_current_power_peak_()
 {
-  return sg_host_self()->get_speed();
+  return static_cast<doublereal>(sg_host_self()->get_speed());
 }
 
 /**
  * @brief Return the number of pstates defined for the current host
  */
-int smpi_get_host_nb_pstates()
+extern "C" XBT_PUBLIC integer smpi_get_host_nb_pstates_();
+integer smpi_get_host_nb_pstates_()
 {
-  return sg_host_get_nb_pstates(sg_host_self());
+  return static_cast<integer>(sg_host_self()->get_pstate_count());
 }
 
 /**
@@ -50,57 +62,25 @@ int smpi_get_host_nb_pstates()
  *
  * @param pstate_index pstate to switch to
  */
-void smpi_set_host_pstate(int pstate_index)
+extern "C" XBT_PUBLIC void smpi_set_host_pstate_(integer* pstate_index);
+void smpi_set_host_pstate_(integer *pstate_index)
 {
-  sg_host_set_pstate(sg_host_self(), pstate_index);
-}
-/** @brief Gets the pstate at which the processor currently running */
-int smpi_get_host_pstate() {
-  return sg_host_get_pstate(sg_host_self());
+  sg_host_set_pstate(sg_host_self(), (static_cast<int>(*pstate_index)));
 }
 
 /**
+ * @brief Gets the pstate at which the processor currently running
+ */
+extern "C" XBT_PUBLIC integer smpi_get_host_pstate_();
+integer smpi_get_host_pstate_()
+{
+  return static_cast<integer>(sg_host_get_pstate(sg_host_self()));
+}
+/**
  * @brief Return the total energy consumed by a host (in Joules)
  *
  * @return Returns the consumed energy
  */
-double smpi_get_host_consumed_energy() {
-  return sg_host_get_consumed_energy(sg_host_self());
-}
-
-#if SMPI_FORTRAN
-
-#if defined(__alpha__) || defined(__sparc64__) || defined(__x86_64__) || defined(__ia64__)
-typedef int integer;
-#else
-typedef long int integer;
-#endif
-typedef double doublereal;
-
-extern "C" XBT_PUBLIC doublereal smpi_get_host_power_peak_at_(integer* pstate_index);
-doublereal smpi_get_host_power_peak_at_(integer *pstate_index)
-{
-  return static_cast<doublereal>(sg_host_self()->get_pstate_speed((int)*pstate_index));
-}
-
-extern "C" XBT_PUBLIC doublereal smpi_get_host_current_power_peak_();
-doublereal smpi_get_host_current_power_peak_()
-{
-  return sg_host_self()->get_speed();
-}
-
-extern "C" XBT_PUBLIC integer smpi_get_host_nb_pstates_();
-integer smpi_get_host_nb_pstates_()
-{
-  return static_cast<integer>(sg_host_self()->get_pstate_count());
-}
-
-extern "C" XBT_PUBLIC void smpi_set_host_pstate_(integer* pstate_index);
-void smpi_set_host_pstate_(integer *pstate_index)
-{
-  sg_host_set_pstate(sg_host_self(), (static_cast<int>(*pstate_index)));
-}
-
 extern "C" XBT_PUBLIC doublereal smpi_get_host_consumed_energy_();
 doublereal smpi_get_host_consumed_energy_()
 {
index 45cf59a..a2b3c1c 100644 (file)
@@ -389,7 +389,6 @@ set(SIMIX_SRC
   src/kernel/context/ContextThread.cpp
   src/kernel/context/ContextThread.hpp
   src/simix/smx_deployment.cpp
-  src/simix/smx_environment.cpp
   src/simix/smx_global.cpp
   src/simix/popping.cpp
   src/kernel/activity/ActivityImpl.cpp