	zpage	btmp0
	zpage	btmp1
	zpage	btmp2
	zpage	r30
	zpage	r31
	zpage	___m65mathptr

	global	___moduint32

	section	text
___moduint32:
	ldq	btmp0
	stq	$d770
	ldq	btmp1
	stq	$d774
	lda	$d76c
        lda     $d76c
        lda     $d76c
        lda     $d76c
	ldq     $d76c
	stq	$d770		; x/y into op1, y still in op2
	ldq	btmp0		; x
	sec
	sbcq	$d778 ; x-(x/y)*y
	stq	btmp0
	ldz	#0
	rts
