Ruby: have the rubytester pass contextId to Ruby.
authorLisa Hsu <Lisa.Hsu@amd.com>
Fri, 1 Apr 2011 00:17:51 +0000 (17:17 -0700)
committerLisa Hsu <Lisa.Hsu@amd.com>
Fri, 1 Apr 2011 00:17:51 +0000 (17:17 -0700)
src/cpu/testers/rubytest/Check.cc

index b536e22874762af373e25da94953742e9166a6d7..c0007cd98e48d974666ab5acea8c95bef559152a 100644 (file)
@@ -104,6 +104,7 @@ Check::initiatePrefetch()
     // Prefetches are assumed to be 0 sized
     Request *req = new Request(m_address.getAddress(), 0, flags, curTick(),
                                m_pc.getAddress());
+    req->setThreadContext(index, 0);
 
     PacketPtr pkt = new Packet(req, cmd, port->idx);
 
@@ -177,6 +178,7 @@ Check::initiateAction()
     Request *req = new Request(writeAddr.getAddress(), 1, flags, curTick(),
                                m_pc.getAddress());
 
+    req->setThreadContext(index, 0);
     Packet::Command cmd;
 
     // 1 out of 8 chance, issue an atomic rather than a write
@@ -242,6 +244,7 @@ Check::initiateCheck()
     Request *req = new Request(m_address.getAddress(), CHECK_SIZE, flags,
                                curTick(), m_pc.getAddress());
 
+    req->setThreadContext(index, 0);
     PacketPtr pkt = new Packet(req, MemCmd::ReadReq, port->idx);
     uint8_t* dataArray = new uint8_t[CHECK_SIZE];
     pkt->dataDynamicArray(dataArray);