1 dnl SPARC v9 mpn_sub_n for T3
/T4.
3 dnl Contributed to the GNU project by David Miller.
5 dnl Copyright
2013 Free Software Foundation
, Inc.
7 dnl
This file is part of the GNU MP Library.
9 dnl The GNU MP Library is free software
; you can redistribute it and/or modify
10 dnl it under the terms of
either:
12 dnl
* the GNU Lesser General
Public License as published by the Free
13 dnl Software Foundation
; either version 3 of the License, or (at your
14 dnl option
) any later version.
18 dnl
* the GNU General
Public License as published by the Free Software
19 dnl Foundation
; either version 2 of the License, or (at your option) any
22 dnl
or both
in parallel
, as here.
24 dnl The GNU MP Library is distributed
in the hope that it will be useful
, but
25 dnl WITHOUT ANY WARRANTY
; without even the implied warranty of MERCHANTABILITY
26 dnl
or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
Public License
29 dnl You should have received copies of the GNU General
Public License
and the
30 dnl GNU Lesser General
Public License along with the GNU MP Library. If
not,
31 dnl see
https://www.gnu.
org/licenses
/.
33 include(`..
/config.m4
')
46 define(`u0_off', `
%l0
')
47 define(`u1_off', `
%l1
')
48 define(`v0_off', `
%l2
')
49 define(`v1_off', `
%l3
')
50 define(`r0_off', `
%l4
')
51 define(`r1_off', `
%l5
')
52 define(`loop_n', `
%l6
')
56 REGISTER(%g2,#scratch)
57 REGISTER(%g3,#scratch)
87 sub loop_n, -(2 * 8), loop_n
89 sub r0_off, 16, r0_off
90 brgez,pn loop_n, L(loop_tail)
97 ldx [loop_n + v0_off], %o5
99 addxccc(%o4, tmp, %g3)
100 ldx [loop_n + u0_off], %o4
103 stx %g3, [loop_n + r0_off]
105 addxccc(%g5, %g1, tmp)
106 ldx [loop_n + v1_off], %g1
108 ldx [loop_n + u1_off], %g5
109 sub loop_n, -(2 * 8), loop_n
112 stx tmp, [loop_n + r1_off]
118 addxccc(%o4, tmp, %g3)
119 add loop_n, u0_off, up
121 addxccc(%g5, %g1, %g5)
122 add loop_n, r0_off, rp
125 add loop_n, v0_off, vp
127 brgz,pt loop_n, L(done)
136 addxccc(%o4, %o5, %g3)