Skip to content
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

Let's trim the MAX_PARAM_LEN of event to keep the ram usage down for sequencer #74

Open
bwhitman opened this issue Dec 16, 2023 · 3 comments
Labels
documentation Improvements or additions to documentation

Comments

@bwhitman
Copy link
Collaborator

bwhitman commented Dec 16, 2023

I was able to boot AMY on a Teensy 3.2, which has 64KB RAM. We say it needs "around 100KB" on the webpage, but I bet if you decrease AMY_OSCS to like 8 or 16 you could make it much smaller. Let's find out

@bwhitman
Copy link
Collaborator Author

bwhitman commented Feb 11, 2024

back of the envelope is at 120 oscs and reverb and chorus on, on an arm64 machine, we alloc a total of 117KB.

the sizeof(synthinfo) is 437 bytes.

setting AMY_OSCS to 240, we alloc 177KB instead of 117KB. So 60KB for 120 oscillators, so 0.5 KB / oscillator.

@bwhitman bwhitman added the documentation Improvements or additions to documentation label Aug 16, 2024
@bwhitman
Copy link
Collaborator Author

bwhitman commented Jan 5, 2025

We've grown a bit and should trim the char[255]s:

sizeof synthinfo 720 sizeof event 1256 sizeof delta 24

@bwhitman bwhitman changed the title How much RAM does AMY really need? Let's trim the MAX_PARAM_LEN of event to keep the ram usage down for sequencer Jan 5, 2025
@bwhitman
Copy link
Collaborator Author

bwhitman commented Jan 6, 2025

I also wonder if this just goes away if we port sequencer to use delta instead of event` -- that is, we parse the events into deltas and put those on the sequencer list instead of full events.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

1 participant