}
}
-extern "C" {
typedef simgrid::jedule::Jedule *jedule_t;
-}
#endif
#endif /* JEDULE_HPP_ */
}
}
-extern "C" {
typedef simgrid::jedule::Event* jed_event_t;
-}
-
#endif
#endif /* JEDULE_EVENTS_H_ */
}
}
-extern "C" {
typedef simgrid::jedule::Container * jed_container_t;
typedef simgrid::jedule::Subset * jed_subset_t;
void get_resource_selection_by_hosts(std::vector<jed_subset_t>* subset_list, std::vector<sg_host_t> *host_list);
-}
#endif
} // namespace kernel
} // namespace simgrid
-extern "C" {
XBT_PRIVATE xbt_node_t new_xbt_graph_node(xbt_graph_t graph, const char* name,
std::map<std::string, xbt_node_t>* nodes);
XBT_PRIVATE xbt_edge_t new_xbt_graph_edge(xbt_graph_t graph, xbt_node_t s, xbt_node_t d,
std::map<std::string, xbt_edge_t>* edges);
-}
#endif /* SIMGRID_ROUTING_GENERIC_HPP_ */
#include <jni.h>
#include <string>
-extern "C" {
-
/* Search a class and throw an exception if not found */
jclass jxbt_get_class(JNIEnv* env, const char* name);
void jxbt_throw_task_cancelled(JNIEnv* env, std::string details);
/** Thrown when looking for a storage from name does not lead to anything */
void jxbt_throw_storage_not_found(JNIEnv* env, std::string invalid_name);
-}
+
#endif
#include "simgrid/msg.h"
#include "simgrid_lua.hpp"
-extern "C" {
-
void sglua_register_host_functions(lua_State* L);
msg_host_t sglua_check_host(lua_State* L, int index);
void sglua_register_platf_functions(lua_State* L);
-}
#define lua_ensure(...) _XBT_IF_ONE_ARG(_lua_ensure_ARG1, _lua_ensure_ARGN, __VA_ARGS__)(__VA_ARGS__)
#define _lua_ensure_ARG1(cond) _lua_ensure_ARGN(cond, "Assertion %s failed", #cond)
#ifndef LUA_UTILS_HPP
#define LUA_UTILS_HPP
-extern "C" {
-
#include <lua.h>
/**
void* sglua_checkudata_debug(lua_State* L, int ud, const char* tname);
const char* sglua_get_spaces(int length);
int sglua_memory_writer(lua_State* L, const void* source, size_t size, void* userdata);
-}
#endif
XBT_PRIVATE container_t smpi_container(int rank);
-extern "C" {
-
XBT_PRIVATE void TRACE_internal_smpi_set_category(const char* category);
XBT_PRIVATE const char* TRACE_internal_smpi_get_category();
XBT_PRIVATE void TRACE_smpi_computing_init(int rank);
std::to_string(linenumber);
}
};
-}
#endif
typedef simgrid::kernel::context::ContextFactory *smx_context_factory_t;
-extern "C" {
-
XBT_PRIVATE void SIMIX_context_mod_init();
XBT_PRIVATE void SIMIX_context_mod_exit();
XBT_PUBLIC int SIMIX_process_get_maxpid();
XBT_PRIVATE void SIMIX_post_create_environment();
-}
XBT_PRIVATE simgrid::simix::ActorCodeFactory& SIMIX_get_actor_code_factory(const char *name);
}
}
-extern "C" {
-
/**
* Type: `xbt_dynar_t<mc_list_comm_pattern_t>`
*/
XBT_PRIVATE void MC_state_copy_incomplete_communications_pattern(simgrid::mc::State* state);
XBT_PRIVATE void MC_state_copy_index_communications_pattern(simgrid::mc::State* state);
-}
#endif
}
}
-extern "C" {
-
/********************************* MC Global **********************************/
XBT_PRIVATE void MC_init_dot_output();
#define MC_VERBOSE 1
/********************************** Miscellaneous **********************************/
-}
-
namespace simgrid {
namespace mc {
* MCed code.
*/
-extern "C" {
-
/** Get the issuer of a simcall (`req->issuer`)
*
* In split-process mode, it does the black magic necessary to get an address
XBT_PRIVATE int MC_smpi_process_count(void);
XBT_PRIVATE unsigned long MC_smx_get_maxpid(void);
-}
#endif
#include "src/mc/mc_forward.hpp"
#include "src/mc/mc_unw.hpp"
-extern "C" {
-
// ***** Snapshot region
XBT_PRIVATE void mc_region_restore_sparse(simgrid::mc::RemoteClient* process, mc_mem_region_t reg);
XBT_PRIVATE mc_mem_region_t mc_get_snapshot_region(const void* addr, const simgrid::mc::Snapshot* snapshot,
int process_index);
-}
// ***** MC Snapshot
}
}
-extern "C" {
-
static XBT_ALWAYS_INLINE mc_mem_region_t mc_get_region_hinted(void* addr, simgrid::mc::Snapshot* snapshot,
int process_index, mc_mem_region_t region)
{
}
static const void* mc_snapshot_get_heap_end(simgrid::mc::Snapshot* snapshot);
-}
namespace simgrid {
namespace mc {
}
}
-extern "C" {
-
XBT_PRIVATE void mc_restore_page_snapshot_region(simgrid::mc::RemoteClient* process, void* start_addr,
simgrid::mc::ChunkedData const& pagenos);
void* res;
return *(void**)MC_region_read(region, &res, addr, sizeof(void*));
}
-}
#endif
}
}
-extern "C" {
extern XBT_PRIVATE simgrid::sd::Global *sd_global;
/* Task */
XBT_PRIVATE bool acyclic_graph_detail(xbt_dynar_t dag);
XBT_PRIVATE void uniq_transfer_task_name(SD_task_t task);
XBT_PRIVATE const char *__get_state_name(e_SD_task_state_t state);
-}
#endif
typedef simgrid::kernel::actor::ActorImpl* smx_actor_t;
-extern "C" {
-
XBT_PRIVATE smx_actor_t SIMIX_process_create(const char* name, std::function<void()> code, void* data, sg_host_t host,
std::map<std::string, std::string>* properties,
smx_actor_t parent_process);
XBT_PRIVATE void SIMIX_process_auto_restart_set(smx_actor_t process, int auto_restart);
extern void (*SMPI_switch_data_segment)(simgrid::s4u::ActorPtr actor);
-}
XBT_PRIVATE void SIMIX_process_sleep_destroy(smx_activity_t synchro);
XBT_PRIVATE smx_activity_t SIMIX_process_join(smx_actor_t issuer, smx_actor_t process, double timeout);
#include <boost/intrusive_ptr.hpp>
-extern "C" {
-
/********************************* Simcalls *********************************/
XBT_PUBLIC_DATA const char* simcall_names[]; /* Name of each simcall */
XBT_PRIVATE const char* SIMIX_simcall_name(e_smx_simcall_t kind);
XBT_PRIVATE void SIMIX_run_kernel(std::function<void()> const* code);
XBT_PRIVATE void SIMIX_run_blocking(std::function<void()> const* code);
-}
/* Defines the marshal/unmarshal functions for each type of parameters.
*
}
}
-extern "C" {
XBT_PRIVATE void SIMIX_host_add_auto_restart_process(sg_host_t host, const char* name, std::function<void()> code,
void* data, double kill_time,
std::map<std::string, std::string>* properties, int auto_restart);
XBT_PRIVATE void SIMIX_execution_finish(smx_activity_t synchro);
XBT_PRIVATE void SIMIX_set_category(smx_activity_t synchro, const char* category);
-}
XBT_PRIVATE boost::intrusive_ptr<simgrid::kernel::activity::ExecImpl>
SIMIX_execution_start(const char* name, double flops_amount, double priority, double bound, sg_host_t host);
}
}
-extern "C" {
-
XBT_PUBLIC_DATA std::unique_ptr<simgrid::simix::Global> simix_global;
XBT_PUBLIC void SIMIX_clean();
_smx_throw_issuer->exception = std::make_exception_ptr(e); \
} else \
((void)0)
-}
#endif
#include <time.h>
#endif
-extern "C" {
-
#define PERSISTENT 0x1
#define NON_PERSISTENT 0x2
#define SEND 0x4
XBT_PRIVATE void smpi_free_tmp_buffer(void* buf);
XBT_PRIVATE void smpi_free_replay_tmp_buffers();
+extern "C" {
// f77 wrappers
+
void mpi_init_(int* ierr);
void mpi_finalize_(int* ierr);
void mpi_abort_(int* comm, int* errorcode, int* ierr);
XBT_PUBLIC int smpi_getopt_long (int argc, char *const *argv, const char *options, const struct option *long_options, int *opt_index);
XBT_PUBLIC int smpi_getopt (int argc, char *const *argv, const char *options);
+} // extern "C"
+
struct s_smpi_privatization_region_t {
void* address;
int file_descriptor;
extern XBT_PRIVATE int smpi_loaded_page;
extern XBT_PRIVATE int smpi_universe_size;
XBT_PRIVATE smpi_privatization_region_t smpi_init_global_memory_segment_process();
-}
/**
* Get the address of the beginning of the memory page where addr is located.
extern std::unordered_map<std::string, double> location2speedup;
/** @brief Returns the last call location (filename, linenumber). Process-specific. */
-extern "C" {
XBT_PUBLIC smpi_trace_call_location_t* smpi_trace_get_call_location();
-}
enum class SmpiPrivStrategies { None = 0, Mmap = 1, Dlopen = 2, Default = Dlopen };
#include <string>
#include <vector>
-extern "C" {
-
// Methods used to parse and store the values for timing injections in smpi
struct s_smpi_factor_t {
size_t factor = 0;
std::vector<double> values;
};
-}
XBT_PUBLIC std::vector<s_smpi_factor_t> parse_factor(std::string smpi_coef_string);
};
XBT_PUBLIC void ns3_initialize(std::string TcpProtocol);
-extern "C" {
XBT_PUBLIC void ns3_simulator(double maxSeconds);
XBT_PUBLIC void ns3_add_link(NetPointNs3* src, NetPointNs3* dst, double bw, double lat);
XBT_PUBLIC void ns3_add_cluster(const char* id, double bw, double lat);
-}
class XBT_PRIVATE SgFlow {
public:
#include "simgrid/forward.h"
#include "xbt/sysdep.h"
-extern "C" {
-
/* Generic functions common to all models */
XBT_PRIVATE FILE* surf_fopen(const char* name, const char* mode);
/* from surf_instr.c */
void TRACE_surf_host_set_speed(double date, const char* resource, double power);
void TRACE_surf_link_set_bandwidth(double date, const char* resource, double bandwidth);
-}
#endif
#include <xbt/signal.hpp>
-extern "C" {
-
/* Module management functions */
XBT_PUBLIC void sg_platf_init();
XBT_PUBLIC void sg_platf_exit();
XBT_PUBLIC double surf_parse_get_speed(const char* string, const char* entity_kind, std::string name);
XBT_PUBLIC int surf_parse(); /* Entry-point to the parser */
-}
#endif
};
}}}
-extern "C" {
-
/********** Routing **********/
void routing_cluster_add_backbone(simgrid::kernel::resource::LinkImpl* bb);
/*** END of the parsing cruft ***/
XBT_PUBLIC int surf_parse_get_debug();
XBT_PUBLIC void surf_parse_set_debug(int bdebug);
XBT_PUBLIC int surf_parse_lex_destroy();
-}
namespace simgrid {
namespace surf {