- std::vector<std::string> res;
- for (xbt_fifo_item_t item = xbt_fifo_get_last_item(mc_stack);
- item; item = xbt_fifo_get_prev_item(item)) {
- simgrid::mc::State* state = (simgrid::mc::State*)xbt_fifo_get_item_content(item);
- int value;
- smx_simcall_t req = MC_state_get_executed_request(state, &value);
- if (req) {
- char* req_str = simgrid::mc::request_to_string(
- req, value, simgrid::mc::RequestType::executed);
- res.push_back(req_str);
- xbt_free(req_str);
- }
+ std::vector<std::string> trace;
+ for (auto const& state : stack_) {
+ smx_simcall_t req = &state->executed_req;
+ if (req)
+ trace.push_back(simgrid::mc::request_to_string(
+ req, state->req_num, simgrid::mc::RequestType::executed));