From 0d2836e4709f36f096536edf51248092ccb361fc Mon Sep 17 00:00:00 2001 From: Aleksey Demakov Date: Mon, 22 Dec 2008 18:49:46 +0000 Subject: [PATCH] don't define undefined labels for dump --- ChangeLog | 5 +++++ jit/jit-dump.c | 13 +++++-------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/ChangeLog b/ChangeLog index a2b66e9..a408198 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-12-21 Aleksey Demakov + + * jit/jit-dump.c (jit_dump_function): dump undefined labels as such + rather than generating new labels for them. + 2008-12-12 Aleksey Demakov * jitruby/*: add Paul Brannan's ruby-libjit. diff --git a/jit/jit-dump.c b/jit/jit-dump.c index b67b25b..be8af1f 100644 --- a/jit/jit-dump.c +++ b/jit/jit-dump.c @@ -846,18 +846,15 @@ void jit_dump_function(FILE *stream, jit_function_t func, const char *name) while((block = jit_block_next(func, block)) != 0) { /* Output the block's label, if it has one */ - if(prev_block && block->label == jit_label_undefined) - { - /* A new block was started, but it doesn't have a label yet */ - if(_jit_block_get_last(block) != 0) - { - block->label = (func->builder->next_label)++; - } - } if(block->label != jit_label_undefined) { fprintf(stream, ".L%ld:\n", (long)(block->label)); } + else if (prev_block && _jit_block_get_last(block) != 0) + { + /* A new block was started, but it doesn't have a label yet */ + fprintf(stream, ".L:\n"); + } prev_block = 1; /* Dump the instructions in the block */ -- 2.47.3