DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - metrics - download
Index: T m n

⟦7fe4d9da1⟧ TextFile

    Length: 812 (0x32c)
    Types: TextFile
    Names: »m16subs.s«, »ns32ksubs.s«

Derivation

└─⟦b20c6495f⟧ Bits:30007238 EUUGD18: Wien-båndet, efterår 1987
    └─⟦this⟧ »EUUGD18/General/Dpy/m16subs.s« 
    └─⟦this⟧ »EUUGD18/General/Dpy/ns32ksubs.s« 

TextFile

; @(#)m16subs.s	1.4	1/28/85
; @(#)Copyright (C) 1985 by D Bell
;
;machine dependent subroutines for the National 32032 microprocessor.
;strdif - return number of bytes until two strings differ or count is reached.
;clear	- from first address up till last address, make memory spaces.

	.program

_strdif::
	movd	16(sp),r0	;byte count
	movd	8(sp),r1	;first string
	movd	12(sp),r2	;second string
	cmpsb			;compare bytes
	subd	8(sp),r1	;get length of search
	movd	r1,r0		;make return value
	rxp	0		;return


_clear::
	movd	12(sp),r0	;ending address
	movd	8(sp),r1	;beginning address
	subd	r1,r0		;compute byte count
	cmpqd	0,r0		;see if any to do
	bge	done		;nope
	addqd	-1,r0		;fix count
	addr	1(r1),r2	;destination address
	movb	32,0(r1)	;start with a blank
	movsb			;fill rest too
done:	rxp	0		;return

	.endseg