Annotation of OpenXM_contrib/gmp/mpn/ia64/copyd.asm, Revision 1.1
1.1 ! ohara 1: dnl IA-64 mpn_copyd -- copy limb vector, decrementing.
! 2:
! 3: dnl Copyright 2001, 2002 Free Software Foundation, Inc.
! 4:
! 5: dnl This file is part of the GNU MP Library.
! 6:
! 7: dnl The GNU MP Library is free software; you can redistribute it and/or modify
! 8: dnl it under the terms of the GNU Lesser General Public License as published
! 9: dnl by the Free Software Foundation; either version 2.1 of the License, or (at
! 10: dnl your option) any later version.
! 11:
! 12: dnl The GNU MP Library is distributed in the hope that it will be useful, but
! 13: dnl WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
! 14: dnl or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
! 15: dnl License for more details.
! 16:
! 17: dnl You should have received a copy of the GNU Lesser General Public License
! 18: dnl along with the GNU MP Library; see the file COPYING.LIB. If not, write to
! 19: dnl the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
! 20: dnl MA 02111-1307, USA.
! 21:
! 22: include(`../config.m4')
! 23:
! 24: C INPUT PARAMETERS
! 25: C rp = r32
! 26: C sp = r33
! 27: C n = r34
! 28:
! 29: ASM_START()
! 30: PROLOGUE(mpn_copyd)
! 31: .prologue
! 32: .save ar.lc, r2
! 33: mov r2 = ar.lc
! 34: .body
! 35: ifdef(`HAVE_ABI_32',
! 36: ` addp4 r32 = 0, r32
! 37: addp4 r33 = 0, r33
! 38: sxt4 r34 = r34
! 39: ;;
! 40: ')
! 41: and r14 = 3, r34
! 42: cmp.ge p14, p15 = 3, r34
! 43: add r34 = -1, r34
! 44: ;;
! 45: cmp.eq p8, p9 = 1, r14
! 46: shladd r32 = r34, 3, r32
! 47: shladd r33 = r34, 3, r33
! 48: add r34 = -3, r34
! 49: cmp.eq p10, p11 = 2, r14
! 50: cmp.eq p12, p13 = 3, r14
! 51: ;;
! 52: (p8) br.dptk .Lb01
! 53: (p10) br.dptk .Lb10
! 54: (p12) br.dptk .Lb11
! 55:
! 56: .Lb00: C n = 4, 8, 12, ...
! 57: (p14) br.dptk .Ls00
! 58: ;;
! 59: ld8 r16 = [r33], -8
! 60: shr r15 = r34, 2
! 61: ;;
! 62: ld8 r17 = [r33], -8
! 63: mov ar.lc = r15
! 64: ;;
! 65: ld8 r18 = [r33], -8
! 66: ;;
! 67: ld8 r19 = [r33], -8
! 68: br.cloop.dptk .Loop
! 69: ;;
! 70: br.sptk .Lend
! 71: ;;
! 72:
! 73: .Lb01: C n = 1, 5, 9, 13, ...
! 74: ld8 r19 = [r33], -8
! 75: shr r15 = r34, 2
! 76: (p14) br.dptk .Ls01
! 77: ;;
! 78: ld8 r16 = [r33], -8
! 79: mov ar.lc = r15
! 80: ;;
! 81: ld8 r17 = [r33], -8
! 82: ;;
! 83: ld8 r18 = [r33], -8
! 84: br.sptk .Li01
! 85: ;;
! 86:
! 87: .Lb10: C n = 2,6, 10, 14, ...
! 88: ld8 r18 = [r33], -8
! 89: shr r15 = r34, 2
! 90: ;;
! 91: ld8 r19 = [r33], -8
! 92: mov ar.lc = r15
! 93: (p14) br.dptk .Ls10
! 94: ;;
! 95: ld8 r16 = [r33], -8
! 96: ;;
! 97: ld8 r17 = [r33], -8
! 98: br.sptk .Li10
! 99: ;;
! 100:
! 101: .Lb11: C n = 3, 7, 11, 15, ...
! 102: ld8 r17 = [r33], -8
! 103: shr r15 = r34, 2
! 104: ;;
! 105: ld8 r18 = [r33], -8
! 106: mov ar.lc = r15
! 107: ;;
! 108: ld8 r19 = [r33], -8
! 109: (p14) br.dptk .Ls11
! 110: ;;
! 111: ld8 r16 = [r33], -8
! 112: br.sptk .Li11
! 113: ;;
! 114:
! 115: .Loop:
! 116: .Li00:
! 117: { .mmb; st8 [r32] = r16, -8
! 118: ld8 r16 = [r33], -8
! 119: ;;
! 120: }
! 121: .Li11:
! 122: { .mmb; st8 [r32] = r17, -8
! 123: ld8 r17 = [r33], -8
! 124: ;;
! 125: }
! 126: .Li10:
! 127: { .mmb; st8 [r32] = r18, -8
! 128: ld8 r18 = [r33], -8
! 129: ;;
! 130: }
! 131: .Li01:
! 132: { .mmb; st8 [r32] = r19, -8
! 133: ld8 r19 = [r33], -8
! 134: br.cloop.dptk .Loop
! 135: ;;
! 136: }
! 137: .Lend: st8 [r32] = r16, -8
! 138: ;;
! 139: .Ls11: st8 [r32] = r17, -8
! 140: ;;
! 141: .Ls10: st8 [r32] = r18, -8
! 142: ;;
! 143: .Ls01: st8 [r32] = r19, -8
! 144: .Ls00:
! 145: mov ar.lc = r2
! 146: br.ret.sptk.many rp
! 147: EPILOGUE(mpn_copyd)
! 148: ASM_END()
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>