diff options
author | Nilay Vaish <nilay@cs.wisc.edu> | 2013-01-14 10:04:21 -0600 |
---|---|---|
committer | Nilay Vaish <nilay@cs.wisc.edu> | 2013-01-14 10:04:21 -0600 |
commit | cf232de4615f0fe9435d6e92a1d6319c972a8c88 (patch) | |
tree | 539c365baf0b078b2fdbf820feeb89c1afee8726 /src/mem/protocol | |
parent | cbbc4c7f6b4cb718cc3907b955f7ae527d2d0274 (diff) | |
download | gem5-cf232de4615f0fe9435d6e92a1d6319c972a8c88.tar.xz |
Ruby: use ClockedObject in Consumer class
Many Ruby structures inherit from the Consumer, which is used for scheduling
events. The Consumer used to relay on an Event Manager for scheduling events
and on g_system_ptr for time. With this patch, the Consumer will now use a
ClockedObject to schedule events and to query for current time. This resulted
in several structures being converted from SimObjects to ClockedObjects. Also,
the MessageBuffer class now requires a pointer to a ClockedObject so as to
query for time.
Diffstat (limited to 'src/mem/protocol')
-rw-r--r-- | src/mem/protocol/RubySlicc_Profiler.sm | 2 | ||||
-rw-r--r-- | src/mem/protocol/RubySlicc_Types.sm | 3 |
2 files changed, 2 insertions, 3 deletions
diff --git a/src/mem/protocol/RubySlicc_Profiler.sm b/src/mem/protocol/RubySlicc_Profiler.sm index 50fe41fe5..64f643054 100644 --- a/src/mem/protocol/RubySlicc_Profiler.sm +++ b/src/mem/protocol/RubySlicc_Profiler.sm @@ -47,4 +47,4 @@ void profile_outstanding_persistent_request(int outstanding); void profile_average_latency_estimate(int latency); // profile the total message delay of a message across a virtual network -void profileMsgDelay(int virtualNetwork, int delayCycles); +void profileMsgDelay(int virtualNetwork, Time delayCycles); diff --git a/src/mem/protocol/RubySlicc_Types.sm b/src/mem/protocol/RubySlicc_Types.sm index 20249942a..b4601e9e6 100644 --- a/src/mem/protocol/RubySlicc_Types.sm +++ b/src/mem/protocol/RubySlicc_Types.sm @@ -36,13 +36,12 @@ // external_type(MessageBuffer, buffer="yes", inport="yes", outport="yes"); - external_type(OutPort, primitive="yes"); structure(InPort, external = "yes", primitive="yes") { bool isReady(); void dequeue(); - int dequeue_getDelayCycles(); + Time dequeue_getDelayCycles(); void recycle(); bool isEmpty(); } |