[illumos-Developer] Proposal: Add memory clearing allocator to libnvpair

Garrett D'Amore garrett at nexenta.com
Wed Jan 26 21:08:58 PST 2011


On Wed, 2011-01-26 at 22:11 -0600, Jason King wrote:
> On Wed, Jan 26, 2011 at 7:20 PM, Garrett D'Amore <garrett at nexenta.com> wrote:
> > Jason, I missed your original message.
> >
> > That said, this sounds like an easy improvement.  I presume we are only
> > talking about doing this for userland, and not for kernel space?
> >
> > The reference passed into nvlist_xalloc is used to receive the pointer
> > to the newly allocated structure.  Its done this way so that
> > nvlist_alloc() and return different errnos on success.
> 
> One potential wrinkle.  The existing libnvpair.so.1 lib is somewhat
> heavily versioned:
> 
> SUNW_1.3
> SUNW_1.2.2
> SUNW_1.2.1
> SUNW_1.2
> SUNW_1.1.1
> SUNW_1.1
> SUNWprivate_1.1
> 
> So... should we just cram the nv_alloc_zero symbol into SUNW_1.3, or
> should we create an ILLUMOS_1.0 or such ?
> I've not looked too heavily into the versioning mechanisms supported
> by the linker (though perhaps I'll need to now).


I think I've already created ILLUMOS_0.1 in another project:  see libc:

SYMBOL_VERSION ILLUMOS_0.1 {    # Illumos additions
    protected:
        timegm;
} SUNW_1.23;


So there is precedent.

	- Garrett





More information about the Developer mailing list