* parse-packet.c (dump_sig_subpkt, parse_signature), build-packet.c
[gnupg.git] / mpi / pa7100 / mpih-rshift.S
blob81906f9f8dba0929fb53547b9257f3a277db1926
1 /* hppa   rshift
2  *        optimized for the PA7100, where it runs at 3.25 cycles/limb
3  *
4  *      Copyright (C) 1992, 1994, 1998,
5  *                    2001 Free Software Foundation, Inc.
6  *
7  * This file is part of GnuPG.
8  *
9  * GnuPG is free software; you can redistribute it and/or modify
10  * it under the terms of the GNU General Public License as published by
11  * the Free Software Foundation; either version 2 of the License, or
12  * (at your option) any later version.
13  *
14  * GnuPG is distributed in the hope that it will be useful,
15  * but WITHOUT ANY WARRANTY; without even the implied warranty of
16  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  * GNU General Public License for more details.
18  *
19  * You should have received a copy of the GNU General Public License
20  * along with this program; if not, write to the Free Software
21  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301,
22  * USA.
23  */
27 /*******************
28  * mpi_limb_t
29  * mpihelp_rshift( mpi_ptr_t wp,       (gr26)
30  *                 mpi_ptr_t up,       (gr25)
31  *                 mpi_size_t usize,   (gr24)
32  *                 unsigned cnt)       (gr23)
33  */
35         .code
36         .export         mpihelp_rshift
37         .label          mpihelp_rshift
38         .proc
39         .callinfo       frame=64,no_calls
40         .entry
42         ldws,ma         4(0,%r25),%r22
43         mtsar           %r23
44         addib,=         -1,%r24,L$r004
45         vshd            %r22,%r0,%r28           ; compute carry out limb
46         ldws,ma         4(0,%r25),%r29
47         addib,<=        -5,%r24,L$rrest
48         vshd            %r29,%r22,%r20
50         .label  L$roop
51         ldws,ma         4(0,%r25),%r22
52         stws,ma         %r20,4(0,%r26)
53         vshd            %r22,%r29,%r20
54         ldws,ma         4(0,%r25),%r29
55         stws,ma         %r20,4(0,%r26)
56         vshd            %r29,%r22,%r20
57         ldws,ma         4(0,%r25),%r22
58         stws,ma         %r20,4(0,%r26)
59         vshd            %r22,%r29,%r20
60         ldws,ma         4(0,%r25),%r29
61         stws,ma         %r20,4(0,%r26)
62         addib,>         -4,%r24,L$roop
63         vshd            %r29,%r22,%r20
65         .label  L$rrest
66         addib,=         4,%r24,L$rend1
67         nop
68         .label  L$eroop
69         ldws,ma         4(0,%r25),%r22
70         stws,ma         %r20,4(0,%r26)
71         addib,<=        -1,%r24,L$rend2
72         vshd            %r22,%r29,%r20
73         ldws,ma         4(0,%r25),%r29
74         stws,ma         %r20,4(0,%r26)
75         addib,>         -1,%r24,L$eroop
76         vshd            %r29,%r22,%r20
78         .label  L$rend1
79         stws,ma         %r20,4(0,%r26)
80         vshd            %r0,%r29,%r20
81         bv              0(%r2)
82         stw             %r20,0(0,%r26)
83         .label  L$rend2
84         stws,ma         %r20,4(0,%r26)
85         .label  L$r004
86         vshd            %r0,%r22,%r20
87         bv              0(%r2)
88         stw             %r20,0(0,%r26)
90         .exit
91         .procend