riscv32-unknown-elf-gcc bootstrap.S main.c uart.c -o main -march=rv32i -mabi=ilp32 -nostartfiles -Wl,--no-relax -T link.ld
riscv32-unknown-elf-objdump -D main

main:     Dateiformat elf32-littleriscv


Disassembly of section .text:

80000000 <_start>:
80000000:	000070b3          	and	ra,zero,zero
80000004:	00007133          	and	sp,zero,zero
80000008:	000071b3          	and	gp,zero,zero
8000000c:	00007233          	and	tp,zero,zero
80000010:	000072b3          	and	t0,zero,zero
80000014:	00007333          	and	t1,zero,zero
80000018:	000073b3          	and	t2,zero,zero
8000001c:	00007433          	and	s0,zero,zero
80000020:	000074b3          	and	s1,zero,zero
80000024:	00007533          	and	a0,zero,zero
80000028:	000075b3          	and	a1,zero,zero
8000002c:	00007633          	and	a2,zero,zero
80000030:	000076b3          	and	a3,zero,zero
80000034:	00007733          	and	a4,zero,zero
80000038:	000077b3          	and	a5,zero,zero
8000003c:	00007833          	and	a6,zero,zero
80000040:	000078b3          	and	a7,zero,zero
80000044:	00007933          	and	s2,zero,zero
80000048:	000079b3          	and	s3,zero,zero
8000004c:	00007a33          	and	s4,zero,zero
80000050:	00007ab3          	and	s5,zero,zero
80000054:	00007b33          	and	s6,zero,zero
80000058:	00007bb3          	and	s7,zero,zero
8000005c:	00007c33          	and	s8,zero,zero
80000060:	00007cb3          	and	s9,zero,zero
80000064:	00007d33          	and	s10,zero,zero
80000068:	00007db3          	and	s11,zero,zero
8000006c:	00007e33          	and	t3,zero,zero
80000070:	00007eb3          	and	t4,zero,zero
80000074:	00007f33          	and	t5,zero,zero
80000078:	00007fb3          	and	t6,zero,zero
8000007c:	00000117          	auipc	sp,0x0
80000080:	42010113          	addi	sp,sp,1056 # 8000049c <wait>
80000084:	460000ef          	jal	ra,800004e4 <main>
80000088:	05d00893          	li	a7,93
8000008c:	00000513          	li	a0,0
80000090:	020102b7          	lui	t0,0x2010
80000094:	f1402873          	csrr	a6,mhartid
80000098:	0102a023          	sw	a6,0(t0) # 2010000 <SYSCALL_ADDR>

8000009c <stack_begin>:
	...

8000049c <wait>:
8000049c:	fd010113          	addi	sp,sp,-48
800004a0:	02812623          	sw	s0,44(sp)
800004a4:	03010413          	addi	s0,sp,48
800004a8:	fca42e23          	sw	a0,-36(s0)
800004ac:	fe042623          	sw	zero,-20(s0)
800004b0:	0140006f          	j	800004c4 <wait+0x28>
800004b4:	00000013          	nop
800004b8:	fec42783          	lw	a5,-20(s0)
800004bc:	00178793          	addi	a5,a5,1
800004c0:	fef42623          	sw	a5,-20(s0)
800004c4:	fec42703          	lw	a4,-20(s0)
800004c8:	fdc42783          	lw	a5,-36(s0)
800004cc:	fef764e3          	bltu	a4,a5,800004b4 <wait+0x18>
800004d0:	00000013          	nop
800004d4:	00000013          	nop
800004d8:	02c12403          	lw	s0,44(sp)
800004dc:	03010113          	addi	sp,sp,48
800004e0:	00008067          	ret

