[petsc-dev] de-global variablelizing PETSc

Jed Brown jedbrown at mcs.anl.gov
Sun Nov 10 18:57:25 CST 2013


Barry Smith <bsmith at mcs.anl.gov> writes:
>    What do tiny or fat Vecs have to do with wether
>    ISInitializePackage() and friends are called during some
>    initialization or “when needed” (and thus requiring some sort of
>    lock).

That was a question of whether threads should have their own private
library contexts.  (That is the strongest separation you could have
between threads, and would make some sense when multiple components of a
large application use PETSc, but do not interact via PETSc.)

>    BTW: I am not opposed to ISInitializePackage() using a lock to
>    insure it is done only once per process, but I ain’t writing that
>    code.

Okay, that's easy code, it just depends on what sort of portability we
want for threaded code.  (Non-threaded code will always just work.)  For
threaded, should we assume that (a) inline assembly is supported, (b)
C11 stdatomic.h is available, or (c) OpenMP is available?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 835 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20131110/6f1cfb42/attachment.sig>


More information about the petsc-dev mailing list