Commit 716fa91d authored by Christophe Leroy's avatar Christophe Leroy Committed by Scott Wood

powerpc32: small optimisation in flush_icache_range()

Inlining of _dcache_range() functions has shown that the compiler
does the same thing a bit better with one insn less
Signed-off-by: default avatarChristophe Leroy <christophe.leroy@c-s.fr>
Signed-off-by: default avatarScott Wood <oss@buserror.net>
parent 8478d7f0
...@@ -348,10 +348,9 @@ BEGIN_FTR_SECTION ...@@ -348,10 +348,9 @@ BEGIN_FTR_SECTION
PURGE_PREFETCHED_INS PURGE_PREFETCHED_INS
blr /* for 601, do nothing */ blr /* for 601, do nothing */
END_FTR_SECTION_IFSET(CPU_FTR_COHERENT_ICACHE) END_FTR_SECTION_IFSET(CPU_FTR_COHERENT_ICACHE)
li r5,L1_CACHE_BYTES-1 rlwinm r3,r3,0,0,31 - L1_CACHE_SHIFT
andc r3,r3,r5
subf r4,r3,r4 subf r4,r3,r4
add r4,r4,r5 addi r4,r4,L1_CACHE_BYTES - 1
srwi. r4,r4,L1_CACHE_SHIFT srwi. r4,r4,L1_CACHE_SHIFT
beqlr beqlr
mtctr r4 mtctr r4
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment