1 /* Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
3 This file is part of GNU CC.
5 GNU CC is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2, or (at your option)
10 GNU CC is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with GNU CC; see the file COPYING. If not, write to
17 the Free Software Foundation, 59 Temple Place - Suite 330,
18 Boston, MA 02111-1307, USA. */
59 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
60 sub %i0,%o4,%i0 ! this kills msb of n
61 addx %i0,%i0,%i0 ! so this cannot give carry
66 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
68 sub %i0,%o4,%i0 ! this kills msb of n
73 ! Got carry from n. Subtract next step to cancel this carry.
75 addcc %o1,%o1,%o1 ! shift n1n0 and a 0-bit in lsb
95 addxcc %o2,%o2,%o2 ! shift n1n0 and a q-bit in lsb
96 sub %g3,%o4,%g3 ! this kills msb of n
97 addx %g3,%g3,%g3 ! so this cannot give carry
102 addxcc %o2,%o2,%o2 ! shift n1n0 and a q-bit in lsb
104 sub %g3,%o4,%g3 ! this kills msb of n
106 5: addxcc %g3,%g3,%g3
109 ! Got carry from n. Subtract next step to cancel this carry.
111 addcc %o2,%o2,%o2 ! shift n1n0 and a 0-bit in lsb
119 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
120 sub %i0,%o4,%i0 ! this kills msb of n
121 addx %i0,%i0,%i0 ! so this cannot give carry
126 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
128 sub %i0,%o4,%i0 ! this kills msb of n
130 5: addxcc %i0,%i0,%i0
133 ! Got carry from n. Subtract next step to cancel this carry.
135 addcc %o1,%o1,%o1 ! shift n1n0 and a 0-bit in lsb
147 or %o0,%lo(65535),%o0
156 sethi %hi(16777215),%o0
157 or %o0,%lo(16777215),%o0
164 sethi %hi(__clz_tab),%o1
165 or %o1,%lo(__clz_tab),%o1
194 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
195 sub %o2,%i2,%o2 ! this kills msb of n
196 addx %o2,%o2,%o2 ! so this cannot give carry
201 addxcc %o1,%o1,%o1 ! shift n1n0 and a q-bit in lsb
203 sub %o2,%i2,%o2 ! this kills msb of n
205 5: addxcc %o2,%o2,%o2
208 ! Got carry from n. Subtract next step to cancel this carry.
210 addcc %o1,%o1,%o1 ! shift n1n0 and a 0-bit in lsb
214 wr %g0,%o1,%y ! SPARC has 0-3 delay insn after a wr
215 sra %o4,31,%g2 ! Do not move this insn
216 and %o1,%g2,%g2 ! Do not move this insn
217 andcc %g0,0,%g1 ! Do not move this insn