gem5-users@gem5.org

The gem5 Users mailing list

View all threads

new SimObject fails to send a response packet due to crossbar issue

IL
Iliass Lasri
Tue, Jul 16, 2024 7:18 PM

Hello gem5 community,

I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this :  pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt);

More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where.

So I don't really know where the problem can come from, thank you all for your help.

Iliass Lasri
Msc of Engineering Student at Télécom Paris

Hello gem5 community, I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this : pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt); More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where. So I don't really know where the problem can come from, thank you all for your help. Iliass Lasri Msc of Engineering Student at Télécom Paris
ST
Samuel Thomas
Tue, Jul 16, 2024 8:07 PM

Hi Iliass,

This error typically happens when the XBar receives a packet that it didn’t send to the SimObject as a response. Are you making a new response packet? If so, try using the pkt->makeTimingResponse() function to send the received packet directly back to the XBar.

Hopefully this helps.

Best,
Sam

On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users gem5-users@gem5.org wrote:

Hello gem5 community,

I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this :  pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt);

More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where.

So I don't really know where the problem can come from, thank you all for your help.

Iliass Lasri
Msc of Engineering Student at Télécom Paris


gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-leave@gem5.org

Hi Iliass, This error typically happens when the XBar receives a packet that it didn’t send to the SimObject as a response. Are you making a new response packet? If so, try using the pkt->makeTimingResponse() function to send the received packet directly back to the XBar. Hopefully this helps. Best, Sam > On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users <gem5-users@gem5.org> wrote: > > > Hello gem5 community, > > I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this : pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt); > > More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where. > > So I don't really know where the problem can come from, thank you all for your help. > > Iliass Lasri > Msc of Engineering Student at Télécom Paris > _______________________________________________ > gem5-users mailing list -- gem5-users@gem5.org > To unsubscribe send an email to gem5-users-leave@gem5.org
IL
Iliass Lasri
Tue, Jul 16, 2024 8:17 PM

Hello Sam,

Thanks for your response. Actually, I did exactly what you said pkt->makeTimingResponse(), and pkt->setData(&value). And when debugging I follow the packet and the attribute pkt->req don't change, so logically the crossbar should have the proper routing, but it's not the case. Do you have any other ideas, where this problem can come from.

Thanks again for your help, I appreciate it.
Iliass

----- Mail original -----
De: "Samuel Thomas" samuel_thomas@brown.edu
À: "gem5 users mailing list" gem5-users@gem5.org
Cc: "Iliass Lasri" iliass.lasri@telecom-paris.fr
Envoyé: Mardi 16 Juillet 2024 22:07:32
Objet: Re: [gem5-users] new SimObject fails to send a response packet due to crossbar issue

Hi Iliass,

This error typically happens when the XBar receives a packet that it didn’t send to the SimObject as a response. Are you making a new response packet? If so, try using the pkt->makeTimingResponse() function to send the received packet directly back to the XBar.

Hopefully this helps.

Best,
Sam

On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users gem5-users@gem5.org wrote:

Hello gem5 community,

I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this :  pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt);

More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where.

So I don't really know where the problem can come from, thank you all for your help.

Iliass Lasri
Msc of Engineering Student at Télécom Paris


gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-leave@gem5.org

Hello Sam, Thanks for your response. Actually, I did exactly what you said pkt->makeTimingResponse(), and pkt->setData(&value). And when debugging I follow the packet and the attribute pkt->req don't change, so logically the crossbar should have the proper routing, but it's not the case. Do you have any other ideas, where this problem can come from. Thanks again for your help, I appreciate it. Iliass ----- Mail original ----- De: "Samuel Thomas" <samuel_thomas@brown.edu> À: "gem5 users mailing list" <gem5-users@gem5.org> Cc: "Iliass Lasri" <iliass.lasri@telecom-paris.fr> Envoyé: Mardi 16 Juillet 2024 22:07:32 Objet: Re: [gem5-users] new SimObject fails to send a response packet due to crossbar issue Hi Iliass, This error typically happens when the XBar receives a packet that it didn’t send to the SimObject as a response. Are you making a new response packet? If so, try using the pkt->makeTimingResponse() function to send the received packet directly back to the XBar. Hopefully this helps. Best, Sam > On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users <gem5-users@gem5.org> wrote: > > > Hello gem5 community, > > I created a new SimObject that does just like the memory, the object has a Response port when it recieves a read command it sends a ReadResponse, but when it arrives to the xbar, the xbar fails to route it, and the assersion in line 454 in coherent_xbar.cc _assert(route_lookup != routeTo.end()); fails, however While debugging I made sure to have to send a Response packet and I just modify the data like this : pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt); > > More details : I just write a C code reading from the address I assigned to the module and the Request packet arrives to the new object and the REsponse packet succesufly leaves the new object and get to the xbar. the problem is just with the routing in the xbar, knowimg that I don't modify pkt->req, used by the xbar to remember the reauest came from where. > > So I don't really know where the problem can come from, thank you all for your help. > > Iliass Lasri > Msc of Engineering Student at Télécom Paris > _______________________________________________ > gem5-users mailing list -- gem5-users@gem5.org > To unsubscribe send an email to gem5-users-leave@gem5.org
KS
Khan Shaikhul Hadi
Tue, Jul 16, 2024 11:08 PM

