Rockbox Technical Forums

Rockbox General => Rockbox General Discussion => Topic started by: Jason Arthur Taylor on November 14, 2019, 09:13:58 PM

Title: How do you test ram available, and which bootloader and version used least ram?
Post by: Jason Arthur Taylor on November 14, 2019, 09:13:58 PM
It's great news that a new version, 3.15, has come out today.  Well done team.

Which gets me wondering.  Should I upgrade?  Should I not?

It so happens that various rockbox plugins can run into ram issues.  This is largely because many plugins can themselves load arbitrarily large files.  So, I was thinking of downloading all the builds and bootloaders, and seeing which combination results in the most ram.  Is there any way to actually test this number more easily, aside from running a plugin and waiting for it to see if it crashes?

Also, does anyone have any ideas about which bootloader and which rockbox build or version might have the least ram yet still have most of the functionality?   Obviously really old ones have a good shot.  There used to be an adjustable cache setting.  It's too bad that feature was axed.
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: __builtin on November 14, 2019, 09:21:42 PM
Why do you want to do this? Is there a specific plugin that crashes?
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: Jason Arthur Taylor on November 14, 2019, 10:07:53 PM
Why do you want to do this? Is there a specific plugin that crashes?

It's not relevant to my question, but it's all of the plugins that can load plugin-related files of arbitrary size.  Especially the games having those freeware, homegrown levels.  Some of these levels essentially convert games that were action based into board-like games containing puzzles.  Even the old chess program had a ram issue leading to a cool auto-save game feature being axed.  It's the plugins that make Rockbox so awesome.  Not the playing feature.  That's anywhere.
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: saratoga on November 14, 2019, 10:55:28 PM
Bootloader's don't affect memory usage. The build table shows memory usage for recent builds but I don't think really old ones are logged. If you have a really old target, probably very early builds will use less memory since there were less features then. The difference isn't going to be huge though unless you're on a target with extremely little ram.
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: Jason Arthur Taylor on November 16, 2019, 12:49:12 AM
"The build table shows memory usage for recent builds but I don't think really old ones are logged."

Thanks.  I was looking around and the closest I saw were urls like this:

http://build.rockbox.org/data/54e7eaf-clients.html

It says "A detailed build chart is available on rasher's page.", with "rasher's page" linking to http://rasher.dk/rockbox/buildgraphs/graph.php?r=54e7eaf&debug, which says,

"Warning: mysql_connect(): Connection refused in /home/www/rasher.dk/rockbox/buildgraphs/graph.php on line 34
No connection to database (I'm aware of the issue)"

Does anyone know where exactly on the build table is the plugin ram available (or a derivative of it) listed for a target?
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: saratoga on November 16, 2019, 01:24:37 AM
Plugins that need more memory than the static plugin buffer use the audio buffer for memory. That is essentially all of the available memory outside of the main rockbox binary and codec memory.
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: Jason Arthur Taylor on November 19, 2019, 02:27:34 PM
IMO the codec memory should definitely be unloaded too unless it plugins with sound require all of it.
Title: Re: How do you test ram available, and which bootloader and version used least ram?
Post by: saratoga on November 19, 2019, 02:56:49 PM
I can't remember how that is handled on devices that put the codecs in regular dram.