1 /* Copyright (c) 2007-2017. The SimGrid Team. All rights reserved. */
3 /* This program is free software; you can redistribute it and/or modify it
4 * under the terms of the license (GNU LGPL) which comes with this package. */
6 #ifndef SIMIX_HOST_PRIVATE_H
7 #define SIMIX_HOST_PRIVATE_H
13 #include <xbt/Extendable.hpp>
15 #include "simgrid/simix.h"
16 #include "popping_private.h"
18 #include "src/kernel/activity/SynchroExec.hpp"
20 /** @brief Host datatype from SIMIX POV */
27 static simgrid::xbt::Extension<simgrid::s4u::Host, Host> EXTENSION_ID;
32 xbt_swag_t process_list;
33 std::vector<ProcessArg*> auto_restart_processes;
34 std::vector<ProcessArg*> boot_processes;
42 XBT_PRIVATE void SIMIX_host_add_auto_restart_process(sg_host_t host,
44 std::function<void()> code,
47 xbt_dict_t properties,
50 XBT_PRIVATE void SIMIX_host_autorestart(sg_host_t host);
51 XBT_PRIVATE smx_activity_t SIMIX_execution_start(smx_actor_t issuer, const char *name,
52 double flops_amount, double priority, double bound);
53 XBT_PRIVATE smx_activity_t SIMIX_execution_parallel_start(const char* name, int host_nb, sg_host_t* host_list,
54 double* flops_amount, double* bytes_amount, double amount,
55 double rate, double timeout);
56 XBT_PRIVATE void SIMIX_execution_cancel(smx_activity_t synchro);
57 XBT_PRIVATE void SIMIX_execution_set_priority(smx_activity_t synchro, double priority);
58 XBT_PRIVATE void SIMIX_execution_set_bound(smx_activity_t synchro, double bound);
60 XBT_PRIVATE void SIMIX_execution_finish(simgrid::kernel::activity::Exec *exec);
62 XBT_PRIVATE void SIMIX_set_category(smx_activity_t synchro, const char *category);