NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: lib/50887: __clzdi2 implementation in compile_rt incompatible with gcc



The following reply was made to PR lib/50887; it has been noted by GNATS.

From: Joerg Sonnenberger <joerg%britannica.bec.de@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: lib-bug-people%netbsd.org@localhost, gnats-admin%netbsd.org@localhost,
	netbsd-bugs%netbsd.org@localhost
Subject: Re: lib/50887: __clzdi2 implementation in compile_rt incompatible
 with gcc
Date: Thu, 3 Mar 2016 11:17:26 +0100

 On Thu, Mar 03, 2016 at 07:30:00AM +0000, martin%NetBSD.org@localhost wrote:
 > However, libgcc on sparc64 does not implement the underlying helper function
 > _clzsi2 at all and always inlines:
 > 
 > inlint int _clzsi2(uint32_t v) { return _clzdi2(v)-32; }
 > 
 > which is correct, but combined with the compile_rt implementation leads
 > to an obvious endless recursion.
 
 I can't find any sensible reason for the GCC behavior. Even when using
 the table version, it is better to only four lookups instead of eight,
 so this is really something where GCC should be fixed to match its own
 builtin definition.
 
 Joerg
 


Home | Main Index | Thread Index | Old Index