Skip to content

[WIP] Sdcc4.2.0#6

Open
basxto wants to merge 11 commits intoDonaldHays:masterfrom
basxto:sdcc4.2.0
Open

[WIP] Sdcc4.2.0#6
basxto wants to merge 11 commits intoDonaldHays:masterfrom
basxto:sdcc4.2.0

Conversation

@basxto
Copy link

@basxto basxto commented Feb 4, 2022

4.1.0

Bank           Range             Size   Used   Used%  Free   Free% 
----------     ----------------  -----  -----  -----  -----  -----
ROM            0x0000 -> 0x3FFF  16384  15905    97%    479     2% |.###########################|
ROM_0          0x4000 -> 0x7FFF  16384   1473     8%  14911    91% |##-.........................|
WRAM           0xC000 -> 0xCFFF   4096    190     4%   3906    95% |.--.........................|

4.2.0 (soft freeze;r12975) (old calling convention for handwritten asm 1824d08)

Bank           Range             Size   Used   Used%  Free   Free% 
----------     ----------------  -----  -----  -----  -----  -----
ROM            0x0000 -> 0x3FFF  16384  15905    97%    479     2% |.###########################|
ROM_0          0x4000 -> 0x7FFF  16384   1043     6%  15341    93% |#-..........................|
WRAM           0xC000 -> 0xCFFF   4096    190     4%   3906    95% |.--.........................|

4.2.0 (soft freeze;r12975) (new calling convention for handwritten asm 1824d08)

Bank           Range             Size   Used   Used%  Free   Free% 
----------     ----------------  -----  -----  -----  -----  -----
ROM            0x0000 -> 0x3FFF  16384  15905    97%    479     2% |.###########################|
ROM_0          0x4000 -> 0x7FFF  16384    871     5%  15513    94% |#-..........................|
WRAM           0xC000 -> 0xCFFF   4096    186     4%   3910    95% |.--.........................|

^ for this I modified gbLogUInt8 and gbLogUInt16, hopefully correct since I didn’t check if they still work.
I changed the calling convention of memoryCopy from three variables to one variable and two parameters.
I also changed the loop of memoryCopy to run faster, dec already sets the zero bit. It’s one byte more without that.

@basxto
Copy link
Author

basxto commented Feb 4, 2022

After some more manual optimization:

Bank           Range             Size   Used   Used%  Free   Free% 
----------     ----------------  -----  -----  -----  -----  -----
ROM            0x0000 -> 0x3FFF  16384  15900    97%    484     2% |.###########################|
ROM_0          0x4000 -> 0x7FFF  16384    860     5%  15524    94% |#-..........................|
WRAM           0xC000 -> 0xCFFF   4096    186     4%   3910    95% |.--.........................|

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant