1 ! Copyright
(c
) 2000, 2002, 2006 MySQL AB
3 ! This library is free software; you can redistribute it
and/or
4 ! modify it under the terms of the GNU Library General Public
5 ! License as published by the Free Software Foundation; version
2
8 ! This library is distributed in the hope that it will
be useful
,
9 ! but WITHOUT ANY WARRANTY; without even the implied warranty of
10 ! MERCHANTABILITY
or FITNESS FOR
A PARTICULAR PURPOSE. See the GNU
11 ! Library General Public License for more details.
13 ! You should have received
a copy of the GNU Library General Public
14 ! License along with this library; if
not, write to the Free
15 ! Software Foundation
, Inc.
, 51 Franklin Street
, Fifth Floor
, Boston
,
19 ! Note that this function only works on
32 bit sparc systems
20 ! on
64 bits the offsets to
%sp are different
!
22 .file "strxmov-sparc.s"
26 .type strxmov,#function
30 st %o2
, [%sp+
76] ! store
3rd param before other params
31 st %o3
, [%sp+
80] ! store
4th param
" "
32 cmp %o1
, 0 ! check if no from args
33 st %o4
, [%sp+
84] ! store
5th param
35 st %o5
, [%sp+
88] ! store last
36 add %sp
, 76, %o4
! put pointer to
3rd arg
38 ldub
[%o1
], %o5
! set values of src
(o1
)
39 add %o1
, 1, %o1
! inc src
40 stb %o5
, [%o0
] ! and dst (o2
) equal
41 cmp %o5
, 0 ! second while
cmp
43 add %o0
, 1, %o0
! inc
dst
44 ld [%o4
], %o1
! get next param
45 cmp %o1
, 0 ! check if last param
47 add %o4
, 4, %o4
! advance to next param
52 .size strxmov,.strxmov_end-strxmov
53 .ident "Matt Wagner & Monty"