There are many places checking all CMD types for delivery:
|
elif (s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU_CROSSBAR) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG_PROLOGUE_ROUTING_CROSSBAR) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG_TOTAL_CTRL_COUNT) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONFIG_COUNT_PER_ITER) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_CONST) | \ |
|
(s.recv_from_inter_cgra_noc.msg.payload.cmd == CMD_LAUNCH): |
|
if (s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU_CROSSBAR) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_PROLOGUE_ROUTING_CROSSBAR) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_LAUNCH) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_TERMINATE) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_PAUSE) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_TOTAL_CTRL_COUNT) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_COUNT_PER_ITER) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_CTRL_LOWER_BOUND) | \ |
|
(s.recv_pkt_queue.send.msg.payload.cmd == CMD_CONFIG_COUNT_PER_ITER): |
|
((s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG_PROLOGUE_FU_CROSSBAR) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG_PROLOGUE_ROUTING_CROSSBAR) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG_TOTAL_CTRL_COUNT) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_CONFIG_COUNT_PER_ITER) | \ |
|
(s.recv_from_controller_pkt.msg.payload.cmd == CMD_LAUNCH)): |
This is easy to fail/forget when we add new types. I think we can somehow check if not some_types to make it easier.
There are many places checking all CMD types for delivery:
VectorCGRA/controller/ControllerRTL.py
Lines 277 to 284 in ca33d73
VectorCGRA/mem/ctrl/CtrlMemDynamicRTL.py
Lines 122 to 132 in ca33d73
VectorCGRA/tile/TileRTL.py
Lines 235 to 241 in ca33d73
This is easy to fail/forget when we add new types. I think we can somehow check
if not some_typesto make it easier.