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

memcpy_tointerleave allow AUDIO_BLOCK_SAMPLES == 4 #423

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 23 additions & 2 deletions memcpy_audio.S
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
.thumb
.text

/* void memcpy_tointerleave(short *dst, short *srcL, short *srcR); */
/* void memcpy_tointerleaveLR(short *dst, short *srcL, short *srcR); */
.global memcpy_tointerleaveLR
.thumb_func
memcpy_tointerleaveLR:
Expand Down Expand Up @@ -86,6 +86,14 @@

stmia r0!, {r3,r4,r5,r6}
pop {r4-r8}
#elif AUDIO_BLOCK_SAMPLES == 4
ldr r3, [r1]
ldr r2, [r2]

pkhbt r1,r3,r2,LSL #16
pkhtb r3,r2,r3,ASR #16

stmia r0!, {r1,r3}
#endif
BX lr

Expand Down Expand Up @@ -142,11 +150,18 @@
stmia r0!, {r3,r4,r5,r6}

pop {r4-r7}
#elif AUDIO_BLOCK_SAMPLES == 4
ldr r3, [r1]

pkhbt r1,r3,r2
pkhtb r3,r2,r3,ASR #16

stmia r0!, {r1,r3}
#endif
BX lr


/* void memcpy_tointerleaveL(short *dst, short *srcR); */
/* void memcpy_tointerleaveR(short *dst, short *srcR); */
.global memcpy_tointerleaveR
.thumb_func
memcpy_tointerleaveR:
Expand Down Expand Up @@ -197,7 +212,13 @@
stmia r0!, {r3,r4,r5,r6}

pop {r4-r7}
#elif AUDIO_BLOCK_SAMPLES == 4
ldr r3, [r1]

pkhbt r1,r2,r3,LSL #16
pkhtb r3,r3,r2

stmia r0!, {r1,r3}
#endif
BX lr

Expand Down