Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
MorsGames
GitHub Repository: MorsGames/sm64plus
Path: blob/master/asm/entry.s
7854 views
1
// assembler directives
2
.set noat // allow manual use of $at
3
.set noreorder // don't insert nops after branches
4
.set gp=64
5
6
#include "macros.inc"
7
8
9
.section .text, "ax"
10
11
glabel entry_point
12
lui $t0, %hi(_mainSegmentNoloadStart) // $t0, 0x8034
13
lui $t1, %lo(_mainSegmentNoloadSizeHi) // lui $t1, 2
14
addiu $t0, %lo(_mainSegmentNoloadStart) // addiu $t0, $t0, -0x6df0
15
ori $t1, %lo(_mainSegmentNoloadSizeLo) // ori $t1, $t1, 0xcee0
16
.L80246010:
17
addi $t1, $t1, -8
18
sw $zero, ($t0)
19
sw $zero, 4($t0)
20
bnez $t1, .L80246010
21
addi $t0, $t0, 8
22
lui $t2, %hi(main_func) // $t2, 0x8024
23
lui $sp, %hi(gIdleThreadStack) // $sp, 0x8020
24
addiu $t2, %lo(main_func) // addiu $t2, $t2, 0x6dc4
25
jr $t2
26
addiu $sp, %lo(gIdleThreadStack) // addiu $sp, $sp, 0xa00
27
nop
28
nop
29
nop
30
nop
31
nop
32
nop
33
34