This is the bug/patch tracker for Rockbox. Click here for more information.
Quick links: Bugs · Patches · Rockbox frontpage
FS#7833 - Optimizations to Vorbis codec
Attached to Project:
Rockbox
Opened by Tomasz Malesinski (tmal) - Tuesday, 25 September 2007, 23:20 GMT+1
Last edited by Jens Arnold (amiconn) - Friday, 25 January 2008, 19:53 GMT+1
Opened by Tomasz Malesinski (tmal) - Tuesday, 25 September 2007, 23:20 GMT+1
Last edited by Jens Arnold (amiconn) - Friday, 25 January 2008, 19:53 GMT+1
|
DetailsI attach a few patches that improve efficiency of the Vorbis codec. I would like them to be tested on various targets. The patches are independent.
codebook.patch includes a faster vorbis_book_decodevv_add function for one common case. It also doesn't inline decode_packed_block, because inlining such a big function confuses gcc making it fail to allocate registers properly in the loop after the call to decode_packed_block. mdct_arm.patch contains a part of mdct.c rewritten in ARM assembly. It saves some cycles, mostly by using ldm/stm where possible (gcc is not very good at it). It also does less inlining which makes it more cache friendly and easier to fit in IRAM. vbpcm.patch tries to put the output of the codec in vb->pcm, which is usually in IRAM, unlike v->pcm. |
This task depends upon
Closed by Jens Arnold (amiconn)
Friday, 25 January 2008, 19:53 GMT+1
Reason for closing: Accepted
Additional comments about closing: The crash on gigabeat if the code is enabled is fixed now (gigabeat uses no IRAM), but the asm mdct is kept disabled because the C code is slightly faster.
Friday, 25 January 2008, 19:53 GMT+1
Reason for closing: Accepted
Additional comments about closing: The crash on gigabeat if the code is enabled is fixed now (gigabeat uses no IRAM), but the asm mdct is kept disabled because the C code is slightly faster.
I tested on my h300
vbpcm.patch 300% -> 333% realtime
codebook.patch 300% -> 312% realtime
(minor nitpick though, there's an unused variable in vorbis_book_decodevv_add_2ch_even)
both 300% -> 341% realtime
Thank you very much.
I see no reason not to commit this :)