XBT_LOG_NEW_DEFAULT_CATEGORY(energy_vm, "Messages of this example");
-static int worker_func() {
+static int worker_func(int argc, char *argv[]) {
+ (void)argc;
+ (void)argv;
msg_task_t task1 = MSG_task_create("t1", 300E6, 0, NULL);
MSG_task_execute (task1);
MSG_task_destroy(task1);
int main(int argc, char *argv[])
{
- msg_error_t res = MSG_OK;
- sg_energy_plugin_init();
+ sg_host_energy_plugin_init();
MSG_init(&argc, argv);
xbt_assert(argc > 1, "Usage: %s platform_file\n\tExample: %s msg_platform.xml\n", argv[0], argv[0]);
MSG_process_create("dvfs",dvfs,NULL,MSG_host_by_name("MyHost1"));
- res = MSG_main();
+ msg_error_t res = MSG_main();
XBT_INFO("Total simulation time: %.2f; All hosts must have the exact same energy consumption.", MSG_get_clock());