This is the mail archive of the
libc-alpha@sourceware.org
mailing list for the glibc project.
Re: [PATCH] malloc: Run fork handler as late as possible [BZ #19431]
- From: Roland McGrath <roland at hack dot frob dot com>
- To: Florian Weimer <fweimer at redhat dot com>
- Cc: Torvald Riegel <triegel at redhat dot com>, GNU C Library <libc-alpha at sourceware dot org>
- Date: Tue, 12 Apr 2016 13:37:12 -0700 (PDT)
- Subject: Re: [PATCH] malloc: Run fork handler as late as possible [BZ #19431]
- Authentication-results: sourceware.org; auth=none
- References: <56BBAF3D dot 5030905 at redhat dot com> <1455559833 dot 20971 dot 11 dot camel at localhost dot localdomain> <56C5EE32 dot 1020605 at redhat dot com> <1460485015 dot 3869 dot 267 dot camel at localhost dot localdomain> <20160412184643 dot 16EF72C39FA at topped-with-meat dot com> <570D4735 dot 30100 at redhat dot com>
> Great, so include/malloc.h is out, and malloc-private.h,
> malloc-internal.h and mallocP.h are still in the race. :)
Right. Personally I would prefer to avoid the camelP.h naming style.
Between the other two I don't have a particular preference except that we
should move towards consistent conventions and knowing what they mean.
e.g. perhaps foo-private.h should only be for things that really should be
private to the foo subsystem, while foo-internal.h is for things in the foo
subsystem that are internal to libc put public across subsystems. Or
perhaps vice versa. Or perhaps we don't need both of those. Whatever.
But choosing conventions, describing them clearly, and using them
consistently is the goal.
> Just to clarify, do you see a future where we have about five different
> headers per subsystem?
I guess I do, since we've identified 6 categories and there's only two of
them that I'm not 100% sure need to be distinct.
> The new header in this patch is in category F (used across subsystems,
> internal to libc). Should we keep this separate from E and use a
> separate naming convention?
Tentatively yes, but maybe don't bother? That is, I don't really know off
hand how much we have in categories E and F today or how much we're likely
to get. If there is little enough it might not be worth distinguishing
them. Personally I don't mind having clearly-defined categories with very
few members and being pedantic about putting things in the right categories
even when that means some of the headers declare one or two things. But I
wouldn't want to insist on that.
Thanks,
Roland