summaryrefslogtreecommitdiffstats
path: root/contrib/compiler-rt/lib
diff options
context:
space:
mode:
authormarius <marius@FreeBSD.org>2012-05-13 05:09:36 +0000
committermarius <marius@FreeBSD.org>2012-05-13 05:09:36 +0000
commit80005c54cb1d2228fb6a4913fa9ceda467ad6535 (patch)
tree26e6980ebcf7f4522f61411b9cddb72dc77f37a7 /contrib/compiler-rt/lib
parent89316f1b303a584dcaba655aacdd0218a72401f0 (diff)
downloadFreeBSD-src-80005c54cb1d2228fb6a4913fa9ceda467ad6535.zip
FreeBSD-src-80005c54cb1d2228fb6a4913fa9ceda467ad6535.tar.gz
Regenerate after r235388.
Diffstat (limited to 'contrib/compiler-rt/lib')
-rw-r--r--contrib/compiler-rt/lib/sparc64/divsi3.S27
-rw-r--r--contrib/compiler-rt/lib/sparc64/modsi3.S27
2 files changed, 24 insertions, 30 deletions
diff --git a/contrib/compiler-rt/lib/sparc64/divsi3.S b/contrib/compiler-rt/lib/sparc64/divsi3.S
index 52133f7..70fc1f4 100644
--- a/contrib/compiler-rt/lib/sparc64/divsi3.S
+++ b/contrib/compiler-rt/lib/sparc64/divsi3.S
@@ -47,13 +47,13 @@
*/
#include "../assembly.h"
.text
- .align 4
+ .align 32
DEFINE_COMPILERRT_FUNCTION(__udivsi3)
- save %sp,-64,%sp ! do this for debugging
b divide
mov 0,%g3 ! result always nonnegative
+.text
+ .align 32
DEFINE_COMPILERRT_FUNCTION(__divsi3)
- save %sp,-64,%sp ! do this for debugging
orcc %o1,%o0,%g0 ! are either %o0 or %o1 negative
bge divide ! if not, skip this junk
xor %o1,%o0,%g3 ! record sign of result in sign of %g3
@@ -126,8 +126,8 @@ do_single_div:
nop
sub %o3,%o5,%o3
mov 1,%o2
- b end_single_divloop
- nop
+ b,a end_single_divloop
+ ! EMPTY
single_divloop:
sll %o2,1,%o2
bl 1f
@@ -144,8 +144,8 @@ single_divloop:
deccc %g2
bge single_divloop
tst %o3
- b end_regular_divide
- nop
+ b,a end_regular_divide
+ ! EMPTY
not_really_big:
1:
sll %o5,4,%o5
@@ -317,17 +317,14 @@ end_regular_divide:
deccc %o4
bge divloop
tst %o3
- bge got_result
- nop
- ! non-restoring fixup here
+ bl,a got_result
+ ! non-restoring fixup if remainder < 0, otherwise annulled
dec %o2
got_result:
tst %g3
- bge 1f
- restore
- ! answer < 0
- retl ! leaf-routine return
- neg %o2,%o0 ! quotient <- -%o2
+ bl,a 1f
+ ! negate for answer < 0, otherwise annulled
+ neg %o2,%o2 ! %o2 <- -%o2
1:
retl ! leaf-routine return
mov %o2,%o0 ! quotient <- %o2
diff --git a/contrib/compiler-rt/lib/sparc64/modsi3.S b/contrib/compiler-rt/lib/sparc64/modsi3.S
index 98deb9d..e126e3d 100644
--- a/contrib/compiler-rt/lib/sparc64/modsi3.S
+++ b/contrib/compiler-rt/lib/sparc64/modsi3.S
@@ -47,13 +47,13 @@
*/
#include "../assembly.h"
.text
- .align 4
+ .align 32
DEFINE_COMPILERRT_FUNCTION(__umodsi3)
- save %sp,-64,%sp ! do this for debugging
b divide
mov 0,%g3 ! result always nonnegative
+.text
+ .align 32
DEFINE_COMPILERRT_FUNCTION(__modsi3)
- save %sp,-64,%sp ! do this for debugging
orcc %o1,%o0,%g0 ! are either %o0 or %o1 negative
bge divide ! if not, skip this junk
mov %o0,%g3 ! record sign of result in sign of %g3
@@ -126,8 +126,8 @@ do_single_div:
nop
sub %o3,%o5,%o3
mov 1,%o2
- b end_single_divloop
- nop
+ b,a end_single_divloop
+ ! EMPTY
single_divloop:
sll %o2,1,%o2
bl 1f
@@ -144,8 +144,8 @@ single_divloop:
deccc %g2
bge single_divloop
tst %o3
- b end_regular_divide
- nop
+ b,a end_regular_divide
+ ! EMPTY
not_really_big:
1:
sll %o5,4,%o5
@@ -317,17 +317,14 @@ end_regular_divide:
deccc %o4
bge divloop
tst %o3
- bge got_result
- nop
- ! non-restoring fixup here
+ bl,a got_result
+ ! non-restoring fixup if remainder < 0, otherwise annulled
add %o3,%o1,%o3
got_result:
tst %g3
- bge 1f
- restore
- ! answer < 0
- retl ! leaf-routine return
- neg %o3,%o0 ! remainder <- -%o3
+ bl,a 1f
+ ! negate for answer < 0, otherwise annulled
+ neg %o3,%o3 ! %o3 <- -%o3
1:
retl ! leaf-routine return
mov %o3,%o0 ! remainder <- %o3
OpenPOWER on IntegriCloud