From 8615b27174ae06db4665016c877b1e88031af203 Mon Sep 17 00:00:00 2001 From: Mitch Hayenga Date: Tue, 5 Apr 2016 12:39:21 -0500 Subject: mem: Remove threadId from memory request class In general, the ThreadID parameter is unnecessary in the memory system as the ContextID is what is used for the purposes of locks/wakeups. Since we allocate sequential ContextIDs for each thread on MT-enabled CPUs, ThreadID is unnecessary as the CPUs can identify the requesting thread through sideband info (SenderState / LSQ entries) or ContextID offset from the base ContextID for a cpu. --- src/cpu/o3/lsq.hh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/cpu/o3/lsq.hh') diff --git a/src/cpu/o3/lsq.hh b/src/cpu/o3/lsq.hh index dcd676221..6bc9b3d73 100644 --- a/src/cpu/o3/lsq.hh +++ b/src/cpu/o3/lsq.hh @@ -334,7 +334,7 @@ Fault LSQ::read(RequestPtr req, RequestPtr sreqLow, RequestPtr sreqHigh, int load_idx) { - ThreadID tid = req->threadId(); + ThreadID tid = cpu->contextToThread(req->contextId()); return thread[tid].read(req, sreqLow, sreqHigh, load_idx); } @@ -344,7 +344,7 @@ Fault LSQ::write(RequestPtr req, RequestPtr sreqLow, RequestPtr sreqHigh, uint8_t *data, int store_idx) { - ThreadID tid = req->threadId(); + ThreadID tid = cpu->contextToThread(req->contextId()); return thread[tid].write(req, sreqLow, sreqHigh, data, store_idx); } -- cgit v1.2.3