ZJIT: Add the ISEQ name to Block asm comments (#14070)

This commit is contained in:
Takashi Kokubun 2025-07-31 14:28:08 -07:00 committed by GitHub
parent 5a7be72c06
commit 543f8dcad3
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 30 additions and 22 deletions

View file

@ -244,7 +244,11 @@ fn gen_function(cb: &mut CodeBlock, iseq: IseqPtr, function: &Function) -> Optio
let reverse_post_order = function.rpo();
for &block_id in reverse_post_order.iter() {
let block = function.block(block_id);
asm_comment!(asm, "Block: {block_id}({})", block.params().map(|param| format!("{param}")).collect::<Vec<_>>().join(", "));
asm_comment!(
asm, "{block_id}({}): {}",
block.params().map(|param| format!("{param}")).collect::<Vec<_>>().join(", "),
iseq_get_location(iseq, block.insn_idx),
);
// Write a label to jump to the basic block
let label = jit.get_label(&mut asm, block_id);