From: Victor van den Elzen Date: Mon, 23 Feb 2009 03:35:00 +0000 (+0100) Subject: BR 2420167: jmp not always optimized X-Git-Url: https://repo.or.cz/w/nasm/perl-rewrite.git/commitdiff_plain/ccafc3c4b75d8c26c2d57c2a4d39bb49cd76231c BR 2420167: jmp not always optimized Begin by assuming short jumps are possible to prevent suboptimal convergence. --- diff --git a/assemble.c b/assemble.c index ad7ea706..748e62f7 100644 --- a/assemble.c +++ b/assemble.c @@ -262,6 +262,11 @@ static bool jmp_match(int32_t segment, int64_t offset, int bits, return false; isize = calcsize(segment, offset, bits, ins, code); + + if (ins->oprs[0].segment == NO_SEG) + /* Be optimistic in pass 1 */ + return true; + if (ins->oprs[0].segment != segment) return false;