X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/bc5903068a99bfc50a9f7a479cc3305326f774e9..f76533fa77b5013433976d12be12dd1ff71cf20a:/src/surf/network_cm02.cpp diff --git a/src/surf/network_cm02.cpp b/src/surf/network_cm02.cpp index e34e829965..b80ddfd255 100644 --- a/src/surf/network_cm02.cpp +++ b/src/surf/network_cm02.cpp @@ -1,3 +1,9 @@ +/* Copyright (c) 2013-2014. 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 "network_cm02.hpp" #include "maxmin_private.hpp" #include "simgrid/sg_config.h" @@ -372,12 +378,12 @@ ActionPtr NetworkCm02Model::communicate(RoutingEdgePtr src, RoutingEdgePtr dst, xbt_dynar_t route = xbt_dynar_new(sizeof(RoutingEdgePtr), NULL); - XBT_IN("(%s,%s,%g,%g)", src->p_name, dst->p_name, size, rate); + XBT_IN("(%s,%s,%g,%g)", src->getName(), dst->getName(), size, rate); routing_platf->getRouteAndLatency(src, dst, &route, &latency); xbt_assert(!xbt_dynar_is_empty(route) || latency, "You're trying to send data from %s to %s but there is no connection at all between these two hosts.", - src->p_name, dst->p_name); + src->getName(), dst->getName()); xbt_dynar_foreach(route, i, _link) { link = static_cast(_link); @@ -434,7 +440,7 @@ ActionPtr NetworkCm02Model::communicate(RoutingEdgePtr src, RoutingEdgePtr dst, link = *static_cast(xbt_dynar_get_ptr(route, 0)); gapAppend(size, link, action); XBT_DEBUG("Comm %p: %s -> %s gap=%f (lat=%f)", - action, src->p_name, dst->p_name, action->m_senderGap, + action, src->getName(), dst->getName(), action->m_senderGap, action->m_latency); } @@ -624,10 +630,10 @@ void NetworkCm02Action::updateRemainingLazy(double now) delta = now - m_lastUpdate; if (m_remains > 0) { - XBT_DEBUG("Updating action(%p): remains was %lf, last_update was: %lf", this, m_remains, m_lastUpdate); + XBT_DEBUG("Updating action(%p): remains was %f, last_update was: %f", this, m_remains, m_lastUpdate); double_update(&(m_remains), m_lastValue * delta); - XBT_DEBUG("Updating action(%p): remains is now %lf", this, m_remains); + XBT_DEBUG("Updating action(%p): remains is now %f", this, m_remains); } if (m_maxDuration != NO_MAX_DURATION)