linux/arch/powerpc
Milton Miller 53024fe250 [POWERPC] Optimize account_system_vtime
We have multiple calls to has_feature being inlined, but gcc can't
be sure that the store via get_paca() doesn't alias the path to
cur_cpu_spec->feature.

Reorder to put the calls to read_purr and read_spurr adjacent to each
other.  To add a sense of consistency, reorder the remaining lines to
perform parallel steps on purr and scaled purr of each line instead of
calculating and then using one value before going on to the next.

In addition, we can tell gcc that no SPURR means no PURR.  The test is
completely hidden in the PURR case, and in the !PURR case the second test
is eliminated resulting in the simple register copy in the out-of-line
branch.

Further, gcc sees get_paca()->system_time referenced several times and
allocates a register to address it (shadowing r13) instead of caching its
value.  Reading into a local varable saves the shadow of r13 and removes
a potentially duplicate load (between the nested if and its parent).

Signed-off-by: Milton Miller <miltonm@bga.com>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2007-12-20 16:15:46 +11:00
..
boot [POWERPC] wrapper: Treat NULL as root node in devp_offset; add devp_offset_find() 2007-12-20 16:11:46 +11:00
configs [POWERPC] 83xx: Add MPC837x MDS default kernel configuration 2007-12-11 13:57:18 -06:00
kernel [POWERPC] Optimize account_system_vtime 2007-12-20 16:15:46 +11:00
lib [POWERPC] rheap: Changes config mechanism 2007-10-16 17:09:21 -06:00
math-emu [POWERPC] Fix handling of stfiwx math emulation 2007-10-16 09:05:24 -05:00
mm [POWERPC] Fake NUMA emulation for PowerPC 2007-12-20 16:11:46 +11:00
oprofile [POWERPC] OProfile: fix cbe pm signal routing problem 2007-12-19 01:00:01 +01:00
platforms [POWERPC] Push down or eliminate smp_processor_id calls in xics code 2007-12-20 16:15:34 +11:00
sysdev [POWERPC] pasemi: Implement MSI support 2007-12-20 16:15:23 +11:00
xmon [POWERPC] Update xmon slb code 2007-12-11 13:46:05 +11:00
.gitignore [POWERPC] Add files build to .gitignore 2006-12-04 20:41:29 +11:00
Kconfig Fix boot problem with iSeries lacking hugepage support 2007-11-29 09:24:51 -08:00
Kconfig.debug [POWERPC] Early debug forces console log level to max 2007-12-11 15:43:35 +11:00
Makefile [POWERPC] Implement 'make bootwrapper_install' 2007-12-06 14:44:30 +11:00