800004e4 <main>:
800004e4:	fd010113          	addi	sp,sp,-48
800004e8:	02112623          	sw	ra,44(sp)
800004ec:	02812423          	sw	s0,40(sp)
800004f0:	03010413          	addi	s0,sp,48
800004f4:	fca42e23          	sw	a0,-36(s0)
800004f8:	fcb42c23          	sw	a1,-40(s0)
800004fc:	00100793          	li	a5,1
80000500:	fef407a3          	sb	a5,-17(s0)
80000504:	fe040723          	sb	zero,-18(s0)
80000508:	fe0406a3          	sb	zero,-19(s0)
8000050c:	800017b7          	lui	a5,0x80001
80000510:	0187a783          	lw	a5,24(a5) # 80001018 <_end+0xffffffd0>
80000514:	0007a023          	sw	zero,0(a5)
80000518:	800017b7          	lui	a5,0x80001
8000051c:	0207a783          	lw	a5,32(a5) # 80001020 <_end+0xffffffd8>
80000520:	0007a783          	lw	a5,0(a5)
80000524:	fef40723          	sb	a5,-18(s0)
80000528:	fee44783          	lbu	a5,-18(s0)
8000052c:	02079663          	bnez	a5,80000558 <main+0x74>
80000530:	fef44703          	lbu	a4,-17(s0)
80000534:	08000793          	li	a5,128
80000538:	00f71863          	bne	a4,a5,80000548 <main+0x64>
8000053c:	00100793          	li	a5,1
80000540:	fef407a3          	sb	a5,-17(s0)
80000544:	0380006f          	j	8000057c <main+0x98>
80000548:	fef44783          	lbu	a5,-17(s0)
8000054c:	00179793          	slli	a5,a5,0x1
80000550:	fef407a3          	sb	a5,-17(s0)
80000554:	0280006f          	j	8000057c <main+0x98>
80000558:	fef44703          	lbu	a4,-17(s0)
8000055c:	00100793          	li	a5,1
80000560:	00f71863          	bne	a4,a5,80000570 <main+0x8c>
80000564:	f8000793          	li	a5,-128
80000568:	fef407a3          	sb	a5,-17(s0)
8000056c:	0100006f          	j	8000057c <main+0x98>
80000570:	fef44783          	lbu	a5,-17(s0)
80000574:	0017d793          	srli	a5,a5,0x1
80000578:	fef407a3          	sb	a5,-17(s0)
8000057c:	800017b7          	lui	a5,0x80001
80000580:	0007a783          	lw	a5,0(a5) # 80001000 <_end+0xffffffb8>
80000584:	fef44703          	lbu	a4,-17(s0)
80000588:	00e7a023          	sw	a4,0(a5)
8000058c:	000117b7          	lui	a5,0x11
80000590:	17078513          	addi	a0,a5,368 # 11170 <SYSCALL_ADDR-0x1ffee90>
80000594:	00000097          	auipc	ra,0x0
80000598:	f08080e7          	jalr	-248(ra) # 8000049c <wait>
8000059c:	f7dff06f          	j	80000518 <main+0x34>

800005a0 <sendString>:
800005a0:	fd010113          	addi	sp,sp,-48
800005a4:	02112623          	sw	ra,44(sp)
800005a8:	02812423          	sw	s0,40(sp)
800005ac:	03010413          	addi	s0,sp,48
800005b0:	fca42e23          	sw	a0,-36(s0)
800005b4:	fcb42c23          	sw	a1,-40(s0)
800005b8:	fd842783          	lw	a5,-40(s0)
800005bc:	fef42623          	sw	a5,-20(s0)
800005c0:	fdc42783          	lw	a5,-36(s0)
800005c4:	fef42423          	sw	a5,-24(s0)
800005c8:	0300006f          	j	800005f8 <sendString+0x58>
800005cc:	fec42783          	lw	a5,-20(s0)
800005d0:	fff78793          	addi	a5,a5,-1
800005d4:	fef42623          	sw	a5,-20(s0)
800005d8:	fe842783          	lw	a5,-24(s0)
800005dc:	0007c783          	lbu	a5,0(a5)
800005e0:	00078513          	mv	a0,a5
800005e4:	00000097          	auipc	ra,0x0
800005e8:	034080e7          	jalr	52(ra) # 80000618 <putChr>
800005ec:	fe842783          	lw	a5,-24(s0)
800005f0:	00178793          	addi	a5,a5,1
800005f4:	fef42423          	sw	a5,-24(s0)
800005f8:	fec42783          	lw	a5,-20(s0)
800005fc:	fcf048e3          	bgtz	a5,800005cc <sendString+0x2c>
80000600:	fd842783          	lw	a5,-40(s0)
80000604:	00078513          	mv	a0,a5
80000608:	02c12083          	lw	ra,44(sp)
8000060c:	02812403          	lw	s0,40(sp)
80000610:	03010113          	addi	sp,sp,48
80000614:	00008067          	ret

80000618 <putChr>:
80000618:	fd010113          	addi	sp,sp,-48
8000061c:	02812623          	sw	s0,44(sp)
80000620:	03010413          	addi	s0,sp,48
80000624:	00050793          	mv	a5,a0
80000628:	fcf40fa3          	sb	a5,-33(s0)
8000062c:	fe042623          	sw	zero,-20(s0)
80000630:	800017b7          	lui	a5,0x80001
80000634:	0287a783          	lw	a5,40(a5) # 80001028 <_end+0xffffffe0>
80000638:	fdf44703          	lbu	a4,-33(s0)
8000063c:	00e7a023          	sw	a4,0(a5)
80000640:	800017b7          	lui	a5,0x80001
80000644:	02c7a783          	lw	a5,44(a5) # 8000102c <_end+0xffffffe4>
80000648:	00100713          	li	a4,1
8000064c:	00e7a023          	sw	a4,0(a5)
80000650:	800017b7          	lui	a5,0x80001
80000654:	02c7a783          	lw	a5,44(a5) # 8000102c <_end+0xffffffe4>
80000658:	0007a783          	lw	a5,0(a5)
8000065c:	fef42623          	sw	a5,-20(s0)
80000660:	00000013          	nop
80000664:	fec42783          	lw	a5,-20(s0)
80000668:	fe0784e3          	beqz	a5,80000650 <putChr+0x38>
8000066c:	00000013          	nop
80000670:	02c12403          	lw	s0,44(sp)
80000674:	03010113          	addi	sp,sp,48
80000678:	00008067          	ret

Disassembly of section .sdata:

80001000 <LED_ADDR>:
80001000:	0000                	unimp
80001002:	8100                	0x8100

80001004 <UART_TX_DATA_ADDR>:
80001004:	0000                	unimp
80001006:	8200                	0x8200

80001008 <UART_TX_CTRL_ADDR>:
80001008:	0004                	0x4
8000100a:	8200                	0x8200

8000100c <UART_RX_DATA_ADDR>:
8000100c:	0008                	0x8
8000100e:	8200                	0x8200

80001010 <MTIMECMP_REG>:
80001010:	4000                	lw	s0,0(s0)
80001012:	0200                	addi	s0,sp,256

80001014 <MTIME_REG>:
80001014:	bff8                	fsd	fa4,248(a5)
80001016:	0200                	addi	s0,sp,256

80001018 <GPIO_BANK_A_DIRECTION_ADDR>:
80001018:	0000                	unimp
8000101a:	8300                	0x8300

8000101c <GPIO_BANK_A_OUTPUT_ADDR>:
8000101c:	0004                	0x4
8000101e:	8300                	0x8300

80001020 <GPIO_BANK_A_INPUT_ADDR>:
80001020:	0008                	0x8
80001022:	8300                	0x8300

80001024 <LED_ADDR>:
80001024:	0000                	unimp
80001026:	8100                	0x8100

80001028 <UART_TX_DATA_ADDR>:
80001028:	0000                	unimp
8000102a:	8200                	0x8200

8000102c <UART_TX_CTRL_ADDR>:
8000102c:	0004                	0x4
8000102e:	8200                	0x8200

80001030 <UART_RX_DATA_ADDR>:
80001030:	0008                	0x8
80001032:	8200                	0x8200

80001034 <MTIMECMP_REG>:
80001034:	4000                	lw	s0,0(s0)
80001036:	0200                	addi	s0,sp,256

80001038 <MTIME_REG>:
80001038:	bff8                	fsd	fa4,248(a5)
8000103a:	0200                	addi	s0,sp,256

8000103c <GPIO_BANK_A_DIRECTION_ADDR>:
8000103c:	0000                	unimp
8000103e:	8300                	0x8300

80001040 <GPIO_BANK_A_OUTPUT_ADDR>:
80001040:	0004                	0x4
80001042:	8300                	0x8300

80001044 <GPIO_BANK_A_INPUT_ADDR>:
80001044:	0008                	0x8
80001046:	8300                	0x8300

Disassembly of section .riscv.attributes:

00000000 <.riscv.attributes>:
   0:	1f41                	addi	t5,t5,-16
   2:	0000                	unimp
   4:	7200                	flw	fs0,32(a2)
   6:	7369                	lui	t1,0xffffa
   8:	01007663          	bgeu	zero,a6,14 <SYSCALL_ADDR-0x200ffec>
   c:	0015                	c.nop	5
   e:	0000                	unimp
  10:	1004                	addi	s1,sp,32
  12:	7205                	lui	tp,0xfffe1
  14:	3376                	fld	ft6,376(sp)
  16:	6932                	flw	fs2,12(sp)
  18:	7032                	flw	ft0,44(sp)
  1a:	0030                	addi	a2,sp,8
  1c:	0108                	addi	a0,sp,128
  1e:	0b0a                	slli	s6,s6,0x2

Disassembly of section .comment:

00000000 <.comment>:
   0:	3a434347          	fmsub.d	ft6,ft6,ft4,ft7,rmm
   4:	2820                	fld	fs0,80(s0)
   6:	29554e47          	fmsub.s	ft8,fa0,fs5,ft5,rmm
   a:	3120                	fld	fs0,96(a0)
   c:	2e30                	fld	fa2,88(a2)
   e:	2e32                	fld	ft8,264(sp)
  10:	0030                	addi	a2,sp,8
