From 584fb00b96cf6f2527330615fee9caf820cd136b Mon Sep 17 00:00:00 2001 From: Kazu Hirata Date: Fri, 14 Nov 2003 20:39:30 +0000 Subject: [PATCH] lib1funcs.asm (___udivsi3): Peel off the first iteration. * config/h8300/lib1funcs.asm (___udivsi3): Peel off the first iteration. From-SVN: r73620 --- gcc/ChangeLog | 5 +++++ gcc/config/h8300/lib1funcs.asm | 5 ++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/gcc/ChangeLog b/gcc/ChangeLog index 3725a1c35a4..44b6690a510 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,8 @@ +2003-11-14 Kazu Hirata + + * config/h8300/lib1funcs.asm (___udivsi3): Peel off the first + iteration. + 2003-11-14 Fariborz Jahanian * config/rs6000/rs6000.c (rs6000_move_block_from_reg): diff --git a/gcc/config/h8300/lib1funcs.asm b/gcc/config/h8300/lib1funcs.asm index 44d399087b6..744d402d19b 100644 --- a/gcc/config/h8300/lib1funcs.asm +++ b/gcc/config/h8300/lib1funcs.asm @@ -633,13 +633,16 @@ divmod_L21: mov.w e2,e2 bne divmod_L21 #else - bra divmod_L22 + shlr.l #2,er2 ; make divisor < 2^16 + mov.w e2,e2 + beq divmod_L22A divmod_L21: shlr.l #2,er0 divmod_L22: shlr.l #2,er2 ; make divisor < 2^16 mov.w e2,e2 bne divmod_L21 +divmod_L22A: rotxl.w r2 bcs divmod_L23 shlr.l er0