Annotation of OpenXM_contrib/gmp/mpn/pa32/hppa2_0/sqr_diagonal.asm, Revision 1.1
1.1 ! ohara 1: dnl HP-PA 32-bit mpn_sqr_diagonal optimized for the PA8x00.
! 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 This code runs at 6 cycles/limb on the PA7100 and 2 cycles/limb on PA8x00.
! 25: C The 2-way unrolling is actually not helping the PA7100.
! 26:
! 27: C INPUT PARAMETERS
! 28: define(`rp',`%r26')
! 29: define(`up',`%r25')
! 30: define(`n',`%r24')
! 31:
! 32: ASM_START()
! 33: PROLOGUE(mpn_sqr_diagonal)
! 34:
! 35: fldws,ma 4(up),%fr4r
! 36: addib,= -1,n,L(end1)
! 37: ldo 4(rp),rp
! 38:
! 39: fldws,ma 4(up),%fr6r
! 40: addib,= -1,n,L(end2)
! 41: xmpyu %fr4r,%fr4r,%fr5
! 42:
! 43: fldws,ma 4(up),%fr4r
! 44: addib,= -1,n,L(end3)
! 45: xmpyu %fr6r,%fr6r,%fr7
! 46:
! 47:
! 48: .label L(loop)
! 49: fldws,ma 4(up),%fr6r
! 50: fstws %fr5r,-4(rp)
! 51: fstws,ma %fr5l,8(rp)
! 52: addib,= -1,n,L(exite)
! 53: xmpyu %fr4r,%fr4r,%fr5
! 54: fldws,ma 4(up),%fr4r
! 55: fstws %fr7r,-4(rp)
! 56: fstws,ma %fr7l,8(rp)
! 57: addib,<> -1,n,L(loop)
! 58: xmpyu %fr6r,%fr6r,%fr7
! 59:
! 60: .label L(exito)
! 61: fstws %fr5r,-4(rp)
! 62: fstws %fr5l,0(rp)
! 63: xmpyu %fr4r,%fr4r,%fr5
! 64: fstws %fr7r,4(rp)
! 65: fstws %fr7l,8(rp)
! 66: fstws,mb %fr5r,12(rp)
! 67: bv 0(%r2)
! 68: fstws %fr5l,4(rp)
! 69:
! 70: .label L(exite)
! 71: fstws %fr7r,-4(rp)
! 72: fstws %fr7l,0(rp)
! 73: xmpyu %fr6r,%fr6r,%fr7
! 74: fstws %fr5r,4(rp)
! 75: fstws %fr5l,8(rp)
! 76: fstws,mb %fr7r,12(rp)
! 77: bv 0(%r2)
! 78: fstws %fr7l,4(rp)
! 79:
! 80: .label L(end1)
! 81: xmpyu %fr4r,%fr4r,%fr5
! 82: fstws %fr5r,-4(rp)
! 83: bv 0(%r2)
! 84: fstws,ma %fr5l,8(rp)
! 85:
! 86: .label L(end2)
! 87: xmpyu %fr6r,%fr6r,%fr7
! 88: fstws %fr5r,-4(rp)
! 89: fstws %fr5l,0(rp)
! 90: fstws %fr7r,4(rp)
! 91: bv 0(%r2)
! 92: fstws %fr7l,8(rp)
! 93:
! 94: .label L(end3)
! 95: fstws %fr5r,-4(rp)
! 96: fstws %fr5l,0(rp)
! 97: xmpyu %fr4r,%fr4r,%fr5
! 98: fstws %fr7r,4(rp)
! 99: fstws %fr7l,8(rp)
! 100: fstws,mb %fr5r,12(rp)
! 101: bv 0(%r2)
! 102: fstws %fr5l,4(rp)
! 103: EPILOGUE(mpn_sqr_diagonal)
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>