1 /* SPDX-License-Identifier: GPL-2.0-or-later */
2 /* Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
4 This file is part of GNU CC.
24 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
25 sub %i0,%o3,%i0 ! this kills msb of n
26 addx %i0,%i0,%i0 ! so this cannot give carry
31 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
33 sub %i0,%o3,%i0 ! this kills msb of n
38 ! Got carry from n. Subtract next step to cancel this carry.
40 addcc %o1,%o1,%o1 ! shift n1n0 and a 0-bit in lsb
43 ! End of inline udiv_qrnnd
62 addxcc %o2,%o2,%o2 ! shift n1n0 and a q-bit in lsb
63 sub %o4,%o3,%o4 ! this kills msb of n
64 addx %o4,%o4,%o4 ! so this cannot give carry
69 addxcc %o2,%o2,%o2 ! shift n1n0 and a q-bit in lsb
71 sub %o4,%o3,%o4 ! this kills msb of n
76 ! Got carry from n. Subtract next step to cancel this carry.
78 addcc %o2,%o2,%o2 ! shift n1n0 and a 0-bit in lsb
81 ! End of inline udiv_qrnnd
88 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
89 sub %i0,%o3,%i0 ! this kills msb of n
90 addx %i0,%i0,%i0 ! so this cannot give carry
95 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
97 sub %i0,%o3,%i0 ! this kills msb of n
102 ! Got carry from n. Subtract next step to cancel this carry.
104 addcc %o1,%o1,%o1 ! shift n1n0 and a 0-bit in lsb
107 ! End of inline udiv_qrnnd
117 or %o0,%lo(65535),%o0
126 sethi %hi(16777215),%o0
127 or %o0,%lo(16777215),%o0
134 sethi %hi(__clz_tab),%o0
135 or %o0,%lo(__clz_tab),%o0
167 addxcc %o5,%o5,%o5 ! shift n1n0 and a q-bit in lsb
168 sub %o4,%i2,%o4 ! this kills msb of n
169 addx %o4,%o4,%o4 ! so this cannot give carry
174 addxcc %o5,%o5,%o5 ! shift n1n0 and a q-bit in lsb
176 sub %o4,%i2,%o4 ! this kills msb of n
178 5: addxcc %o4,%o4,%o4
181 ! Got carry from n. Subtract next step to cancel this carry.
183 addcc %o5,%o5,%o5 ! shift n1n0 and a 0-bit in lsb
186 ! End of inline udiv_qrnnd
190 wr %g0,%o1,%y ! SPARC has 0-3 delay insn after a wr
191 sra %o3,31,%g2 ! Do not move this insn
192 and %o1,%g2,%g2 ! Do not move this insn
193 andcc %g0,0,%g1 ! Do not move this insn