changeset 7f67a8d786a2 in /z/repo/gem5
details: http://repo.gem5.org/gem5?cmd=changeset;node=7f67a8d786a2
description:
        cpu: Add a PC-value to the traffic generator requests

        Have the traffic generator add its masterID as the PC address to the
        requests. That way, prefetchers (and other components) that use a PC
        for request classification will see per-tester streams of requests.
        This enables us to test strided prefetchers with the memchecker, too.

diffstat:

 src/cpu/testers/traffic_gen/generators.cc |  3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diffs (13 lines):

diff -r 9b71309d29f9 -r 7f67a8d786a2 src/cpu/testers/traffic_gen/generators.cc
--- a/src/cpu/testers/traffic_gen/generators.cc Mon Mar 02 04:00:29 2015 -0500
+++ b/src/cpu/testers/traffic_gen/generators.cc Mon Mar 02 04:00:31 2015 -0500
@@ -57,6 +57,9 @@
 {
     // Create new request
     Request *req = new Request(addr, size, flags, masterID);
+    // Dummy PC to have PC-based prefetchers latch on; get entropy into higher
+    // bits
+    req->setPC(((Addr)masterID) << 2);
 
     // Embed it in a packet
     PacketPtr pkt = new Packet(req, cmd);
_______________________________________________
gem5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/gem5-dev

Reply via email to