linux/arch/powerpc
Paul Mackerras 745a14cc26 [POWERPC] Add fast little-endian switch system call
This adds a system call on 64-bit platforms for switching between
little-endian and big-endian modes that is much faster than doing a
prctl call.  This system call is handled as a special case right at
the start of the system call entry code, and because it is a special
case, it uses a system call number which is out of the range of
normal system calls, namely 0x1ebe.

Measurements with lmbench on a 4.2GHz POWER6 showed no measurable
change in the speed of normal system calls with this patch.

Switching endianness with this new system call takes around 60ns on a
4.2GHz POWER6, compared with around 300ns to switch endian mode with a
prctl.  This can provide a significant performance advantage for
emulators for little-endian architectures that want to switch between
big-endian and little-endian mode frequently, e.g. because they are
generating instructions sequences on the fly and they want to run
those sequences in little-endian mode.

The other thing about this system call is that it doesn't clobber as
many registers as a normal system call.  It only clobbers r12.

Signed-off-by: Paul Mackerras <paulus@samba.org>
2008-04-29 15:57:34 +10:00
..
boot fbdev: powerpc: driver for Freescale 8610 and 5121 DIU 2008-04-28 08:58:40 -07:00
configs [POWERPC] 83xx: Enable FCM NAND and OF partitions in defconfig 2008-04-17 01:01:41 -05:00
kernel [POWERPC] Add fast little-endian switch system call 2008-04-29 15:57:34 +10:00
kvm KVM: ppc: PowerPC 440 KVM implementation 2008-04-27 18:21:39 +03:00
lib [POWERPC] Make rheap safe for spinlocks 2008-04-17 09:50:38 -05:00
math-emu [POWERPC] Replace remaining __FUNCTION__ occurrences 2008-04-01 20:43:09 +11:00
mm hotplug-memory: make online_page() common 2008-04-28 08:58:17 -07:00
oprofile Merge branch 'linux-2.6' 2008-04-14 21:11:02 +10:00
platforms celleb_scc_pciex __iomem annotations 2008-04-28 10:03:31 -07:00
sysdev powerpc: Add DIU platform code for MPC8610HPCD 2008-04-28 08:58:40 -07:00
xmon [POWERPC] Move stackframe definitions to common header 2008-04-18 15:37:18 +10:00
.gitignore [POWERPC] Add files build to .gitignore 2006-12-04 20:41:29 +11:00
Kconfig KVM: ppc: PowerPC 440 KVM implementation 2008-04-27 18:21:39 +03:00
Kconfig.debug KVM: ppc: PowerPC 440 KVM implementation 2008-04-27 18:21:39 +03:00
Makefile KVM: ppc: PowerPC 440 KVM implementation 2008-04-27 18:21:39 +03:00