diff options
author | Jens Arnold <amiconn@rockbox.org> | 2006-12-06 18:44:45 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2006-12-06 18:44:45 +0000 |
commit | b774bae5fdceb0a0357e8866b3c235626c94bfe9 (patch) | |
tree | 8144cacb2e6aa1fd35a78dd7e1c677d96c45d6fe /firmware/target/coldfire/ata-as-coldfire.S | |
parent | 4c43d9422cc1fb23d8fa87c528176872cee5e661 (diff) | |
download | rockbox-b774bae5fdceb0a0357e8866b3c235626c94bfe9.tar.gz rockbox-b774bae5fdceb0a0357e8866b3c235626c94bfe9.zip |
Coldfire targets: Fixed performance-hitting bug for unaligned transfers. Now unaligned transfers are less than 10% slower than aligned transfers.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11679 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/coldfire/ata-as-coldfire.S')
-rwxr-xr-x | firmware/target/coldfire/ata-as-coldfire.S | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/firmware/target/coldfire/ata-as-coldfire.S b/firmware/target/coldfire/ata-as-coldfire.S index 3b0d67f8e4..0148ea261f 100755 --- a/firmware/target/coldfire/ata-as-coldfire.S +++ b/firmware/target/coldfire/ata-as-coldfire.S | |||
@@ -62,9 +62,9 @@ copy_read_sectors: | |||
62 | move.l %d2, %d3 | 62 | move.l %d2, %d3 |
63 | lsr.l #8, %d3 | 63 | lsr.l #8, %d3 |
64 | move.b %d3, (%a0)+ /* write high byte of it, aligns dest addr */ | 64 | move.b %d3, (%a0)+ /* write high byte of it, aligns dest addr */ |
65 | 65 | ||
66 | btst.l #1, %d0 /* longword aligned? */ | 66 | btst.l #1, %d0 /* longword aligned? (testing old d0 value!) */ |
67 | beq.b .r_end_u_w1 /* yes, skip leading word handling */ | 67 | bne.b .r_end_u_w1 /* yes, skip leading word handling */ |
68 | 68 | ||
69 | swap %d2 /* move initial word up */ | 69 | swap %d2 /* move initial word up */ |
70 | move.w (%a2), %d2 /* combine with second word */ | 70 | move.w (%a2), %d2 /* combine with second word */ |
@@ -273,8 +273,8 @@ copy_write_sectors: | |||
273 | 273 | ||
274 | move.b (%a0)+, %d2 | 274 | move.b (%a0)+, %d2 |
275 | 275 | ||
276 | btst.l #1, %d0 /* longword aligned? */ | 276 | btst.l #1, %d0 /* longword aligned? (testing old d0 value!) */ |
277 | beq.b .w_end_u_w1 /* yes, skip leading word handling */ | 277 | bne.b .w_end_u_w1 /* yes, skip leading word handling */ |
278 | 278 | ||
279 | swap %d2 | 279 | swap %d2 |
280 | move.w (%a0)+, %d2 | 280 | move.w (%a0)+, %d2 |