minix/common/lib/libc/arch/vax/gen/bswap64.S
Lionel Sambuc f14fb60209 Libraries updates and cleanup
* Updating common/lib
 * Updating lib/csu
 * Updating lib/libc
 * Updating libexec/ld.elf_so
 * Corrected test on __minix in featuretest to actually follow the
   meaning of the comment.
 * Cleaned up _REENTRANT-related defintions.
 * Disabled -D_REENTRANT for libfetch
 * Removing some unneeded __NBSD_LIBC defines and tests

Change-Id: Ic1394baef74d11b9f86b312f5ff4bbc3cbf72ce2
2013-01-14 11:36:26 +01:00

18 lines
342 B
ArmAsm

/* Written by Anders Magnusson. Public Domain */
#include <machine/asm.h>
RCSID("$NetBSD: bswap64.S,v 1.3 2011/01/25 04:45:28 matt Exp $")
ENTRY(bswap64, 0)
movq 4(%ap),%r3
rotl $-8,%r3,%r1
insv %r1,$16,$8,%r1
rotl $8,%r3,%r2
movb %r2,%r1
rotl $-8,%r4,%r0
insv %r0,$16,$8,%r0
rotl $8,%r4,%r2
movb %r2,%r0
ret
END(bswap64)