start.S (398B)
1 // Copyright 2022, Brian Swetland <swetland@frotz.net> 2 // Licensed under the Apache License, Version 2.0 3 4 .section ".start" 5 6 .globl _start 7 _start: 8 /* zero BSS */ 9 la t0, __bss_start 10 la t1, __bss_end 11 zero_loop: 12 beq t0, t1, zero_done 13 sw zero, 0(t0) 14 add t0, t0, 4 15 j zero_loop 16 zero_done: 17 18 /* setup initial stack */ 19 la sp, __memory_top 20 21 /* enter C code */ 22 jal start 23 24 /* infinite loop */ 25 j .