[PATCH 2/2 v4] [BZ #10283] localedef: align fixed maps to SHMLBA

Roland McGrath roland@hack.frob.com
Tue Jun 11 17:40:00 GMT 2013


> On Monday 03 June 2013 15:14:56 Roland McGrath wrote:
> > > +#include <sys/shm.h>
> > > +#define MAP_FIXED_ALIGNMENT SHMLBA
> > 
> > This is the Linux-specific definition.  The generic file should just use
> > page size, or perhaps the macro should be defined such that the code (or at
> > least the compiler) can tell statically that there is no need for
> > additional operations at all when the requirement is no larger than page
> > size.
> 
> in the discussion on this matter earlier, there were multiple points
> raised.  it isn't unique to Linux (at least Solaris does it), and if this
> generally the sane default, then having it be the generic default makes
> sense.  especially since it doesn't really hurt when it's larger, and
> it's safer.

It is not as yet the specified GNU API.  I don't think it should be, either.



More information about the Libc-alpha mailing list