From: ceriel Date: Sat, 23 Nov 1991 12:17:18 +0000 (+0000) Subject: Bug fix in multiplication optimization X-Git-Tag: release-5-5~608 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=aa702fa8553a3eea83b09d2dfa42a664ffa2ca20;p=ack.git Bug fix in multiplication optimization --- diff --git a/util/opt/peephole.c b/util/opt/peephole.c index 3df804144..329a1a926 100644 --- a/util/opt/peephole.c +++ b/util/opt/peephole.c @@ -777,19 +777,19 @@ repl_mul(lp, b, e) newinstr(b, op_exg, sz); b = &((*b)->l_next); newinstr(b, op_dup, 2*sz); b = &((*b)->l_next); newinstr(b, op_asp, sz); b = &((*b)->l_next); - newinstr(b, op_sbu, sz); b = &((*b)->l_next); - retval++; - newinstr(b, op_exg, sz); b = &((*b)->l_next); - newinstr(b, op_loc, n1); b = &((*b)->l_next); - newinstr(b, op_slu, sz); b = &((*b)->l_next); - retval++; - newinstr(b, op_exg, sz); b = &((*b)->l_next); - newinstr(b, op_dup, 2*sz); b = &((*b)->l_next); - newinstr(b, op_asp, sz); b = &((*b)->l_next); - newinstr(b, op_adu, sz); b = &((*b)->l_next); - newinstr(b, op_exg, sz); b = &((*b)->l_next); - retval++; } + newinstr(b, op_sbu, sz); b = &((*b)->l_next); + retval++; + newinstr(b, op_exg, sz); b = &((*b)->l_next); + newinstr(b, op_loc, n1); b = &((*b)->l_next); + newinstr(b, op_slu, sz); b = &((*b)->l_next); + retval++; + newinstr(b, op_exg, sz); b = &((*b)->l_next); + newinstr(b, op_dup, 2*sz); b = &((*b)->l_next); + newinstr(b, op_asp, sz); b = &((*b)->l_next); + newinstr(b, op_adu, sz); b = &((*b)->l_next); + newinstr(b, op_exg, sz); b = &((*b)->l_next); + retval++; if (n0) { newinstr(b, op_loc, n0); b = &((*b)->l_next); newinstr(b, op_slu, sz); b = &((*b)->l_next);