Commit b1113e0a by Toshiyasu Morita Committed by Kazu Hirata

lib1funcs.asm (___cmpsi2, ___ucmpsi2): Bum three instructions from each routine.

	* config/h8300/lib1funcs.asm (___cmpsi2, ___ucmpsi2):
	Bum three instructions from each routine.

From-SVN: r52557
parent 994bca95
2002-04-20 Toshiyasu Morita <toshiyasu.morita@hsa.hitachi.com>
* config/h8300/lib1funcs.asm (___cmpsi2, ___ucmpsi2):
Bum three instructions from each routine.
2002-04-20 Neil Booth <neil@daikokuya.demon.co.uk> 2002-04-20 Neil Booth <neil@daikokuya.demon.co.uk>
* Makefile.in: Update. * Makefile.in: Update.
......
;; libgcc routines for the Hitachi H8/300 CPU. ;; libgcc routines for the Hitachi H8/300 CPU.
;; Contributed by Steve Chamberlain <sac@cygnus.com> ;; Contributed by Steve Chamberlain <sac@cygnus.com>
;; Optimizations by Toshiyasu Morita <toshiyasu.morita@hsa.hitachi.com>
/* Copyright (C) 1994, 2000, 2001 Free Software Foundation, Inc. /* Copyright (C) 1994, 2000, 2001 Free Software Foundation, Inc.
...@@ -108,24 +109,21 @@ Boston, MA 02111-1307, USA. */ ...@@ -108,24 +109,21 @@ Boston, MA 02111-1307, USA. */
.align 2 .align 2
.global ___cmpsi2 .global ___cmpsi2
___cmpsi2: ___cmpsi2:
cmp.w A2,A0 cmp.w A0,A2
bne .L2
cmp.w A3,A1
bne .L2 bne .L2
cmp.w A1,A3
bne .L4
mov.w #1,A0 mov.w #1,A0
rts rts
.L2: .L2:
cmp.w A0,A2 bgt .L5
bgt .L4
bne .L3
cmp.w A1,A3
bls .L3
.L4:
sub.w A0,A0
rts
.L3: .L3:
mov.w #2,A0 mov.w #2,A0
rts
.L4:
bls .L3
.L5: .L5:
sub.w A0,A0
rts rts
.end .end
#endif #endif
...@@ -137,24 +135,21 @@ ___cmpsi2: ...@@ -137,24 +135,21 @@ ___cmpsi2:
.align 2 .align 2
.global ___ucmpsi2 .global ___ucmpsi2
___ucmpsi2: ___ucmpsi2:
cmp.w A2,A0 cmp.w A0,A2
bne .L2
cmp.w A3,A1
bne .L2 bne .L2
cmp.w A1,A3
bne .L4
mov.w #1,A0 mov.w #1,A0
rts rts
.L2: .L2:
cmp.w A0,A2 bhi .L5
bhi .L4
bne .L3
cmp.w A1,A3
bls .L3
.L4:
sub.w A0,A0
rts
.L3: .L3:
mov.w #2,A0 mov.w #2,A0
rts
.L4:
bls .L3
.L5: .L5:
sub.w A0,A0
rts rts
.end .end
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment