summaryrefslogtreecommitdiff
path: root/gnu/usr.bin
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/usr.bin')
-rw-r--r--gnu/usr.bin/gcc/gcc/config/sh/lib1funcs.asm119
1 files changed, 111 insertions, 8 deletions
diff --git a/gnu/usr.bin/gcc/gcc/config/sh/lib1funcs.asm b/gnu/usr.bin/gcc/gcc/config/sh/lib1funcs.asm
index 19bba0ba5c1..743d997dffd 100644
--- a/gnu/usr.bin/gcc/gcc/config/sh/lib1funcs.asm
+++ b/gnu/usr.bin/gcc/gcc/config/sh/lib1funcs.asm
@@ -39,8 +39,12 @@ Boston, MA 02111-1307, USA. */
#ifdef __ELF__
#define LOCAL(X) .L_##X
+#define FUNC(X,Y) .type X,Y
+#define ENDFUNC(X) .size X,.-X
#else
#define LOCAL(X) L_##X
+#define FUNC(X,Y)
+#define ENDFUNC(X)
#endif
#define CONCAT(A,B) A##B
@@ -87,6 +91,40 @@ Boston, MA 02111-1307, USA. */
.global GLOBAL(ashiftrt_r4_31)
.global GLOBAL(ashiftrt_r4_32)
+ FUNC(GLOBAL(ashiftrt_r4_0),function)
+ FUNC(GLOBAL(ashiftrt_r4_1),function)
+ FUNC(GLOBAL(ashiftrt_r4_2),function)
+ FUNC(GLOBAL(ashiftrt_r4_3),function)
+ FUNC(GLOBAL(ashiftrt_r4_4),function)
+ FUNC(GLOBAL(ashiftrt_r4_5),function)
+ FUNC(GLOBAL(ashiftrt_r4_6),function)
+ FUNC(GLOBAL(ashiftrt_r4_7),function)
+ FUNC(GLOBAL(ashiftrt_r4_8),function)
+ FUNC(GLOBAL(ashiftrt_r4_9),function)
+ FUNC(GLOBAL(ashiftrt_r4_10),function)
+ FUNC(GLOBAL(ashiftrt_r4_11),function)
+ FUNC(GLOBAL(ashiftrt_r4_12),function)
+ FUNC(GLOBAL(ashiftrt_r4_13),function)
+ FUNC(GLOBAL(ashiftrt_r4_14),function)
+ FUNC(GLOBAL(ashiftrt_r4_15),function)
+ FUNC(GLOBAL(ashiftrt_r4_16),function)
+ FUNC(GLOBAL(ashiftrt_r4_17),function)
+ FUNC(GLOBAL(ashiftrt_r4_18),function)
+ FUNC(GLOBAL(ashiftrt_r4_19),function)
+ FUNC(GLOBAL(ashiftrt_r4_20),function)
+ FUNC(GLOBAL(ashiftrt_r4_21),function)
+ FUNC(GLOBAL(ashiftrt_r4_22),function)
+ FUNC(GLOBAL(ashiftrt_r4_23),function)
+ FUNC(GLOBAL(ashiftrt_r4_24),function)
+ FUNC(GLOBAL(ashiftrt_r4_25),function)
+ FUNC(GLOBAL(ashiftrt_r4_26),function)
+ FUNC(GLOBAL(ashiftrt_r4_27),function)
+ FUNC(GLOBAL(ashiftrt_r4_28),function)
+ FUNC(GLOBAL(ashiftrt_r4_29),function)
+ FUNC(GLOBAL(ashiftrt_r4_30),function)
+ FUNC(GLOBAL(ashiftrt_r4_31),function)
+ FUNC(GLOBAL(ashiftrt_r4_32),function)
+
.align 1
GLOBAL(ashiftrt_r4_32):
GLOBAL(ashiftrt_r4_31):
@@ -188,6 +226,7 @@ GLOBAL(ashiftrt_r4_0):
!
.global GLOBAL(ashrsi3)
+ FUNC(GLOBAL(ashrsi3),function)
.align 2
GLOBAL(ashrsi3):
mov #31,r0
@@ -201,6 +240,7 @@ GLOBAL(ashrsi3):
braf r5
#endif
mov r4,r0
+ ENDFUNC(GLOBAL(ashrsi3))
.align 2
LOCAL(ashrsi3_table):
@@ -336,6 +376,7 @@ LOCAL(ashrsi3_0):
! (none)
!
.global GLOBAL(ashlsi3)
+ FUNC(GLOBAL(ashrsi3),function)
.align 2
GLOBAL(ashlsi3):
mov #31,r0
@@ -349,6 +390,7 @@ GLOBAL(ashlsi3):
braf r5
#endif
mov r4,r0
+ ENDFUNC(GLOBAL(ashrsi3))
.align 2
LOCAL(ashlsi3_table):
@@ -493,6 +535,7 @@ LOCAL(ashlsi3_0):
! (none)
!
.global GLOBAL(lshrsi3)
+ FUNC(GLOBAL(lshrsi3),function)
.align 2
GLOBAL(lshrsi3):
mov #31,r0
@@ -506,6 +549,7 @@ GLOBAL(lshrsi3):
braf r5
#endif
mov r4,r0
+ ENDFUNC(GLOBAL(lshrsi3))
.align 2
LOCAL(lshrsi3_table):
@@ -645,77 +689,111 @@ done:
add #64,r4
.align 4
.global GLOBAL(movstrSI64)
+ FUNC(GLOBAL(movstrSI64),function)
GLOBAL(movstrSI64):
mov.l @(60,r5),r0
mov.l r0,@(60,r4)
.global GLOBAL(movstrSI60)
+ FUNC(GLOBAL(movstrSI60),function)
GLOBAL(movstrSI60):
mov.l @(56,r5),r0
mov.l r0,@(56,r4)
.global GLOBAL(movstrSI56)
+ FUNC(GLOBAL(movstrSI56),function)
GLOBAL(movstrSI56):
mov.l @(52,r5),r0
mov.l r0,@(52,r4)
.global GLOBAL(movstrSI52)
+ FUNC(GLOBAL(movstrSI52),function)
GLOBAL(movstrSI52):
mov.l @(48,r5),r0
mov.l r0,@(48,r4)
.global GLOBAL(movstrSI48)
+ FUNC(GLOBAL(movstrSI48),function)
GLOBAL(movstrSI48):
mov.l @(44,r5),r0
mov.l r0,@(44,r4)
.global GLOBAL(movstrSI44)
+ FUNC(GLOBAL(movstrSI44),function)
GLOBAL(movstrSI44):
mov.l @(40,r5),r0
mov.l r0,@(40,r4)
.global GLOBAL(movstrSI40)
+ FUNC(GLOBAL(movstrSI40),function)
GLOBAL(movstrSI40):
mov.l @(36,r5),r0
mov.l r0,@(36,r4)
.global GLOBAL(movstrSI36)
+ FUNC(GLOBAL(movstrSI36),function)
GLOBAL(movstrSI36):
mov.l @(32,r5),r0
mov.l r0,@(32,r4)
.global GLOBAL(movstrSI32)
+ FUNC(GLOBAL(movstrSI32),function)
GLOBAL(movstrSI32):
mov.l @(28,r5),r0
mov.l r0,@(28,r4)
.global GLOBAL(movstrSI28)
+ FUNC(GLOBAL(movstrSI28),function)
GLOBAL(movstrSI28):
mov.l @(24,r5),r0
mov.l r0,@(24,r4)
.global GLOBAL(movstrSI24)
+ FUNC(GLOBAL(movstrSI24),function)
GLOBAL(movstrSI24):
mov.l @(20,r5),r0
mov.l r0,@(20,r4)
.global GLOBAL(movstrSI20)
+ FUNC(GLOBAL(movstrSI20),function)
GLOBAL(movstrSI20):
mov.l @(16,r5),r0
mov.l r0,@(16,r4)
.global GLOBAL(movstrSI16)
+ FUNC(GLOBAL(movstrSI16),function)
GLOBAL(movstrSI16):
mov.l @(12,r5),r0
mov.l r0,@(12,r4)
.global GLOBAL(movstrSI12)
+ FUNC(GLOBAL(movstrSI12),function)
GLOBAL(movstrSI12):
mov.l @(8,r5),r0
mov.l r0,@(8,r4)
.global GLOBAL(movstrSI8)
+ FUNC(GLOBAL(movstrSI8),function)
GLOBAL(movstrSI8):
mov.l @(4,r5),r0
mov.l r0,@(4,r4)
.global GLOBAL(movstrSI4)
+ FUNC(GLOBAL(movstrSI4),function)
GLOBAL(movstrSI4):
mov.l @(0,r5),r0
mov.l r0,@(0,r4)
GLOBAL(movstrSI0):
+ FUNC(GLOBAL(movstrSI0),function)
rts
nop
+ ENDFUNC(GLOBAL(movstrSI64))
+ ENDFUNC(GLOBAL(movstrSI60))
+ ENDFUNC(GLOBAL(movstrSI56))
+ ENDFUNC(GLOBAL(movstrSI52))
+ ENDFUNC(GLOBAL(movstrSI48))
+ ENDFUNC(GLOBAL(movstrSI44))
+ ENDFUNC(GLOBAL(movstrSI40))
+ ENDFUNC(GLOBAL(movstrSI36))
+ ENDFUNC(GLOBAL(movstrSI32))
+ ENDFUNC(GLOBAL(movstrSI28))
+ ENDFUNC(GLOBAL(movstrSI24))
+ ENDFUNC(GLOBAL(movstrSI20))
+ ENDFUNC(GLOBAL(movstrSI16))
+ ENDFUNC(GLOBAL(movstrSI12))
+ ENDFUNC(GLOBAL(movstrSI8))
+ ENDFUNC(GLOBAL(movstrSI4))
+ ENDFUNC(GLOBAL(movstrSI0))
.align 4
.global GLOBAL(movstr)
- .type GLOBAL(movstr),function
+ FUNC(GLOBAL(movstr),function)
GLOBAL(movstr):
mov.l @(60,r5),r0
mov.l r0,@(60,r4)
@@ -772,7 +850,7 @@ GLOBAL(movstr):
add #64,r5
bra GLOBAL(movstr)
add #64,r4
- .size GLOBAL(movstr),.-GLOBAL(movstr)
+ ENDFUNC(GLOBAL(movstr))
#endif
#ifdef L_movstr_i4
@@ -780,6 +858,9 @@ GLOBAL(movstr):
.global GLOBAL(movstr_i4_even)
.global GLOBAL(movstr_i4_odd)
.global GLOBAL(movstrSI12_i4)
+ FUNC(GLOBAL(movstr_i4_even),function)
+ FUNC(GLOBAL(movstr_i4_odd),function)
+ FUNC(GLOBAL(movstrSI12_i4),function)
.p2align 5
L_movstr_2mod4_end:
@@ -814,6 +895,7 @@ L_movstr_start_even:
mov.l r2,@(8,r4)
rts
mov.l r3,@(12,r4)
+ ENDFUNC(GLOBAL(movstr_i4_odd))
GLOBAL(movstr_i4_even):
mov.l @r5+,r0
@@ -829,12 +911,15 @@ GLOBAL(movstrSI12_i4):
mov.l r1,@(4,r4)
rts
mov.l r2,@(8,r4)
+ ENDFUNC(GLOBAL(movstr_i4_even))
+ ENDFUNC(GLOBAL(movstrSI12_i4))
#endif
#ifdef L_mulsi3
.global GLOBAL(mulsi3)
+ FUNC(GLOBAL(mulsi3),function)
! r4 = aabb
! r5 = ccdd
@@ -877,6 +962,7 @@ hiset: sts macl,r0 ! r0 = bb*dd
!! args in r4 and r5, result in fpul, clobber dr0, dr2
.global GLOBAL(sdivsi3_i4)
+ FUNC(GLOBAL(sdivsi3_i4),function)
GLOBAL(sdivsi3_i4):
lds r4,fpul
float fpul,dr0
@@ -885,6 +971,7 @@ GLOBAL(sdivsi3_i4):
fdiv dr2,dr0
rts
ftrc dr0,fpul
+ ENDFUNC(GLOBAL(sdivsi3_i4))
#elif defined(__SH4_SINGLE__) || defined(__SH4_SINGLE_ONLY__) || (defined (__SH5__) && ! defined __SH4_NOFPU__)
!! args in r4 and r5, result in fpul, clobber r2, dr0, dr2
@@ -894,6 +981,7 @@ GLOBAL(sdivsi3_i4):
.mode SHcompact
#endif
.global GLOBAL(sdivsi3_i4)
+ FUNC(GLOBAL(sdivsi3_i4),function)
GLOBAL(sdivsi3_i4):
sts.l fpscr,@-r15
mov #8,r2
@@ -915,7 +1003,7 @@ GLOBAL(sdivsi3_i4):
#ifdef L_sdivsi3
/* __SH4_SINGLE_ONLY__ keeps this part for link compatibility with
sh3e code. */
-#if (! defined(__SH4__) && ! defined (__SH4_SINGLE__)) || defined (__linux__)
+#if (! defined(__SH4__) && ! defined (__SH4_SINGLE__)) || defined (__linux__) || defined (__OpenBSD__)
!!
!! Steve Chamberlain
!! sac@cygnus.com
@@ -925,7 +1013,7 @@ GLOBAL(sdivsi3_i4):
!! args in r4 and r5, result in r0 clobber r1,r2,r3
.global GLOBAL(sdivsi3)
- .type GLOBAL(sdivsi3), function
+ FUNC(GLOBAL(sdivsi3), function)
#if __SHMEDIA__
#if __SH5__ == 32
.section .text..SHmedia32,"ax"
@@ -1168,7 +1256,7 @@ GLOBAL(sdivsi3):
div0: rts
mov #0,r0
- .size GLOBAL(sdivsi3),.-GLOBAL(sdivsi3)
+ ENDFUNC(GLOBAL(sdivsi3))
#endif /* ! __SHMEDIA__ */
#endif /* ! __SH4__ */
@@ -1181,6 +1269,7 @@ div0: rts
!! args in r4 and r5, result in fpul, clobber r0, r1, r4, r5, dr0, dr2, dr4
.global GLOBAL(udivsi3_i4)
+ FUNC(GLOBAL(udivsi3_i4),function)
GLOBAL(udivsi3_i4):
mov #1,r1
cmp/hi r1,r5
@@ -1226,6 +1315,7 @@ L1:
!! args in r4 and r5, result in fpul, clobber r20, r21, dr0, fr33
.mode SHmedia
.global GLOBAL(udivsi3_i4)
+ FUNC(GLOBAL(udivsi3_i4),function)
GLOBAL(udivsi3_i4):
addz.l r4,r63,r20
addz.l r5,r63,r21
@@ -1243,6 +1333,7 @@ GLOBAL(udivsi3_i4):
!! args in r4 and r5, result in fpul, clobber r0, r1, r4, r5, dr0, dr2, dr4
.global GLOBAL(udivsi3_i4)
+ FUNC(GLOBAL(udivsi3_i4),function)
GLOBAL(udivsi3_i4):
mov #1,r1
cmp/hi r1,r5
@@ -1274,6 +1365,7 @@ GLOBAL(udivsi3_i4):
ftrc dr0,fpul
rts
lds.l @r15+,fpscr
+ ENDFUNC(GLOBAL(udivsi3_i4))
#ifdef FMOVD_WORKS
.align 3 ! make double below 8 byte aligned.
@@ -1297,11 +1389,11 @@ L1:
#ifdef L_udivsi3
/* __SH4_SINGLE_ONLY__ keeps this part for link compatibility with
sh3e code. */
-#if (! defined(__SH4__) && ! defined (__SH4_SINGLE__)) || defined (__linux__)
+#if (! defined(__SH4__) && ! defined (__SH4_SINGLE__)) || defined (__linux__) || defined (__OpenBSD__)
!! args in r4 and r5, result in r0, clobbers r4, pr, and t bit
.global GLOBAL(udivsi3)
- .type GLOBAL(udivsi3),function
+ FUNC(GLOBAL(udivsi3),function)
#if __SHMEDIA__
#if __SH5__ == 32
@@ -1470,7 +1562,7 @@ GLOBAL(udivsi3):
rotcl r0
rts
shlr16 r5
- .size GLOBAL(udivsi3),.-GLOBAL(udivsi3)
+ ENDFUNC(GLOBAL(udivsi3))
LOCAL(large_divisor):
#ifdef __sh1__
@@ -1501,6 +1593,7 @@ LOCAL(large_divisor):
.section .text..SHmedia32,"ax"
.align 2
.global GLOBAL(udivdi3)
+ FUNC(GLOBAL(udivdi3),function)
GLOBAL(udivdi3):
shlri r3,1,r4
nsb r4,r22
@@ -1626,6 +1719,7 @@ LOCAL(no_lo_adj):
.section .text..SHmedia32,"ax"
.align 2
.global GLOBAL(divdi3)
+ FUNC(GLOBAL(divdi3),function)
GLOBAL(divdi3):
pta GLOBAL(udivdi3),tr0
shari r2,63,r22
@@ -1648,6 +1742,7 @@ GLOBAL(divdi3):
.section .text..SHmedia32,"ax"
.align 2
.global GLOBAL(umoddi3)
+ FUNC(GLOBAL(umoddi3),function)
GLOBAL(umoddi3):
shlri r3,1,r4
nsb r4,r22
@@ -1774,6 +1869,7 @@ LOCAL(no_lo_adj):
.section .text..SHmedia32,"ax"
.align 2
.global GLOBAL(moddi3)
+ FUNC(GLOBAL(moddi3),function)
GLOBAL(moddi3):
pta GLOBAL(umoddi3),tr0
shari r2,63,r22
@@ -1796,6 +1892,7 @@ GLOBAL(moddi3):
.mode SHcompact
#endif
.global GLOBAL(set_fpscr)
+ FUNC(GLOBAL(set_fpscr),function)
GLOBAL(set_fpscr):
lds r4,fpscr
mov.l LOCAL(set_fpscr_L1),r1
@@ -1841,6 +1938,7 @@ LOCAL(set_fpscr_L1):
.section .text..SHmedia32,"ax"
.align 2
.global GLOBAL(init_trampoline)
+ FUNC(GLOBAL(set_fpscr),function)
GLOBAL(init_trampoline):
st.l r0,8,r2
#ifdef __LITTLE_ENDIAN__
@@ -1857,6 +1955,7 @@ GLOBAL(init_trampoline):
st.q r0,0,r20
st.l r0,12,r3
.global GLOBAL(ic_invalidate)
+ FUNC(GLOBAL(ic_invalidate),function)
GLOBAL(ic_invalidate):
ocbwb r0,0
synco
@@ -1866,6 +1965,7 @@ GLOBAL(ic_invalidate):
blink tr0, r63
#elif defined(__SH4_SINGLE__) || defined(__SH4__) || defined(__SH4_SINGLE_ONLY__)
.global GLOBAL(ic_invalidate)
+ FUNC(GLOBAL(ic_invalidate),function)
GLOBAL(ic_invalidate):
ocbwb @r4
mova 0f,r0
@@ -1946,6 +2046,7 @@ LOCAL(ct_main_table):
will be expanded into r2/r3 upon return. */
.global GLOBAL(GCC_shcompact_call_trampoline)
+ FUNC(GLOBAL(GCC_shcompact_call_trampoline),function)
GLOBAL(GCC_shcompact_call_trampoline):
ptabs/l r0, tr0 /* Prepare to call the actual function. */
movi ((datalabel LOCAL(ct_main_table) - 31 * 2) >> 16) & 65535, r0
@@ -2308,6 +2409,7 @@ LOCAL(ct_ret_wide): /* Call the function, so that we can unpack its
.section .text..SHmedia32, "ax"
.align 2
.global GLOBAL(GCC_shcompact_return_trampoline)
+ FUNC(GLOBAL(GCC_shcompact_return_trampoline),function)
GLOBAL(GCC_shcompact_return_trampoline):
ptabs/l r18, tr0
#if __LITTLE_ENDIAN__
@@ -2373,6 +2475,7 @@ LOCAL(ia_main_table):
actual bit pattern. */
.global GLOBAL(GCC_shcompact_incoming_args)
+ FUNC(GLOBAL(GCC_shcompact_incoming_args))
GLOBAL(GCC_shcompact_incoming_args):
ptabs/l r18, tr0 /* Prepare to return. */
shlri r17, 32, r0 /* Load the cookie. */