[vlc-devel] [PATCH] Add ARM mode compilation for JNI files

Måns Rullgård mans at mansr.com
Wed May 2 02:26:21 CEST 2012


Rafaël Carré <funman at videolan.org> writes:

> Le 01/05/2012 13:53, Jean-Baptiste Kempf a écrit :
>> On Tue, May 01, 2012 at 06:36:52PM +0100, Måns Rullgård wrote :
>>> Thumb-1 is certainly slower.
>
> Due to being much smaller, it might be faster than ARM in certain cases
> (so a benchmark is needed before claiming a specific code is slower when
> built in thumb).

I have never seen Thumb1 code being faster than ARM.  Simple code isn't
necessarily much slower, but anything mildly complex is always slower.
A Thumb instruction is half the size of an ARM instruction (16 bits
instead of 32), but the same code usually requires more Thumb
instructions than it needs in ARM mode.  As long as the number of
instructions is less than twice that for ARM mode, there is still a size
reduction, and this is the common case.  However, Thumb and ARM
instructions execute at the same rate, so the Thumb code is always
slower.

-- 
Måns Rullgård
mans at mansr.com




More information about the vlc-devel mailing list