[PATCH] Add example to rand.3
Alejandro Colomar
alx.manpages@gmail.com
Fri Dec 30 18:20:30 GMT 2022
Hey Joseph!
On 12/30/22 19:15, Joseph Myers wrote:
> On Wed, 28 Dec 2022, Cristian Rodríguez via Libc-alpha wrote:
>
>> On Tue, Dec 27, 2022 at 9:41 PM Alejandro Colomar
>> <alx.manpages@gmail.com> wrote:
>>>
>>> Hi Branden,
>>>
>>> On 12/28/22 01:00, G. Branden Robinson wrote:
>>>> At 2022-12-28T00:33:13+0100, Alejandro Colomar wrote:
>>
>>> (I used C23 syntax for rounding up to a power of 2, to avoid some magic macro.
>>> That line is not necessary, but improves performance considerably for small
>>> upper bounds. I don't know if it's available already in GCC or Clang.)
>>
>> at least current gcc13 does not implement N3022 yet :-| that actually
>> a nice and looong needed addition (like 30 years late)
>
> I expect to implement these functions in due course for glibc (not GCC,
> since these are library functions, with the usual requirements for
> definitions with external linkage, though most would also have inline
> header implementations based on existing longstanding built-in functions).
Is there any builtin for stdc_bit_ceil()? I've tried to search for it, but
didn't find it. I came to the conclusion that I need to write the ugly code
around __builtin_clz().
Cheers,
Alex
>
--
<http://www.alejandro-colomar.es/>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: OpenPGP_signature
Type: application/pgp-signature
Size: 833 bytes
Desc: OpenPGP digital signature
URL: <https://sourceware.org/pipermail/libc-alpha/attachments/20221230/2ff85271/attachment.sig>
More information about the Libc-alpha
mailing list