Hi Nilay and Tushar, Thanks for your response. I thought so earlier but I tried running pure memory test (e.g. ruby_mem_test.py) as well as ruby_random_test. Shouldn't the memory test inject only memory request packets in the network? In that case why should the type cast fail? Please correct me if I am wrong. Is there any way of determining whether a flit corresponds to a memory message or a network message?
I am using this command line to run the test ./build/ALPHA_SE_MOESI_hammer/gem5.debug configs/example/ruby_random_test.py --num-cpus=4 --num-dirs=4 --topology=Mesh --mesh-rows=2 --garnet-network=fixed -l 100 ./build/ALPHA_SE_MOESI_hammer/gem5.debug configs/example/ruby_mem_test.py --num-cpus=4 --num-dirs=4 --topology=Mesh --mesh-rows=2 --garnet-network=fixed -l 100 Looking forward to your guidance. Thanks! On Wed, Sep 26, 2012 at 8:39 AM, Nilay Vaish <ni...@cs.wisc.edu> wrote: > If the Message* is not a MemoryMsg*, then safe cast will fail. > > -- > Nilay > > > > On Wed, 26 Sep 2012, Tushar Krishna wrote: > > Hi Tejasi, >> I tried it too and yeah it fails, not sure why... >> The same code works in src/mem/ruby/system/**RubyMemoryControl.cc >> A cast into NetworkMessage has been done in places like RoutingUnit_d but >> that won't give you the message type. >> You'll have to dig in and see why the cast fails… >> >> - Tushar >> >> On Sep 26, 2012, at 2:17 AM, tejasi pimpalkhute wrote: >> >> Hi Tushar, >>> >>> I had resumed working on this again, so was going through your >>> emails(please see email below). I am still getting this error: >>> >>> gem5.debug: build/ALPHA_SE_MOESI_hammer/**base/cast.hh:49: T >>> safe_cast(U) [with T = const MemoryMsg*, U = Message*]: Assertion `ret' >>> failed. >>> Program aborted at cycle 10 >>> Aborted >>> >>> My code looks like this in SWallocator.cc file(I have included all the >>> necessary files) in the arbitrate_outports() function: >>> >>> flit_d *t_flit = m_input_unit[inport]->**peekTopFlit(invc); >>> >>> MsgPtr msg_ptr = t_flit->get_msg_ptr(); >>> >>> const MemoryMsg* memMess = safe_cast<const MemoryMsg*>(msg_ptr.get()); >>> >>> physical_address_t addr = memMess->getAddress().**getAddress(); >>> MemoryRequestType type = memMess->getType(); >>> >>> However, the typecast fails. Could you please let me know what could be >>> the problem here? I just want to extract the information from the flit if >>> it is a memory message or network message and if it is memory message, I >>> want to know its physical address and memory request type (e.g. read/write, >>> etc). Can you please suggest the correct way of getting this information >>> from the flit? >>> >>> I appreciate your guidance. >>> >>> Thanks! >>> >>> > _______________________________________________ > gem5-users mailing list > gem5-users@gem5.org > http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users >
_______________________________________________ gem5-users mailing list gem5-users@gem5.org http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users