Skip to content

Commit

Permalink
Merge Pull Request #2433 from jpkenny/sst-elements/hg-mtu
Browse files Browse the repository at this point in the history
Automatically Merged using SST Pull Request AutoTester
PR Title: b'Mercury: parameter clean-up'
PR Author: jpkenny
  • Loading branch information
sst-autotester authored Dec 20, 2024
2 parents 545438c + a2dad38 commit 659211a
Show file tree
Hide file tree
Showing 12 changed files with 35 additions and 25 deletions.
2 changes: 1 addition & 1 deletion src/sst/elements/iris/sumi/sim_transport.cc
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ SimTransport::SimTransport(SST::Params& params, SST::Hg::App* parent) :
rdma_pin_latency_ = TimeDelta(params.find<SST::UnitAlgebra>("rdma_pin_latency", "0s").getValue().toDouble());
rdma_page_delay_ = TimeDelta(params.find<SST::UnitAlgebra>("rdma_page_delay", "0s").getValue().toDouble());
pin_delay_ = rdma_pin_latency_.ticks() || rdma_page_delay_.ticks();
page_size_ = params.find<SST::UnitAlgebra>("rdma_page_size", "4096").getRoundedValue();
page_size_ = params.find<SST::UnitAlgebra>("rdma_page_size", "4096 B").getRoundedValue();

output.output("%d", sid().app_);
nproc_ = os_->nranks();
Expand Down
13 changes: 7 additions & 6 deletions src/sst/elements/mask-mpi/mpi_api.cc
Original file line number Diff line number Diff line change
Expand Up @@ -188,12 +188,13 @@ MpiApi::~MpiApi()
delete comm;
}

//people can be sloppy cleaning up requests
//clean up for them
for (auto& pair : req_map_){
MpiRequest* req = pair.second;
delete req;
}
// This causes a "pointer being freed was not allocated" error
// //people can be sloppy cleaning up requests
// //clean up for them
// for (auto& pair : req_map_){
// MpiRequest* req = pair.second;
// delete req;
// }

if (qos_analysis_) delete qos_analysis_;
}
Expand Down
20 changes: 12 additions & 8 deletions src/sst/elements/mask-mpi/tests/platform_file_mask_mpi_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

platdef.addParamSet("nic",{
"verbose" : "0",
"mtu" : "4096 B",
})

platdef.addParamSet("operating_system",{
Expand All @@ -30,34 +31,37 @@
})

platdef.addParamSet("network_interface",{
"link_bw" : "12 GB/s",
"input_buf_size" : "16kB",
"output_buf_size" : "16kB"
"link_bw" : "11.25 GB/s",
"input_buf_size" : "32kB",
"output_buf_size" : "32kB"
})

platdef.addClassType("network_interface","sst.merlin.interface.ReorderLinkControl")

platdef.addParamSet("router",{
"link_bw" : "12 GB/s",
"link_bw" : "11.25 GB/s",
"flit_size" : "8B",
"xbar_bw" : "50GB/s",
"input_latency" : "20ns",
"output_latency" : "20ns",
"input_buf_size" : "16kB",
"output_buf_size" : "16kB",
"input_buf_size" : "32kB",
"output_buf_size" : "32kB",
"num_vns" : 1,
"xbar_arb" : "merlin.xbar_arb_lru",
})

