/* 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/portable.h"
#include "surf_private.h"
#include "surf_interface.hpp"
#include "network_interface.hpp"
#include "cpu_interface.hpp"
-#include "HostImplem.hpp"
+#include "src/surf/HostImpl.hpp"
#include "src/simix/smx_host_private.h"
#include "surf_routing.hpp"
#include "simgrid/sg_config.h"
#include "virtual_machine.hpp"
#include "src/instr/instr_private.h" // TRACE_is_enabled(). FIXME: remove by subscribing tracing to the surf signals
-
XBT_LOG_NEW_CATEGORY(surf, "All SURF categories");
XBT_LOG_NEW_DEFAULT_SUBCATEGORY(surf_kernel, surf,
"Logging specific to SURF (kernel)");
return -1;
}
-static XBT_INLINE void routing_asr_prop_free(void *p)
-{
- //xbt_dict_t elm = (xbt_dict_t) p;
- //xbt_dict_free(&elm); FIXME: leaking in some case? That's a sometimes double-free with AsCluster::~AsCluster
-}
-
static XBT_INLINE void surf_storage_free(void *r)
{
delete static_cast<simgrid::surf::Storage*>(r);
simgrid::s4u::Host::onDestruction(*host);
delete host;
});
+ USER_HOST_LEVEL = simgrid::s4u::Host::extension_create(NULL);
+
as_router_lib = xbt_lib_new();
storage_lib = xbt_lib_new();
storage_type_lib = xbt_lib_new();
file_lib = xbt_lib_new();
watched_hosts_lib = xbt_dict_new_homogeneous(NULL);
- sg_host_init();
XBT_DEBUG("Add routing levels");
- ROUTING_PROP_ASR_LEVEL = xbt_lib_add_level(as_router_lib,routing_asr_prop_free);
+ ROUTING_PROP_ASR_LEVEL = xbt_lib_add_level(as_router_lib, NULL);
XBT_DEBUG("Add SURF levels");
- simgrid::surf::HostImplem::classInit();
+ simgrid::surf::HostImpl::classInit();
SURF_STORAGE_LEVEL = xbt_lib_add_level(storage_lib,surf_storage_free);
xbt_init(argc, argv);