New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use SD card as swapfile #62
Comments
There's a branch that does this here: https://github.com/espruino/Espruino/tree/variable_cache It's still far from perfect:
But it proves that it can be done - and without hacking everything around so much that it doesn't run on 'normal' devices. |
related comment here: #817 (comment) |
|
No... but building for linux and doing I can't remember if this branch needs it, but you might want to edit build_platform_config and remove the RESIZABLE_JSVARS line. |
Killing this due to lack of interest - I guess variable_cache might still happen but honestly it's so easy to find boards with decent amounts of RAM/ROM built in now this isn't a big deal |
Espruino's fixed-size JsVar blocks were designed for this, but it was never implemented.
You'd have to change jsVarCache, jsvLock and jsvUnLock, and then store only the most-used (and locked) JsVars in RAM - writing the rest onto the SD card. Probably quite a lot of work, but it'd be epic.
It would kill Garbage Collection speed (it might need a re-write?) but then if you had basically infinite memory that's not a huge issue.
The text was updated successfully, but these errors were encountered: