	.include	"features.inc"
	.section	.text
	.global	zstr_len
	.syntax	divided
	.type	zstr_len, %function
zstr_len:
	mov	r1, r0			@ pointer = string
	b	zstr_len.loop
zstr_len.increment:
	add	r1, r1, #1		@ pointer = pointer + 1
zstr_len.loop:
	ldrb	r2, [r1]
	cmp	r2, #0
	bne	zstr_len.increment	@ pointer, dereferenced <> 0
	sub	r0, r1, r0		@ Return pointer - string
	RET
