This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [GLIBC][PATCH] Remove string/bits/string2.h header


On Mon, Dec 12, 2016 at 7:32 AM, Wilco Dijkstra <Wilco.Dijkstra@arm.com> wrote:
> After patches [1-5] there is no longer a need for string2.h.
> Move the remaining defines for __bzero and __stpcpy to string.h
> (these are needed as otherwise elf/localplt fails) and remove all
> mention of string2.h.

I'd prefer that this header stick around, even if there is no
_current_ use for it.  I need somewhere to put the inline expansion of
explicit_bzero (see
https://sourceware.org/ml/libc-alpha/2016-12/msg00274.html) and it
seems likely to me that new uses will appear.

> +#ifdef __USE_MISC
> +# define __bzero(s, n) __builtin_memset (s, '\0', n)
> +#endif
> +
> +#ifdef  __USE_XOPEN2K8
> +# ifndef __stpcpy
> +#  define __stpcpy(dest, src) __builtin_stpcpy (dest, src)
> +# endif
> +#endif

These can probably go in include/string.h instead of string/string.h.

zw


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]