pcp
[Top] [All Lists]

RE: [pcp] libpcp vs. multithreading: pmns round

To: "'Frank Ch. Eigler'" <fche@xxxxxxxxxx>, "'pcp developers'" <pcp@xxxxxxxxxxx>
Subject: RE: [pcp] libpcp vs. multithreading: pmns round
From: "Ken McDonell" <kenj@xxxxxxxxxxxxxxxx>
Date: Mon, 2 Mar 2015 07:00:18 +1100
Delivered-to: pcp@xxxxxxxxxxx
In-reply-to: <20150301151637.GQ13422@xxxxxxxxxx>
References: <20150301151637.GQ13422@xxxxxxxxxx>
Thread-index: AQIaPcI6Mrfbnngr9X2U8WiZ3XyfWJx0OEag
Thanks for continuing to push on this Frank.

> -----Original Message-----
> From: pcp-bounces@xxxxxxxxxxx [mailto:pcp-bounces@xxxxxxxxxxx] On
> Behalf Of Frank Ch. Eigler
> Sent: Monday, 2 March 2015 2:17 AM
> ...
> A few possibilities:
> - making curr_pmns a per-thread global (a peer to __pmTPD.curcontext)
> - putting the pmns pointers right into the __pmContext impl.h structure
>   to make it per-context rather than global
>   In the latter case, for archives, it'd just link to the ac_log->l_pmns,
>   and for other cases it'd link to a global read-only pmns.
> Which of these (or something else) looks better?

My initial suggestion would be the first of these.  A PMNS can be loaded
without any PMAPI context in play, examples are pmcd and pminfo -n
<namespace>.  So it needs to be per thread, rather than per PMAPI context I
believe.

<Prev in Thread] Current Thread [Next in Thread>