3
* Copyright (C) 1995, 1998 Free Software Foundation, Inc.
5
* This file is part of GnuPG.
7
* GnuPG is free software; you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation; either version 2 of the License, or
10
* (at your option) any later version.
12
* GnuPG is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
17
* You should have received a copy of the GNU General Public License
18
* along with this program; if not, write to the Free Software
19
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
24
#include "asm-syntax.h"
27
#ifndef USE_PPC_PATCHES
31
* mpihelp_rshift( mpi_ptr_t wp, (r3)
33
* mpi_size_t usize, (r5)
41
.globl .mpihelp_rshift
42
.csect mpihelp_rshift[DS]
44
.long .mpihelp_rshift, TOC[tc0], 0
47
mtctr 5 # copy size into CTR
48
addi 7,3,-4 # move adjusted res_ptr to free return reg
50
lwz 11,0(4) # load first s1 limb
51
slw 3,11,8 # compute function return value
76
/* Shift a limb right, low level routine.
77
Copyright (C) 1995, 1997 Free Software Foundation, Inc.
78
This file is part of the GNU C Library.
80
The GNU C Library is free software; you can redistribute it and/or
81
modify it under the terms of the GNU Library General Public License as
82
published by the Free Software Foundation; either version 2 of the
83
License, or (at your option) any later version.
85
The GNU C Library is distributed in the hope that it will be useful,
86
but WITHOUT ANY WARRANTY; without even the implied warranty of
87
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
88
Library General Public License for more details.
90
You should have received a copy of the GNU Library General Public
91
License along with the GNU C Library; see the file COPYING.LIB. If not,
92
write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
93
Boston, MA 02111-1307, USA. */
102
ENTRY(mpihelp_rshift)
103
mtctr 5 # copy size into CTR
104
addi 7,3,-4 # move adjusted res_ptr to free return reg
106
lwz 11,0(4) # load first s1 limb
107
slw 3,11,8 # compute function return value