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

Performance improvement: ~13% faster on ESP32 and ~21% faster on ESP8266 (empirically tested) #554

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ecoriag
Copy link
Contributor

@ecoriag ecoriag commented Jul 16, 2022

Please consider this PR trying to improve performance with these changes:

  • new tsf_note_on_fast returning playIndex and removing lowpass filter setup since it is not being processed in tsf_voice_render_fast anyway but is consuming a lot of cpu
  • new tsf_note_off_fast using playIndex to stop voices faster
  • Removing lowpass filter setup from tsf_voice_render_fast since it is not being processed
  • Math tweaks trying to avoid complex math operations (specially conversions) at voice render stage
  • Precalculating *F32P32 values to avoid doing them at voice render stage

Edgar added 3 commits July 16, 2022 10:13
- new tsf_note_on_fast returning playIndex and removing lowpass filter setup since it is not being processed in tsf_voice_render_fast anyway but is consuming a lot of cpu
- new tsf_note_off_fast using playIndex to stop voices faster
- Removing lowpass filter setup from tsf_voice_render_fast since it is not being processed
- Math tweaks trying to avoid complex math operations (specially conversions) at voice render stage
- Precalculating *F32P32 values to avoid doing them at voice render stage
@earlephilhower earlephilhower self-assigned this Jul 17, 2022
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.

None yet

3 participants