Bus: Split the bus into a non-coherent and coherent bus
Review Request #1223 - Created May 25, 2012 and submitted
| Information | |
|---|---|
| Andreas Hansson | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Changeset 9034:b5b92099f4c9 --------------------------- Bus: Split the bus into a non-coherent and coherent bus This patch introduces a class hierarchy of buses, a non-coherent one, and a coherent one, splitting the existing bus functionality. By doing so it also enables further specialisation of the two types of buses. A non-coherent bus connects a number of non-snooping masters and slaves, and routes the request and response packets based on the address. The request packets issued by the master connected to a non-coherent bus could still snoop in caches attached to a coherent bus, as is the case with the I/O bus and memory bus in most system configurations. No snoops will, however, reach any master on the non-coherent bus itself. The non-coherent bus can be used as a template for modelling PCI, PCIe, and non-coherent AMBA and OCP buses, and is typically used for the I/O buses. A coherent bus connects a number of (potentially) snooping masters and slaves, and routes the request and response packets based on the address, and also forwards all requests to the snoopers and deals with the snoop responses. The coherent bus can be used as a template for modelling QPI, HyperTransport, ACE and coherent OCP buses, and is typically used for the L1-to-L2 buses and as the main system interconnect. The configuration scripts are updated to use a NoncoherentBus for all peripheral and I/O buses. A bit of minor tidying up has also been done.
util/regress all passing (disregarding t1000 and eio)
Posted (May 25, 2012, 2:49 a.m.)
Seems reasonable, although there doesn't seem to be much code shared between the two buses. Mabye there just isn't much similar functionality? I'd like steve to sign off before committing.
Looks OK to me. I can see where a common BaseBus class would clean up the constructor situation a bit, and I think would allow some of the NoncoherentBus-only bits like the ports to be more cleanly separated. If you're up for it, Andreas, you might want to give it a try. It's not unreasonable as it stands though. Comments below are orthogonal to the patch, just because I noticed this code for the first time.
-
src/mem/noncoherent_bus.cc (Diff revision 1) -
I see this code isn't new, but I never noticed it before... does anything actually work if connected devices don't all have the same block size? I'm just concerned that this code gives the impression that there's more flexibility than actually exists.
-
src/mem/noncoherent_bus.cc (Diff revision 1) -
On the other hand, this warning seems overly conservative... other block sizes should work fine as long as *everyone* uses the same size.
Review request changed
Updated (May 29, 2012, 4:03 a.m.)
Description: |
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Diff: |
Revision 2 (+1353 -755) |
Thanks! I didn't have a chance to go over it in detail, but it looks good to me.
