ruby: improved support for functional accesses
Review Request #1443 - Created Sept. 24, 2012 and submitted
| Information | |
|---|---|
| Nilay Vaish | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 9302:f07b94c9f16e --------------------------- ruby: improved support for functional accesses This patch adds support to different entities in the ruby memory system for more reliable functional read/write accesses. Only the simple network has been augmented as of now. Later on Garnet will also support functional accesses. The patch adds functional access code to all the different types of messages that protocols can send around. These messages are functionally accessed by going through the buffers maintained by the network entities. The patch also rectifies some of the bugs found in coherence protocols while testing the patch. With this patch applied, functional writes always succeed. But functional reads can still fail.
Issue Summary
17
11
6
0
Posted (Sept. 26, 2012, 8:18 a.m.)
Seems fine to me. Anything on the testing?
Posted (Sept. 26, 2012, 2:21 p.m.)
I have a couple questions: - Why do you modify the msg.sm files? It seems unecessary. - How do you handle functional writes to message buffers no part of the network? As you already know, I'm in favor of just creating a list of message buffers by modifying the MessageBuffer constructor. After seeing the number of files you had to change with this existing patch, I'm further convinced that is the better approach. This current patch seems quite hackish, and adding this support to Garnet is only going to be uglier. What can I do to convince you that the MessageBuffer approach is better? Or in other words, can you explain exactly what you don't like about the MessageBuffer approach?
-
src/mem/protocol/MESI_CMP_directory-dir.sm (Diff revision 1) -
Whitespace change?
-
src/mem/ruby/slicc_interface/NetworkMessage.hh (Diff revision 1) -
Why don't you define and implement the functionalWrite function here in NetworkMessage. It seems unecessary to have to modify any .sm files.
Review request changed
Updated (Oct. 3, 2012, 2:12 p.m.)
Description: |
|
|||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+673 -82) |
Posted (Oct. 8, 2012, 3:32 a.m.)
-
src/mem/ruby/slicc_interface/RubySlicc_Util.hh (Diff revision 2) -
What is going on here? Please add comments to these two functions.
Review request changed
Updated (Oct. 8, 2012, 10:47 a.m.)
Summary: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Description: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Diff: |
Revision 3 (+760 -125) |
Posted (Oct. 9, 2012, 5:46 a.m.)
Thanks for the comments. This is much clearer. I only have one question below regarding the functional read logic.
-
src/mem/ruby/system/System.cc (Diff revision 3) -
Is there any reason you try the read the message buffers in this order? Also have you given up on trying to check if only one Maybe_Stale copy exists? It appears so, otherwise I would have expected you to check for a Maybe_Stale copy after going through all the message buffers.
Posted (Oct. 10, 2012, 5:50 p.m.)
-
src/mem/protocol/MESI_CMP_directory-L1cache.sm (Diff revision 3) -
Very minor...the others just have a one-liner return getCacheEntry(addr).DataBlk; Perhaps stick to the same?
-
src/mem/protocol/MESI_CMP_directory-msg.sm (Diff revision 3) -
A comment on what (or what is not) a coherence request of type PUTX?
-
src/mem/protocol/MESI_CMP_directory-msg.sm (Diff revision 3) -
Why is it not symmetric with the reads?
-
src/mem/protocol/MESI_CMP_directory-msg.sm (Diff revision 3) -
Same as previously, a short comment on why Data dataExclusive and memory data (what is data/mem data difference?).
-
src/mem/protocol/MESI_CMP_directory-msg.sm (Diff revision 3) -
Again, why the asymmetry with reads?
-
src/mem/ruby/buffers/MessageBuffer.hh (Diff revision 3) -
Why a pointer reference?
-
src/mem/ruby/buffers/MessageBuffer.hh (Diff revision 3) -
a const pointer ref? Why? Is it not possible that the write turns the packet into a response?
-
src/mem/ruby/buffers/MessageBuffer.cc (Diff revision 3) -
Could this be iterators as well? Feels a bit off to mix counter based and iterator based iteration.
-
src/mem/ruby/buffers/MessageBuffer.cc (Diff revision 3) -
Could there be order dependent behaviour here or somewhere else? The iteration over a map scares me quite a bit! In general, we should avoid it as the order is not defined.
-
src/mem/ruby/network/Network.hh (Diff revision 3) -
Not the same type as the other place...
-
src/mem/ruby/network/Network.hh (Diff revision 3) -
Not the same type (was const Packet*&)
-
src/mem/ruby/network/simple/SimpleNetwork.cc (Diff revision 3) -
now int and not size_t? an iterator would be even nicer to see
-
src/mem/ruby/slicc_interface/RubyRequest.cc (Diff revision 3) -
Just a note on the memtester...it is as far as I am concerned broken in its current implementation. The way it interacts with the shadow memory is too restrictive. The ordering model allows many more legal permutations than what we currently do by comparing with the functional memory. I'm not sure I would design for a broken memtest to pass.
Review request changed
Updated (Oct. 10, 2012, 8:47 p.m.)
Description: |
|
||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 4 (+768 -137) |
Review request changed
Updated (Oct. 15, 2012, 7:15 a.m.)
Description: |
|
||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 5 (+802 -138) |
Ship It!
