From b15de7f54aa55c63af209855186fa04ee8f88580 Mon Sep 17 00:00:00 2001 From: vsariola <5684185+vsariola@users.noreply.github.com> Date: Fri, 5 Mar 2021 09:07:47 +0200 Subject: [PATCH] fix(templates): the polyphonic player forgot about one push and read stack wrongly --- templates/amd64-386/player.asm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/templates/amd64-386/player.asm b/templates/amd64-386/player.asm index 3d84b3c..de73750 100644 --- a/templates/amd64-386/player.asm +++ b/templates/amd64-386/player.asm @@ -107,7 +107,7 @@ su_update_voices_trackloop: xor edx, edx ; edx=0 mov ecx, ebx ; ecx=first voice of the track to be done su_calculate_voices_loop: ; do { - bt dword [{{.Stack "VoiceTrackBitmask"}}],ecx ; test voicetrack_bitmask// notice that the incs don't set carry + bt dword [{{.Stack "VoiceTrackBitmask"}} + {{.PTRSIZE}}],ecx ; test voicetrack_bitmask// notice that the incs don't set carry inc edx ; edx++ // edx=numvoices inc ecx ; ecx++ // ecx=the first voice of next track jc su_calculate_voices_loop ; } while bit ecx-1 of bitmask is on