xref: /openbmc/u-boot/arch/sh/lib/ashiftrt.S (revision 63e22517)
1/* SPDX-License-Identifier: GPL-2.0+ */
2/* Copyright (C) 1994, 1995, 1997, 1998, 1999, 2000, 2001, 2002, 2003,
3   2004, 2005, 2006
4   Free Software Foundation, Inc.
5 */
6
7!! libgcc routines for the Renesas / SuperH SH CPUs.
8!! Contributed by Steve Chamberlain.
9!! sac@cygnus.com
10
11!! ashiftrt_r4_x, ___ashrsi3, ___ashlsi3, ___lshrsi3 routines
12!! recoded in assembly by Toshiyasu Morita
13!! tm@netcom.com
14
15/* SH2 optimizations for ___ashrsi3, ___ashlsi3, ___lshrsi3 and
16   ELF local label prefixes by J"orn Rennecke
17   amylaar@cygnus.com  */
18
19	.global	__ashiftrt_r4_0
20	.global	__ashiftrt_r4_1
21	.global	__ashiftrt_r4_2
22	.global	__ashiftrt_r4_3
23	.global	__ashiftrt_r4_4
24	.global	__ashiftrt_r4_5
25	.global	__ashiftrt_r4_6
26	.global	__ashiftrt_r4_7
27	.global	__ashiftrt_r4_8
28	.global	__ashiftrt_r4_9
29	.global	__ashiftrt_r4_10
30	.global	__ashiftrt_r4_11
31	.global	__ashiftrt_r4_12
32	.global	__ashiftrt_r4_13
33	.global	__ashiftrt_r4_14
34	.global	__ashiftrt_r4_15
35	.global	__ashiftrt_r4_16
36	.global	__ashiftrt_r4_17
37	.global	__ashiftrt_r4_18
38	.global	__ashiftrt_r4_19
39	.global	__ashiftrt_r4_20
40	.global	__ashiftrt_r4_21
41	.global	__ashiftrt_r4_22
42	.global	__ashiftrt_r4_23
43	.global	__ashiftrt_r4_24
44	.global	__ashiftrt_r4_25
45	.global	__ashiftrt_r4_26
46	.global	__ashiftrt_r4_27
47	.global	__ashiftrt_r4_28
48	.global	__ashiftrt_r4_29
49	.global	__ashiftrt_r4_30
50	.global	__ashiftrt_r4_31
51	.global	__ashiftrt_r4_32
52
53	.align	1
54__ashiftrt_r4_32:
55__ashiftrt_r4_31:
56	rotcl	r4
57	rts
58	subc	r4,r4
59__ashiftrt_r4_30:
60	shar	r4
61__ashiftrt_r4_29:
62	shar	r4
63__ashiftrt_r4_28:
64	shar	r4
65__ashiftrt_r4_27:
66	shar	r4
67__ashiftrt_r4_26:
68	shar	r4
69__ashiftrt_r4_25:
70	shar	r4
71__ashiftrt_r4_24:
72	shlr16	r4
73	shlr8	r4
74	rts
75	exts.b	r4,r4
76__ashiftrt_r4_23:
77	shar	r4
78__ashiftrt_r4_22:
79	shar	r4
80__ashiftrt_r4_21:
81	shar	r4
82__ashiftrt_r4_20:
83	shar	r4
84__ashiftrt_r4_19:
85	shar	r4
86__ashiftrt_r4_18:
87	shar	r4
88__ashiftrt_r4_17:
89	shar	r4
90__ashiftrt_r4_16:
91	shlr16	r4
92	rts
93	exts.w	r4,r4
94__ashiftrt_r4_15:
95	shar	r4
96__ashiftrt_r4_14:
97	shar	r4
98__ashiftrt_r4_13:
99	shar	r4
100__ashiftrt_r4_12:
101	shar	r4
102__ashiftrt_r4_11:
103	shar	r4
104__ashiftrt_r4_10:
105	shar	r4
106__ashiftrt_r4_9:
107	shar	r4
108__ashiftrt_r4_8:
109	shar	r4
110__ashiftrt_r4_7:
111	shar	r4
112__ashiftrt_r4_6:
113	shar	r4
114__ashiftrt_r4_5:
115	shar	r4
116__ashiftrt_r4_4:
117	shar	r4
118__ashiftrt_r4_3:
119	shar	r4
120__ashiftrt_r4_2:
121	shar	r4
122__ashiftrt_r4_1:
123	rts
124	shar	r4
125__ashiftrt_r4_0:
126	rts
127	nop
128