sstsimulator / sst-macro

SST Macro Element Library
http://sst-simulator.org/
Other
34 stars 41 forks source link

how to use routing table in sst-macro? #633

Closed chenglin-li closed 2 years ago

chenglin-li commented 2 years ago

New Issue for sst-macro

1 - Detailed description of problem or enhancement i want to use routing table in sst-macro, and i find there are examples (named "test_ping_all_tree_table.ini") in folder: /sstmacro-11.0.0/tests/test_configs, but when i run it, is has below error:

$ /home/samsung/local/bin/sstmac -f test_ping_all_tree_table.ini /home/samsung/local/bin/sstmac --debug="" \ --configfile="test_ping_all_file.ini" \

/home/samsung/local/bin/sstmac: caught exception while setting up simulation: [json.exception.type_error.304] cannot use at() with null

2 - Describe how to reproduce step 1: i find it does not specify topology file, so i add below in namespace topology : filename = testbed_topology.json step 2: run the test case again: $ /home/samsung/local/bin/sstmac -f test_ping_all_tree_table.ini /home/samsung/local/bin/sstmac --debug="" \ --configfile="test_ping_all_tree_table.ini" \ Segmentation fault (core dumped) step 3: i find there are router namespace, and it set name to table, but it does not configure routing table file.

       router {
    name = table
      }

i want to know how to configure routing table file? i tried below script, but it does not work.

router { name = table filename = testbed_rtr_tbl.json // this is routing table file }

the error is as below: /home/samsung/local/bin/sstmac: caught exception while setting up simulation: [json.exception.type_error.304] cannot use at() with null

3 - What Operating system(s) and versions Ubuntu 18.04

4 - What version of external libraries (Boost, MPI) i use SST Macro 11.0.0 version 5 - Provide sha1 of all relevant sst repositories (sst-core, sst-elements, etc) i use SST Macro 11.0.0 version 6 - Fill out Labels, Milestones, and Assignee fields as best possible

jpkenny commented 2 years ago

The following should work in 11.0.0:

router { name = table routing_tables = testbed_rtr_tbl.json }

The name of the parameter was changed from "filename" to "routing_tables" some time ago.

chenglin-li commented 2 years ago

thanks @jpkenny for quick response.

i tried the "routing_tables" keyword, but it still has errors: $ /home/samsung/local/bin/sstmac -f test_ping_all_file.ini /home/samsung/local/bin/sstmac --debug="" \ --configfile="test_ping_all_file.ini" \

TableRouter constructor begin! // the following is my added-log TableRouter file_topo=-770835152 TableRouter file_topo.maxNumPorts=9 TableRouter file_topo.maxSwitchId=3 TableRouter file_topo.maxNodeId=5 TableRouter json switch_ports= //the above is my added-log /home/samsung/local/bin/sstmac: caught exception while setting up simulation: [json.exception.type_error.304] cannot use at() with null

could you please help ?

i find topology file "file_topology1.json" need to be used with routing table file "rtr_tbl_file_topology1.json" together, they are in pair. i attched script file test_ping_all_file.ini as below:

node { app1 { indexing = block allocation = first_available name = mpi_ping_all launch_cmd = aprun -n 6 -N 2 start = 0ms message_size = 1KB } nic { name = pisces injection { mtu = 4096 bandwidth = 1.0GB/s latency = 50ns credits = 64KB arbitrator = cut_through } ejection { latency = 50ns } } memory { name = pisces total_bandwidth = 10GB/s latency = 10ns max_single_bandwidth = 10GB/s mtu = 1MB } proc { ncores = 4 frequency = 2GHz } model = simple }

switch { mtu = 4096 name = pisces arbitrator = cut_through link { bandwidth = 1.0GB/s latency = 100ns credits = 64KB } xbar { bandwidth = 1.0GB/s latency = 100ns } router { name = table

andy begin

routing_tables = rtr_tbl_file_topology1.json

andy end

} logp { bandwidth = 1GB/s out_in_latency = 100ns hop_latency = 100ns } }

topology { name = file

andy begin

filename = file_topology1.json

andy end

}

jpkenny commented 2 years ago

You just need to move the "routing_tables" keyval into topology. Totally logical for it to be in router, it in fact used to be there, but it was moved into topology a while back as an optimization for reading large files. Routers get constructed much more frequently than topologies.

chenglin-li commented 2 years ago

@jpkenny , thanks for your feedback, it works now. thank you very much.