From 036f74f60a1f326ee21dfb3be0801535160bf435 Mon Sep 17 00:00:00 2001 From: Frederic Suter Date: Fri, 6 Mar 2020 13:26:00 +0100 Subject: [PATCH] this is examples/c/exec-basic --- MANIFEST.in | 3 -- teshsuite/msg/CMakeLists.txt | 3 -- teshsuite/msg/task-priority/task-priority.c | 42 ------------------- .../msg/task-priority/task-priority.tesh | 9 ---- .../msg/task-priority/task-priority_d.xml | 12 ------ 5 files changed, 69 deletions(-) delete mode 100644 teshsuite/msg/task-priority/task-priority.c delete mode 100644 teshsuite/msg/task-priority/task-priority.tesh delete mode 100644 teshsuite/msg/task-priority/task-priority_d.xml diff --git a/MANIFEST.in b/MANIFEST.in index 48b0ebc703..3189977ee8 100644 --- a/MANIFEST.in +++ b/MANIFEST.in @@ -674,9 +674,6 @@ include teshsuite/msg/io-file/io-file.tesh include teshsuite/msg/platform-properties/platform-properties.c include teshsuite/msg/platform-properties/platform-properties.tesh include teshsuite/msg/platform-properties/platform-properties_d.xml -include teshsuite/msg/task-priority/task-priority.c -include teshsuite/msg/task-priority/task-priority.tesh -include teshsuite/msg/task-priority/task-priority_d.xml include teshsuite/msg/task_destroy_cancel/task_destroy_cancel.cpp include teshsuite/msg/task_destroy_cancel/task_destroy_cancel.tesh include teshsuite/msg/task_listen_from/task_listen_from.cpp diff --git a/teshsuite/msg/CMakeLists.txt b/teshsuite/msg/CMakeLists.txt index e4dc4c4374..167bd42f2f 100644 --- a/teshsuite/msg/CMakeLists.txt +++ b/teshsuite/msg/CMakeLists.txt @@ -3,7 +3,6 @@ foreach(x cloud-two-tasks get_sender platform-properties io-file - task-priority trace_integration) if(enable_msg) add_executable (${x} EXCLUDE_FROM_ALL ${x}/${x}.c) @@ -45,7 +44,6 @@ set(tesh_files ${tesh_files} ${CMAKE_CURRENT_SOURCE_DIR}/app-bittorrent/ap set(bin_files ${bin_files} ${CMAKE_CURRENT_SOURCE_DIR}/app-bittorrent/generate.py PARENT_SCOPE) set(xml_files ${xml_files} ${CMAKE_CURRENT_SOURCE_DIR}/app-bittorrent/app-bittorrent_d.xml ${CMAKE_CURRENT_SOURCE_DIR}/platform-properties/platform-properties_d.xml - ${CMAKE_CURRENT_SOURCE_DIR}/task-priority/task-priority_d.xml ${CMAKE_CURRENT_SOURCE_DIR}/trace_integration/test-hbp1.0-hbp1.0-hbp1.0.xml ${CMAKE_CURRENT_SOURCE_DIR}/trace_integration/test-hbp1.0-hbp3.0-hbp4.0.xml ${CMAKE_CURRENT_SOURCE_DIR}/trace_integration/test-hbp1.5-hbp1.5.xml @@ -68,7 +66,6 @@ if(enable_msg) task_destroy_cancel task_listen_from task_progress io-file platform-properties - task-priority trace_integration) ADD_TESH_FACTORIES(tesh-msg-${x} "raw" diff --git a/teshsuite/msg/task-priority/task-priority.c b/teshsuite/msg/task-priority/task-priority.c deleted file mode 100644 index 80ccaa9cb3..0000000000 --- a/teshsuite/msg/task-priority/task-priority.c +++ /dev/null @@ -1,42 +0,0 @@ -/* Copyright (c) 2007-2020. 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/msg.h" -XBT_LOG_NEW_DEFAULT_CATEGORY(msg_test, "Messages specific for this msg example"); - -static int test(int argc, char* argv[]) -{ - xbt_assert(argc == 3); - double computation_amount = xbt_str_parse_double(argv[1], "Invalid argument: %s"); - double priority = xbt_str_parse_double(argv[2], "Invalid argument: %s"); - - XBT_INFO("Hello! Running a task of size %g with priority %g", computation_amount, priority); - msg_task_t task = MSG_task_create("Task", computation_amount, 0.0, NULL); - MSG_task_set_priority(task, priority); - - MSG_task_execute(task); - MSG_task_destroy(task); - - XBT_INFO("Goodbye now!"); - return 0; -} - -int main(int argc, char* argv[]) -{ - MSG_init(&argc, argv); - xbt_assert(argc > 2, "Usage: %s platform_file deployment_file\n" - "\tExample: %s msg_platform.xml msg_deployment.xml\n", - argv[0], argv[0]); - - MSG_create_environment(argv[1]); - MSG_function_register("test", test); - MSG_launch_application(argv[2]); - - msg_error_t res = MSG_main(); - - XBT_INFO("Simulation time %g", MSG_get_clock()); - - return res != MSG_OK; -} diff --git a/teshsuite/msg/task-priority/task-priority.tesh b/teshsuite/msg/task-priority/task-priority.tesh deleted file mode 100644 index 8af98f9e3a..0000000000 --- a/teshsuite/msg/task-priority/task-priority.tesh +++ /dev/null @@ -1,9 +0,0 @@ -#!/usr/bin/env tesh - -! output sort 19 -$ ${bindir:=.}/task-priority ${platfdir}/small_platform.xml ${srcdir:=.}/task-priority_d.xml "--log=root.fmt:[%10.6r]%e(%i:%P@%h)%e%m%n" -> [ 0.000000] (1:test@Fafard) Hello! Running a task of size 7.6296e+07 with priority 1 -> [ 0.000000] (2:test@Fafard) Hello! Running a task of size 7.6296e+07 with priority 2 -> [ 1.500000] (2:test@Fafard) Goodbye now! -> [ 2.000000] (0:maestro@) Simulation time 2 -> [ 2.000000] (1:test@Fafard) Goodbye now! diff --git a/teshsuite/msg/task-priority/task-priority_d.xml b/teshsuite/msg/task-priority/task-priority_d.xml deleted file mode 100644 index c82c90668c..0000000000 --- a/teshsuite/msg/task-priority/task-priority_d.xml +++ /dev/null @@ -1,12 +0,0 @@ - - - - - - - - - - - - -- 2.20.1