[petsc-dev] Adding support memkind allocators in PETSc

Jed Brown jed at jedbrown.org
Tue Apr 28 22:44:24 CDT 2015

Barry Smith <bsmith at mcs.anl.gov> writes:
>   The special malloc would need to save the locations at which it set
>   the addresses and then switch the address to NULL. Then the code
>   that used those locations would have to know that they that they may
>   be set to NULL and hence check them before use.

And then PetscMalloc(...,&tmp); foo->data = tmp; creates SEGV at some
unpredictable time.  Awesome!

>   I am not saying this particular thing would be practical or not,
>   just that if we had a concept of a malloc context for each malloc
>   there are many games we could try that we couldn't try otherwise and
>   this is just one of them.

I'm not convinced, except in the case of mixing in madvise hints.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 818 bytes
Desc: not available
URL: <http://lists.mcs.anl.gov/pipermail/petsc-dev/attachments/20150428/92e00061/attachment.sig>

More information about the petsc-dev mailing list