summaryrefslogtreecommitdiff
path: root/src/cpu/o3/fetch_impl.hh
diff options
context:
space:
mode:
authorMitch Hayenga <mitch.hayenga@arm.com>2014-09-09 04:36:34 -0400
committerMitch Hayenga <mitch.hayenga@arm.com>2014-09-09 04:36:34 -0400
commitcd1bd7572aeb49f55ea9071a73ba1e322fb2487b (patch)
tree357bb0d56ac3b5142117d25131952988257d143a /src/cpu/o3/fetch_impl.hh
parent9a595fac74a0ac1c169f24f3156a922cd5c46a4b (diff)
downloadgem5-cd1bd7572aeb49f55ea9071a73ba1e322fb2487b.tar.xz
cpu: Only iterate over possible threads on the o3 cpu
Some places in O3 always iterated over "Impl::MaxThreads" even if a CPU had fewer threads. This removes a few of those instances.
Diffstat (limited to 'src/cpu/o3/fetch_impl.hh')
-rw-r--r--src/cpu/o3/fetch_impl.hh6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cpu/o3/fetch_impl.hh b/src/cpu/o3/fetch_impl.hh
index e20d2970a..fb933b8ca 100644
--- a/src/cpu/o3/fetch_impl.hh
+++ b/src/cpu/o3/fetch_impl.hh
@@ -419,7 +419,7 @@ template <class Impl>
void
DefaultFetch<Impl>::drainResume()
{
- for (ThreadID i = 0; i < Impl::MaxThreads; ++i)
+ for (ThreadID i = 0; i < numThreads; ++i)
stalls[i].drain = false;
}
@@ -887,7 +887,7 @@ DefaultFetch<Impl>::tick()
wroteToTimeBuffer = false;
- for (ThreadID i = 0; i < Impl::MaxThreads; ++i) {
+ for (ThreadID i = 0; i < numThreads; ++i) {
issuePipelinedIfetch[i] = false;
}
@@ -927,7 +927,7 @@ DefaultFetch<Impl>::tick()
}
// Issue the next I-cache request if possible.
- for (ThreadID i = 0; i < Impl::MaxThreads; ++i) {
+ for (ThreadID i = 0; i < numThreads; ++i) {
if (issuePipelinedIfetch[i]) {
pipelineIcacheAccesses(i);
}