| 283 | spv_result_t Output(); |
| 284 | |
| 285 | void DumpIdMap() { |
| 286 | if (!options_.dump_id_map) { |
| 287 | return; |
| 288 | } |
| 289 | |
| 290 | out_ << " Src -> Dst\n"; |
| 291 | for (uint32_t src_id = 1; src_id < src_->IdBound(); ++src_id) { |
| 292 | uint32_t dst_id = id_map_.MappedDstId(src_id); |
| 293 | if (src_id_to_.inst_map_[src_id] != nullptr && dst_id != 0) |
| 294 | out_ << std::setw(4) << src_id << " -> " << std::setw(4) << dst_id |
| 295 | << " [" << spvOpcodeString(src_id_to_.inst_map_[src_id]->opcode()) |
| 296 | << "]\n"; |
| 297 | } |
| 298 | } |
| 299 | |
| 300 | private: |
| 301 | // Helper functions that match ids between src and dst |
no test coverage detected