cpu: Switch off of the CPU's comInstEventQueue.

This switches to letting the ThreadContexts use a thread based/local
comInstEventQueue instead of falling back to the CPU's array. Because
the implementation is no longer shared and it's not given where the
comInstEventQueue (or other implementation) should be accessed, the
default implementation has been removed.

Also, because nobody is using the CPU's array of event queues, those
have been removed.

Change-Id: I515e6e00a2174067a928c33ef832bc5c840bdf7f
Reviewed-on: https://gem5-review.googlesource.com/c/public/gem5/+/22110
Reviewed-by: Andreas Sandberg <andreas.sandberg@arm.com>
Maintainer: Andreas Sandberg <andreas.sandberg@arm.com>
Tested-by: kokoro <noreply+kokoro@google.com>
This commit is contained in:
Gabe Black
2019-10-13 23:40:04 -07:00
parent a2a8dac5c2
commit 272a43175f
10 changed files with 106 additions and 61 deletions

View File

@@ -55,41 +55,6 @@
#include "params/BaseCPU.hh"
#include "sim/full_system.hh"
Tick
ThreadContext::nextInstEventCount()
{
auto *queue = getCpuPtr()->comInstEventQueue[threadId()];
return queue->empty() ? MaxTick : queue->nextTick();
}
void
ThreadContext::serviceInstCountEvents(Tick count)
{
auto *queue = getCpuPtr()->comInstEventQueue[threadId()];
queue->serviceEvents(count);
}
void
ThreadContext::scheduleInstCountEvent(Event *event, Tick count)
{
auto *queue = getCpuPtr()->comInstEventQueue[threadId()];
return queue->schedule(event, count);
}
void
ThreadContext::descheduleInstCountEvent(Event *event)
{
auto *queue = getCpuPtr()->comInstEventQueue[threadId()];
queue->deschedule(event);
}
Tick
ThreadContext::getCurrentInstCount()
{
auto *queue = getCpuPtr()->comInstEventQueue[threadId()];
return queue->getCurTick();
}
void
ThreadContext::compare(ThreadContext *one, ThreadContext *two)
{