From: simonmar Date: Tue, 16 Jul 2002 12:05:37 +0000 (+0000) Subject: [project @ 2002-07-16 12:05:37 by simonmar] X-Git-Tag: Approx_11550_changesets_converted~1847 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=2db30d0659c98890689d26faeac6446b515dfa72;p=ghc-hetmet.git [project @ 2002-07-16 12:05:37 by simonmar] un-rot one transformation on x86: we normally transform movl $_blah, %eax jmp *%eax into simply jmp _blah but the pattern had rotted w.r.t. gcc so this was no longer applying. Should reduce code size measurably. MERGE TO STABLE --- diff --git a/ghc/driver/mangler/ghc-asm.lprl b/ghc/driver/mangler/ghc-asm.lprl index f3afb96..424477e 100644 --- a/ghc/driver/mangler/ghc-asm.lprl +++ b/ghc/driver/mangler/ghc-asm.lprl @@ -1298,7 +1298,7 @@ sub print_doctored { # jmp * # - s/^\tmovl\s+\$${T_US}(.*),(\%e[abcd]x)\n\tjmp\s+\*\2/\tjmp $T_US$1/g; + s/^\tmovl\s+\$${T_US}(.*),\s*(\%e[abcd]x)\n\tjmp\s+\*\2/\tjmp $T_US$1/g; if ($StolenX86Regs <= 2 ) { # YURGH! spurious uses of esi? s/^\tmovl\s+(.*),\s*\%esi\n\tjmp\s+\*%esi\n/\tmovl $1,\%eax\n\tjmp \*\%eax\n/g;