		.text
		.align  2
		.globl  _start

_start:
		addi a0, x0, 1071
		addi a1, x0, 462
		nop
		nop
		nop
		jal ra, euclidian
		nop
   		nop
   		nop
loop:
		jal x0, loop
		nop
		nop
		nop
        
euclidian:
    add t0, zero, a0
    add t1, zero, a1
    nop
    nop
    nop
sub:
    blt t0, t1, switch
    nop
    nop
    nop
    jal zero, sub
    sub t0, t0, t1 
    nop
    nop
switch:
    beq t0, zero, return
    nop
    nop
    nop
    add t3, zero, t0
    add t0, zero, t1
    nop
    nop
    add t1, zero, t3
    jal zero, sub
    nop
    nop
    nop
return:
    add t0, zero, t1
    jalr x0, ra, 0
    nop
    nop
    nop

    .end _start
	.size _start, .-_start
    