summaryrefslogtreecommitdiffstats
path: root/firmware
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2009-12-26 13:22:51 +0000
committerJens Arnold <amiconn@rockbox.org>2009-12-26 13:22:51 +0000
commit099ab1f73181a4574d945055dbefb13802a39d85 (patch)
tree854c49263469fdd93cbd48742dcdc740c9af6801 /firmware
parent60012e195f852c1a3950281da63fcc4c080cf9ac (diff)
downloadrockbox-099ab1f73181a4574d945055dbefb13802a39d85.tar.gz
rockbox-099ab1f73181a4574d945055dbefb13802a39d85.tar.bz2
rockbox-099ab1f73181a4574d945055dbefb13802a39d85.zip
ARM <= v5: Tiny optimisation exploiting the location of the table.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24116 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r--firmware/target/arm/ffs-arm.S3
1 files changed, 1 insertions, 2 deletions
diff --git a/firmware/target/arm/ffs-arm.S b/firmware/target/arm/ffs-arm.S
index 30c62a4806..4e912c5317 100644
--- a/firmware/target/arm/ffs-arm.S
+++ b/firmware/target/arm/ffs-arm.S
@@ -52,13 +52,12 @@ find_first_set_bit:
@
@ Output modified to suit Rockbox purposes.
- adr r2, L_ffs_table
orrne r1, r1, r1, lsl #4 @ r1 = X * 0x11
orrne r1, r1, r1, lsl #6 @ r1 = X * 0x451
rsbne r1, r1, r1, lsl #16 @ r1 = X * 0x0450fbaf
@ now lookup in table indexed on top 6 bits of r1
- ldrb r0, [ r2, r1, lsr #26 ] @
+ ldrb r0, [ pc, r1, lsr #26 ] @ exploit location of table
bx lr @
L_ffs_table: