~ubuntu-branches/ubuntu/precise/gnupg2/precise-proposed

« back to all changes in this revision

Viewing changes to mpi/pa7100/mpih-lshift.S

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Urlichs
  • Date: 2006-01-24 04:31:42 UTC
  • mfrom: (1.1.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20060124043142-pbg192or6qxv3yk2
Tags: 1.9.20-1
* New Upstream version. Closes:#306890,#344530
  * Closes:#320490: gpg-protect-tool fails to decrypt PKCS-12 files 
* Depend on libopensc2-dev, not -1-. Closes:#348106

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* hppa   lshift
 
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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
 
22
 */
 
23
 
 
24
 
 
25
 
 
26
/*******************
 
27
 * mpi_limb_t
 
28
 * mpihelp_lshift( mpi_ptr_t wp,        (gr26)
 
29
 *                 mpi_ptr_t up,        (gr25)
 
30
 *                 mpi_size_t usize,    (gr24)
 
31
 *                 unsigned cnt)        (gr23)
 
32
 */
 
33
 
 
34
        .code
 
35
        .export         mpihelp_lshift
 
36
        .label          mpihelp_lshift
 
37
        .proc
 
38
        .callinfo       frame=64,no_calls
 
39
        .entry
 
40
 
 
41
        sh2add          %r24,%r25,%r25
 
42
        sh2add          %r24,%r26,%r26
 
43
        ldws,mb         -4(0,%r25),%r22
 
44
        subi            32,%r23,%r1
 
45
        mtsar           %r1
 
46
        addib,=         -1,%r24,L$0004
 
47
        vshd            %r0,%r22,%r28           ; compute carry out limb
 
48
        ldws,mb         -4(0,%r25),%r29
 
49
        addib,<=        -5,%r24,L$rest
 
50
        vshd            %r22,%r29,%r20
 
51
 
 
52
        .label  L$loop
 
53
        ldws,mb         -4(0,%r25),%r22
 
54
        stws,mb         %r20,-4(0,%r26)
 
55
        vshd            %r29,%r22,%r20
 
56
        ldws,mb         -4(0,%r25),%r29
 
57
        stws,mb         %r20,-4(0,%r26)
 
58
        vshd            %r22,%r29,%r20
 
59
        ldws,mb         -4(0,%r25),%r22
 
60
        stws,mb         %r20,-4(0,%r26)
 
61
        vshd            %r29,%r22,%r20
 
62
        ldws,mb         -4(0,%r25),%r29
 
63
        stws,mb         %r20,-4(0,%r26)
 
64
        addib,>         -4,%r24,L$loop
 
65
        vshd            %r22,%r29,%r20
 
66
 
 
67
        .label  L$rest
 
68
        addib,=         4,%r24,L$end1
 
69
        nop
 
70
        .label  L$eloop
 
71
        ldws,mb         -4(0,%r25),%r22
 
72
        stws,mb         %r20,-4(0,%r26)
 
73
        addib,<=        -1,%r24,L$end2
 
74
        vshd            %r29,%r22,%r20
 
75
        ldws,mb         -4(0,%r25),%r29
 
76
        stws,mb         %r20,-4(0,%r26)
 
77
        addib,>         -1,%r24,L$eloop
 
78
        vshd            %r22,%r29,%r20
 
79
 
 
80
        .label  L$end1
 
81
        stws,mb         %r20,-4(0,%r26)
 
82
        vshd            %r29,%r0,%r20
 
83
        bv              0(%r2)
 
84
        stw             %r20,-4(0,%r26)
 
85
        .label  L$end2
 
86
        stws,mb         %r20,-4(0,%r26)
 
87
        .label  L$0004
 
88
        vshd            %r22,%r0,%r20
 
89
        bv              0(%r2)
 
90
        stw             %r20,-4(0,%r26)
 
91
 
 
92
        .exit
 
93
        .procend
 
94
 
 
95
 
 
96