diff options
Diffstat (limited to 'sysdeps')
-rw-r--r-- | sysdeps/sparc/sparc32/Makefile | 8 | ||||
-rw-r--r-- | sysdeps/sparc/sparc32/divrem.m4 | 8 | ||||
-rw-r--r-- | sysdeps/sparc/sparc32/rem.S | 2 | ||||
-rw-r--r-- | sysdeps/sparc/sparc32/sdiv.S | 2 | ||||
-rw-r--r-- | sysdeps/sparc/sparc32/udiv.S | 2 | ||||
-rw-r--r-- | sysdeps/sparc/sparc32/urem.S | 2 |
6 files changed, 13 insertions, 11 deletions
diff --git a/sysdeps/sparc/sparc32/Makefile b/sysdeps/sparc/sparc32/Makefile index 14d6e03c6f..eb0438ae50 100644 --- a/sysdeps/sparc/sparc32/Makefile +++ b/sysdeps/sparc/sparc32/Makefile @@ -37,10 +37,10 @@ divrem := sdiv udiv rem urem +divrem-S-udiv := false +divrem-S-urem := false $(divrem:%=$(sysdep_dir)/sparc/sparc32/%.S): $(sysdep_dir)/sparc/sparc32/divrem.m4 - (echo "define(NAME,\`.$(+divrem-NAME)')\ - define(OP,\`$(+divrem-OP-$(+divrem-NAME))')\ - define(S,\`$(+divrem-S-$(+divrem-NAME))')\ - /* This file is generated from divrem.m4; DO NOT EDIT! */"; \ + (echo -n "define(NAME,\`.$(+divrem-NAME)')"; \ + echo -n " define(OP,\`$(+divrem-OP-$(+divrem-NAME))')"; \ + echo -n " define(S,\`$(+divrem-S-$(+divrem-NAME))')"; \ + echo " /* This file is generated from divrem.m4; DO NOT EDIT! */"; \ cat $<) | $(M4) > $@-tmp # Make it unwritable so noone will edit it by mistake. -chmod a-w $@-tmp diff --git a/sysdeps/sparc/sparc32/divrem.m4 b/sysdeps/sparc/sparc32/divrem.m4 index 30d532ad77..c08c530020 100644 --- a/sysdeps/sparc/sparc32/divrem.m4 +++ b/sysdeps/sparc/sparc32/divrem.m4 @@ -72,15 +72,15 @@ define(DEVELOP_QUOTIENT_BITS, ifelse($1, N, ` b 9f add Q, ($2*2+1), Q - ', ` DEVELOP_QUOTIENT_BITS(incr($1), `eval(2*$2+1)')') +', ` DEVELOP_QUOTIENT_BITS(incr($1), `eval(2*$2+1)')') LOC($1.eval(2**N+$2)): ! remainder is negative addcc R,V,R ifelse($1, N, ` b 9f add Q, ($2*2-1), Q - ', ` DEVELOP_QUOTIENT_BITS(incr($1), `eval(2*$2-1)')') - ifelse($1, 1, `9:')')dnl +', ` DEVELOP_QUOTIENT_BITS(incr($1), `eval(2*$2-1)')') +ifelse($1, 1, `9:')')dnl #include <sysdep.h> #include <sys/trap.h> @@ -230,3 +230,5 @@ ifelse(S, `true', ifelse(OP, `div', `mov Q, %o0', `mov R, %o0') END(NAME) +ifelse(OP, `div', ifelse(S, `false', `strong_alias (.udiv, __wrap_.udiv) +'))dnl diff --git a/sysdeps/sparc/sparc32/rem.S b/sysdeps/sparc/sparc32/rem.S index 349d7c0115..79e09a9ef8 100644 --- a/sysdeps/sparc/sparc32/rem.S +++ b/sysdeps/sparc/sparc32/rem.S @@ -341,7 +341,7 @@ LOC(4.9): - 9: +9: LOC(end_regular_divide): subcc %o4, 1, %o4 bge LOC(divloop) diff --git a/sysdeps/sparc/sparc32/sdiv.S b/sysdeps/sparc/sparc32/sdiv.S index d1d4ee31f8..ab29718827 100644 --- a/sysdeps/sparc/sparc32/sdiv.S +++ b/sysdeps/sparc/sparc32/sdiv.S @@ -341,7 +341,7 @@ LOC(4.9): - 9: +9: LOC(end_regular_divide): subcc %o4, 1, %o4 bge LOC(divloop) diff --git a/sysdeps/sparc/sparc32/udiv.S b/sysdeps/sparc/sparc32/udiv.S index ade0afdf40..1db6796431 100644 --- a/sysdeps/sparc/sparc32/udiv.S +++ b/sysdeps/sparc/sparc32/udiv.S @@ -328,7 +328,7 @@ LOC(4.9): - 9: +9: LOC(end_regular_divide): subcc %o4, 1, %o4 bge LOC(divloop) diff --git a/sysdeps/sparc/sparc32/urem.S b/sysdeps/sparc/sparc32/urem.S index d3a1a441fd..83fb4c242e 100644 --- a/sysdeps/sparc/sparc32/urem.S +++ b/sysdeps/sparc/sparc32/urem.S @@ -328,7 +328,7 @@ LOC(4.9): - 9: +9: LOC(end_regular_divide): subcc %o4, 1, %o4 bge LOC(divloop) |