Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 448570
Collapse All | Expand All

(-)a/src/sna/kgem.c (-5 / +13 lines)
Lines 516-525 static void gem_close(int fd, uint32_t handle) Link Here
516
516
517
constant inline static unsigned long __fls(unsigned long word)
517
constant inline static unsigned long __fls(unsigned long word)
518
{
518
{
519
	asm("bsr %1,%0"
519
#if defined(__GNUC__) && ((__GNUC__ * 100 + __GNUC_MINOR__) >= 304)
520
	    : "=r" (word)
520
	return word == 0 ? 0 : 32 - __builtin_clz(word);
521
	    : "rm" (word));
521
#else
522
	return word;
522
	unsigned int v = 1;
523
524
	if (word == 0)
525
		return 0;
526
527
	while (word >>= 1)
528
		v++;
529
530
	return v;
531
#endif
523
}
532
}
524
533
525
constant inline static int cache_bucket(int num_pages)
534
constant inline static int cache_bucket(int num_pages)
526
- 

Return to bug 448570