tools: Cull more ia64 and ppc code
PATCH v2 1/1 tools: Cull more ia64 and ppc code
Signed-off-by Andrew Cooper <[email protected]>
CC Ian Campbell <[email protected]>
CC Ian Jackson <[email protected]>
--- tools/libfsimage/common/fsimage_grub.c | 46 --------------------------- tools/python/xen/lowlevel/xc/xc.c | 53 -------------------------------- 2 files changed, 99 deletions(-)
tools/libfsimage/common/fsimage_grub.c +0 -46
@@ -138,52 +138,6 @@ fsig_log2 (unsigned long word) return word; } -#elif defined(__ia64__) - -#if __GNUC__ >=4 || (__GNUC__ ==3 && __GNUC_MINOR__ >=4 ) -# define ia64_popcnt (x) __builtin_popcountl(x) -#else -# define ia64_popcnt (x) \ - ({ \ - uint64_t ia64_intri_res; \ - asm ("popcnt %0=%1" : "=r" (ia64_intri_res) : "r" (x)); \ - ia64_intri_res; \ - }) -#endif - -unsigned long -fsig_log2 (unsigned long word) -{ -unsigned long result; - - result =ia64_popcnt ((word -1 ) & ~word); -return result; -} - -#elif defined(__powerpc__) - -#ifdef __powerpc64__ -#define PPC_CNTLZL "cntlzd" -#else -#define PPC_CNTLZL "cntlzw" -#endif -#define BITS_PER_LONG (sizeof(long) * 8) - -static int -__ilog2 (unsigned long x) -{ -int lz; - - asm (PPC_CNTLZL " %0,%1" :"=r" (lz) :"r" (x)); -return BITS_PER_LONG -1 - lz; -} - -unsigned long -fsig_log2 (unsigned long word) -{ -return __ilog2 (word & -word); -} -#else /* Unoptimized */ unsigned long
tools/python/xen/lowlevel/xc/xc.c +0 -53
91 lines not on this page · raw message
Signature · 1 line
1.7.10.4
Quoted 3 lines · Andrew Cooper
Signed-off-by Andrew Cooper <[email protected]>CC Ian Campbell <[email protected]>CC Ian Jackson <[email protected]>
acked + applied, thanks.