File:  [CSRG BSD Unix] / 43BSDTahoe / usr.lib / libF77 / CCI / s_cat_s.s
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 16:12:58 2018 UTC (8 years, 1 month ago) by root
Branches: MAIN, BSD
CVS tags: HEAD, BSD43tahoe
BSD 4.3tahoe

#	"@(#)s_cat_s.s	5.1 (Berkeley) 11/3/86"

.data
.text
LL0:.align	1
.globl	_s_cat
.set	MASK__,0x1F04
.data
.text
_s_cat:.word	MASK__
movl	8(fp),r12		/* rpp */
movl	20(fp),r10		/* ll */
movl	12(fp),r9		/* pi = &rnp */
shll	$2,*16(fp),r1		/* *np * 4 */
addl3	r1,r9,r8		/* pn = &rnp + *np */
movl	4(fp),r1		/* lp */
jbr	L18			/* for */

L20:
movs3				/* copy nc chars from rp to lp */
addl2	$4,r12			/* rpp++ */
addl2	$4,r9			/* pi++ */

L18:
cmpl	r9,r8			/* pi < pn */
jgequ	L22			/* pn reached - out of loop */
movl	r10,r2			/* nc = ll */
cmpl	(r9),r2			/* if (*pi < nc) */
jgeq	L19
movl	(r9),r2			/* nc = *pi */

L19:
subl2	r2,r10			/* ll -= nc */
movl	(r12),r0		/* rp = *rpp */
jbr	L20

L2000005:			/* pad with spaces */
movb	$32,(r1)
incl	r1

L22:				/* while (--ll >= 0) */
decl	r10
jgeq	L2000005
ret#2


unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.