platdef.addParamSet("operating_system", {
"ncores" : "24",
"nsockets" : "4",
"app1.post_rdma_delay" : "88us",
"app1.post_header_delay" : "0.36us",
"app1.post_rdma_delay" : "1.5us",
"app1.post_header_delay" : "0.5us",
"app1.poll_delay" : "0us",
"app1.rdma_pin_latency" : "5.43us",
"app1.rdma_page_delay" : "50.50ns",
"app1.rdma_page_size" : "4096",
"app1.max_vshort_msg_size" : "4096 B",
"app1.max_eager_msg_size" : "32768 B",
"app1.use_put_window" : "false",
"app1.compute_library_access_width" : "64",
"app1.compute_library_loop_overhead" : "1.0",
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ recv_values[4]=4
recv_values[5]=5
recv_values[6]=6
recv_values[7]=7
Simulation is complete, simulated time: 5.31875 us
Simulation is complete, simulated time: 6.99895 us
2 changes: 1 addition & 1 deletion src/sst/elements/mask-mpi/tests/refFiles/test_alltoall.out
Original file line number Diff line number Diff line change
Expand Up @@ -1022,4 +1022,4 @@ recv_values[1020]=7
recv_values[1021]=7
recv_values[1022]=7
recv_values[1023]=7
Simulation is complete, simulated time: 270.615 us
Simulation is complete, simulated time: 12.795 us
2 changes: 1 addition & 1 deletion src/sst/elements/mask-mpi/tests/refFiles/test_halo3d26.out
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
halo3d-26 executed successfully
Simulation is complete, simulated time: 53.62 ms
Simulation is complete, simulated time: 1.1873 ms
2 changes: 1 addition & 1 deletion src/sst/elements/mask-mpi/tests/refFiles/test_reduce.out
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ recv_values[4]=4
recv_values[5]=5
recv_values[6]=6
recv_values[7]=7
Simulation is complete, simulated time: 6.63875 us
Simulation is complete, simulated time: 8.73895 us
2 changes: 1 addition & 1 deletion src/sst/elements/mask-mpi/tests/refFiles/test_sendrecv.out
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,4 @@ A[4] = 4
A[5] = 5
A[6] = 6
A[7] = 7
Simulation is complete, simulated time: 2.21875 us
Simulation is complete, simulated time: 2.91879 us
4 changes: 2 additions & 2 deletions src/sst/elements/mercury/components/nic.cc
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ NIC::NIC(uint32_t id, SST::Params& params, NodeBase* parent) :
ack_queue_.resize(1);

// FIXME needs to be a parameter
mtu_ = 2048;
mtu_ = params.find<unsigned int>("mtu", 4096);
out_->debug(CALL_INFO, 1, 0, "setting mtu to %d\n", mtu_);
}

std::string
Expand Down Expand Up @@ -188,7 +189,6 @@ NIC::sendWhatYouCan(int vn) {

bool
NIC::sendWhatYouCan(int vn, Pending& p) {
int seqnum = 0;
uint64_t next_bytes = std::min(uint64_t(mtu_), p.bytesLeft);
uint32_t next_bits = next_bytes * 8; //this is fine for 32-bits
while (link_control_->spaceToSend(vn, next_bits)){
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ mem_(mem), nodeCL_(node)

double parallelism = params.find<double>("parallelism", 1.0);

freq_ = params.find<SST::UnitAlgebra>("frequency", "2.1 GHz").getValue().toDouble();
freq_ = params.find<SST::UnitAlgebra>("frequency", "2.0 GHz").getValue().toDouble();
mem_freq_ = freq_;

tflop_ = TimeDelta(1.0 / freq_ / parallelism);
Expand Down
2 changes: 1 addition & 1 deletion src/sst/elements/mercury/libraries/compute/memory_model.cc
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ MemoryModel::MemoryModel(SST::Params &params, NodeCL* parent) :
{
flow_mtu_ = params.find<SST::UnitAlgebra>("flow_mtu", "512").getRoundedValue();

auto max_bw = params.find<SST::UnitAlgebra>("channel_bandwidth", "10.0 GB/s");
auto max_bw = params.find<SST::UnitAlgebra>("channel_bandwidth", "12.0 GB/s");
channel_byte_delay_ = TimeDelta(max_bw.getValue().inverse().toDouble());

int num_channels = params.find<int>("num_channels",4);
Expand Down
7 changes: 6 additions & 1 deletion src/sst/elements/mercury/pymercury.py
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,9 @@ def build(self,nid,lid,nranks):
class HgNIC(TemplateBase):
def __init__(self):
TemplateBase.__init__(self)
self._declareParams("params",["verbose",])
self._declareParams("params",["verbose",
"mtu",
])
self._subscribeToPlatformParamSet("nic")

def build(self,comp,slot):
Expand Down Expand Up @@ -104,6 +106,9 @@ def __init__(self):
"rdma_pin_latency",
"rdma_page_delay",
"rdma_page_size",
"max_vshort_msg_size",
"max_eager_msg_size",
"use_put_window",
"compute_library_access_width",
"compute_library_loop_overhead",
],
Expand Down

0 comments on commit 659211a

Please sign in to comment.