diff options
| author | lameguy64 <lameguy64@gmail.com> | 2019-05-23 22:24:56 +0800 |
|---|---|---|
| committer | lameguy64 <lameguy64@gmail.com> | 2019-05-23 22:24:56 +0800 |
| commit | 3ffebff2aad2ca438cf76db51fb3459c5639cd67 (patch) | |
| tree | a234fc6158d3c09904c4c1fb2feee09afb479a4c /libpsn00b/libc | |
| parent | e70cd149f41ea71f9ca9ee86c03d1e59005dad2a (diff) | |
| download | psn00bsdk-3ffebff2aad2ca438cf76db51fb3459c5639cd67.tar.gz | |
Added BIOS Controller, BIOS CD, 2 new examples and custom exit handler in the works
Diffstat (limited to 'libpsn00b/libc')
| -rw-r--r-- | libpsn00b/libc/readme.txt | 4 | ||||
| -rw-r--r-- | libpsn00b/libc/start.s | 16 |
2 files changed, 11 insertions, 9 deletions
diff --git a/libpsn00b/libc/readme.txt b/libpsn00b/libc/readme.txt index d7abf0a..064a353 100644 --- a/libpsn00b/libc/readme.txt +++ b/libpsn00b/libc/readme.txt @@ -45,4 +45,6 @@ Todo list: Changelog: - None thus far... + 05-23-2019 by Lameguy64: + + * Made stack usage a lot less wastefull in _start entrypoint. diff --git a/libpsn00b/libc/start.s b/libpsn00b/libc/start.s index c9b529b..d08a2c7 100644 --- a/libpsn00b/libc/start.s +++ b/libpsn00b/libc/start.s @@ -1,5 +1,5 @@ # Start function! -# This is essentially the entrypoint of the PS-EXE +# This is essentially the entry point of the PS-EXE .set noreorder @@ -8,11 +8,10 @@ .global _start .type _start, @function _start: - - addiu $sp, -32 - sw $ra, 28($sp) + addiu $sp, -4 + sw $ra, 0($sp) - la $gp, _gp # Very important to set! + la $gp, _gp # Very important! la $a0, .bss # What are the CORRECT symbols for BSS start and end? la $a1, _end @@ -30,10 +29,11 @@ _start: move $a1, $0 jal main - nop + addiu $sp, -8 + addiu $sp, 8 - lw $ra, 28($sp) - addiu $sp, 32 + lw $ra, 0($sp) # Return + addiu $sp, 4 jr $ra nop
\ No newline at end of file |
