m_virtual_networks = p->number_of_virtual_networks;
m_control_msg_size = p->control_msg_size;
+ fatal_if(p->data_msg_size > p->ruby_system->getBlockSizeBytes(),
+ "%s: data message size > cache line size", name());
+ m_data_msg_size = p->data_msg_size + m_control_msg_size;
+
params()->ruby_system->registerNetwork(this);
// Populate localNodeVersions with the version of each MachineType in
delete m_topology_ptr;
}
-void
-Network::init()
-{
- m_data_msg_size = RubySystem::getBlockSizeBytes() + m_control_msg_size;
-}
-
uint32_t
Network::MessageSizeType_to_int(MessageSizeType size_type)
{
{ return dynamic_cast<const Params *>(_params); }
virtual ~Network();
- void init() override;
static uint32_t getNumberOfVirtualNetworks() { return m_virtual_networks; }
int getNumNodes() const { return m_nodes; }
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
from m5.params import *
+from m5.proxy import *
from m5.objects.ClockedObject import ClockedObject
from m5.objects.BasicLink import BasicLink
slave = DeprecatedParam(in_port, '`slave` is now called `in_port`')
out_port = VectorRequestPort("CPU output port")
master = DeprecatedParam(out_port, '`master` is now called `out_port`')
+
+ data_msg_size = Param.Int(Parent.block_size_bytes,
+ "Size of data messages. Defaults to the parent "
+ "RubySystem cache line size.")
+