MCPcopy Create free account
hub / github.com/N64Recomp/N64Recomp / emit_label

Method emit_label

LiveRecomp/live_generator.cpp:1458–1473  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1456}
1457
1458void N64Recomp::LiveGenerator::emit_label(const std::string& label_name) const {
1459 sljit_label* label = sljit_emit_label(compiler);
1460
1461 // Check if there are any pending jumps for this label and assign them if so.
1462 auto find_it = context->pending_jumps.find(label_name);
1463 if (find_it != context->pending_jumps.end()) {
1464 for (sljit_jump* jump : find_it->second) {
1465 sljit_set_label(jump, label);
1466 }
1467
1468 // Remove the pending jumps for this label.
1469 context->pending_jumps.erase(find_it);
1470 }
1471
1472 context->labels.emplace(label_name, label);
1473}
1474
1475void N64Recomp::LiveGenerator::emit_jtbl_addend_declaration(const JumpTable& jtbl, int reg) const {
1476 (void)jtbl;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected