bug fix
Some checks failed
CI / Ubuntu (push) Has been cancelled
CI / Codecov (push) Has been cancelled
CI / Windows_MinGW (push) Has been cancelled
CI / Mac_OS_X (macos-14) (push) Has been cancelled
CI / Mac_OS_X (macos-latest) (push) Has been cancelled
CI / Windows_Visual_Studio (push) Has been cancelled
Some checks failed
CI / Ubuntu (push) Has been cancelled
CI / Codecov (push) Has been cancelled
CI / Windows_MinGW (push) Has been cancelled
CI / Mac_OS_X (macos-14) (push) Has been cancelled
CI / Mac_OS_X (macos-latest) (push) Has been cancelled
CI / Windows_Visual_Studio (push) Has been cancelled
This commit is contained in:
@@ -138,10 +138,16 @@ MultithreadedSimulatorImpl::ScheduleWithContext(uint32_t context,
|
|||||||
EventImpl* event)
|
EventImpl* event)
|
||||||
{
|
{
|
||||||
NS_LOG_FUNCTION(this << context << delay.GetTimeStep() << event);
|
NS_LOG_FUNCTION(this << context << delay.GetTimeStep() << event);
|
||||||
const bool useSaved = (context < m_savedNodeList.GetN());
|
LogicalProcess* remote = nullptr;
|
||||||
Ptr<Node> node = useSaved ? m_savedNodeList.Get(context) : NodeList::GetNode(context);
|
if (m_savedNodeList.GetN() > context)
|
||||||
LogicalProcess* remote = MtpInterface::GetSystem(node->GetSystemId());
|
{
|
||||||
remote->ScheduleWithContext(remote, context, delay, event);
|
remote = MtpInterface::GetSystem(m_savedNodeList.Get(context)->GetSystemId());
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
remote = MtpInterface::GetSystem(NodeList::GetNode(context)->GetSystemId());
|
||||||
|
}
|
||||||
|
MtpInterface::GetSystem()->ScheduleWithContext(remote, context, delay, event);
|
||||||
}
|
}
|
||||||
|
|
||||||
EventId
|
EventId
|
||||||
@@ -301,7 +307,7 @@ MultithreadedSimulatorImpl::Partition()
|
|||||||
NS_LOG_FUNCTION(this);
|
NS_LOG_FUNCTION(this);
|
||||||
uint32_t systemId = 0;
|
uint32_t systemId = 0;
|
||||||
const NodeContainer nodes = NodeContainer::GetGlobal();
|
const NodeContainer nodes = NodeContainer::GetGlobal();
|
||||||
m_savedNodeList = NodeContainer::GetGlobal();
|
m_savedNodeList = nodes;
|
||||||
bool* visited = new bool[nodes.GetN()]{false};
|
bool* visited = new bool[nodes.GetN()]{false};
|
||||||
std::queue<Ptr<Node>> q;
|
std::queue<Ptr<Node>> q;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user