Config: Exit with fatal if a port is already connected
Review Request #1206 - Created May 18, 2012 and submitted
| Information | |
|---|---|
| Andreas Hansson | |
| gem5 | |
| default | |
| Reviewers | |
| Default | |
Config: Exit with fatal if a port is already connected This patch turns the existing warning into a fatal, as there should never be any cases where a (non-vector) port is assigned to and then later connected to something else. If this behaviour is allowed, as it used to be, there are cases where the wrong number of C++ ports are created when instantiating objects with VectorPorts (obviously that could be fixed, but the better approach is to simply not allow it).
util/regress all passing (disregarding t1000 and eio)
Posted (May 20, 2012, 12:57 a.m.)
hmm.. do we want to do it this way, or fix the issue? It seems like there may be value in allowing the configuration to change before it's instantiated (e.g create a perfectly workable system with only l1s and the later on decide you want to wedge in an l2).
If overwrites of ports are currently causing problems, then I think the fatal error is appropriate. If we decide to go with a scheme like Ali is proposing, we'll have to fix the overwrite behavior anyway, and at that point we can get rid of the error message.
Ship It!
