Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
move the vanilla def of executeParallelTask in HostModel
[simgrid.git] / src / surf / surf_routing_none.cpp
1 /* Copyright (c) 2009-2011, 2013-2015. The SimGrid Team.
2  * All rights reserved.                                                     */
3
4 /* This program is free software; you can redistribute it and/or modify it
5  * under the terms of the license (GNU LGPL) which comes with this package. */
6
7 #include "src/surf/surf_routing_private.hpp"
8 #include "src/surf/surf_routing_none.hpp"
9
10 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(surf_route_none, surf, "Routing part of surf");
11
12 AS_t model_none_create(void)
13 {
14   return new simgrid::surf::AsNone();
15 }
16
17 namespace simgrid {
18 namespace surf {
19
20 xbt_dynar_t AsNone::getOneLinkRoutes() {
21   return NULL;
22 }
23
24 void AsNone::getRouteAndLatency(NetCard * /*src*/, NetCard * /*dst*/,
25                                 sg_platf_route_cbarg_t /*res*/, double *lat)
26 {
27   *lat = 0.0;
28 }
29
30 void AsNone::getGraph(xbt_graph_t /*graph*/, xbt_dict_t /*nodes*/, xbt_dict_t /*edges*/)
31 {
32         XBT_INFO("No routing no graph");
33 }
34
35 sg_platf_route_cbarg_t AsNone::getBypassRoute(NetCard * /*src*/, NetCard * /*dst*/, double * /*lat*/) {
36   return NULL;
37 }
38
39 int AsNone::parsePU(NetCard *elm) {
40   XBT_DEBUG("Load process unit \"%s\"", elm->getName());
41   xbt_dynar_push_as(p_indexNetworkElm, NetCard*, elm);
42   /* don't care about PUs */
43   return -1;
44 }
45
46 int AsNone::parseAS(NetCard *elm) {
47   XBT_DEBUG("Load Autonomous system \"%s\"", elm->getName());
48   xbt_dynar_push_as(p_indexNetworkElm, NetCard*, elm);
49   /* even don't care about sub-ASes -- I'm as nihilist as an old punk*/
50   return -1;
51 }
52
53 void AsNone::parseRoute(sg_platf_route_cbarg_t /*route*/){
54   THROW_IMPOSSIBLE; /* No. */
55 }
56
57 void AsNone::parseASroute(sg_platf_route_cbarg_t /*route*/){
58   THROW_IMPOSSIBLE;
59 }
60 void AsNone::parseBypassroute(sg_platf_route_cbarg_t /*e_route*/){
61   THROW_IMPOSSIBLE;
62 }
63
64 }
65 }