Hi,
please check when coherent_xbar receive the request, before sending it
downstream to your new object, the packet is expected to have response and
not express snoop so that "bool expect_response = pkt->needsResponse() && !
pkt->cacheResponding();"  this line set expect_response to zero which
should control the execution flow as such it creates routeTo entry.
It could be possible that your code is not creating routeTo requests in the
first place.
Another possible reason is that your system is sending two responses ( have
no idea how this could happen) and thus the second response could not find
any routTo entry as the first response deleted that entry.

On Tue, Jul 16, 2024 at 5:36 PM Iliass Lasri via gem5-users <
gem5-users@gem5.org> wrote:

Hello Sam,

Thanks for your response. Actually, I did exactly what you said
pkt->makeTimingResponse(), and pkt->setData(&value). And when debugging I
follow the packet and the attribute pkt->req don't change, so logically the
crossbar should have the proper routing, but it's not the case. Do you have
any other ideas, where this problem can come from.

Thanks again for your help, I appreciate it.
Iliass

----- Mail original -----
De: "Samuel Thomas" samuel_thomas@brown.edu
À: "gem5 users mailing list" gem5-users@gem5.org
Cc: "Iliass Lasri" iliass.lasri@telecom-paris.fr
Envoyé: Mardi 16 Juillet 2024 22:07:32
Objet: Re: [gem5-users] new SimObject fails to send a response packet due
to crossbar issue

Hi Iliass,

This error typically happens when the XBar receives a packet that it
didn’t send to the SimObject as a response. Are you making a new response
packet? If so, try using the pkt->makeTimingResponse() function to send the
received packet directly back to the XBar.

Hopefully this helps.

Best,
Sam

On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users <

Hello gem5 community,

I created a new SimObject that does just like the memory, the object has

a Response port when it recieves a read command it sends a ReadResponse,
but when it arrives to the xbar, the xbar fails to route it, and the
assersion in line 454 in coherent_xbar.cc _assert(route_lookup !=
routeTo.end()); fails, however While debugging I made sure to have to send
a Response packet and I just modify the data like this :
pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt);

More details : I just write a C code reading from the address I assigned

to the module and the Request packet arrives to the new object and the
REsponse packet succesufly leaves the new object and get to the xbar. the
problem is just with the routing in the xbar, knowimg that I don't modify
pkt->req, used by the xbar to remember the reauest came from where.

So I don't really know where the problem can come from, thank you all

for your help.

Iliass Lasri
Msc of Engineering Student at Télécom Paris


gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-leave@gem5.org


gem5-users mailing list -- gem5-users@gem5.org
To unsubscribe send an email to gem5-users-leave@gem5.org

Hi, please check when coherent_xbar receive the request, before sending it downstream to your new object, the packet is expected to have response and not express snoop so that "bool expect_response = pkt->needsResponse() && ! pkt->cacheResponding();" this line set expect_response to zero which should control the execution flow as such it creates routeTo entry. It could be possible that your code is not creating routeTo requests in the first place. Another possible reason is that your system is sending two responses ( have no idea how this could happen) and thus the second response could not find any routTo entry as the first response deleted that entry. On Tue, Jul 16, 2024 at 5:36 PM Iliass Lasri via gem5-users < gem5-users@gem5.org> wrote: > Hello Sam, > > Thanks for your response. Actually, I did exactly what you said > pkt->makeTimingResponse(), and pkt->setData(&value). And when debugging I > follow the packet and the attribute pkt->req don't change, so logically the > crossbar should have the proper routing, but it's not the case. Do you have > any other ideas, where this problem can come from. > > Thanks again for your help, I appreciate it. > Iliass > > ----- Mail original ----- > De: "Samuel Thomas" <samuel_thomas@brown.edu> > À: "gem5 users mailing list" <gem5-users@gem5.org> > Cc: "Iliass Lasri" <iliass.lasri@telecom-paris.fr> > Envoyé: Mardi 16 Juillet 2024 22:07:32 > Objet: Re: [gem5-users] new SimObject fails to send a response packet due > to crossbar issue > > Hi Iliass, > > This error typically happens when the XBar receives a packet that it > didn’t send to the SimObject as a response. Are you making a new response > packet? If so, try using the pkt->makeTimingResponse() function to send the > received packet directly back to the XBar. > > Hopefully this helps. > > Best, > Sam > > > On Jul 16, 2024, at 3:18 PM, Iliass Lasri via gem5-users < > gem5-users@gem5.org> wrote: > > > > > > Hello gem5 community, > > > > I created a new SimObject that does just like the memory, the object has > a Response port when it recieves a read command it sends a ReadResponse, > but when it arrives to the xbar, the xbar fails to route it, and the > assersion in line 454 in coherent_xbar.cc _assert(route_lookup != > routeTo.end()); fails, however While debugging I made sure to have to send > a Response packet and I just modify the data like this : > pkt->setData(&value); pkt->makeResponse(); port.sendTimingResp(pkt); > > > > More details : I just write a C code reading from the address I assigned > to the module and the Request packet arrives to the new object and the > REsponse packet succesufly leaves the new object and get to the xbar. the > problem is just with the routing in the xbar, knowimg that I don't modify > pkt->req, used by the xbar to remember the reauest came from where. > > > > So I don't really know where the problem can come from, thank you all > for your help. > > > > Iliass Lasri > > Msc of Engineering Student at Télécom Paris > > _______________________________________________ > > gem5-users mailing list -- gem5-users@gem5.org > > To unsubscribe send an email to gem5-users-leave@gem5.org > _______________________________________________ > gem5-users mailing list -- gem5-users@gem5.org > To unsubscribe send an email to gem5-users-leave@gem5.org >