[petsc-dev] Using multiple mallocs with PETSc
Barry Smith
bsmith at mcs.anl.gov
Fri Mar 10 11:09:09 CST 2017
> On Mar 10, 2017, at 9:58 AM, Lisandro Dalcin <dalcinl at gmail.com> wrote:
>
>
> On 10 March 2017 at 03:19, Barry Smith <bsmith at mcs.anl.gov> wrote:
> PetscMallocRegister(malloc,realloc,free,&basicmalloc);
> PetscMallocRegister(PetscMallocDebug,PetscReallocDebug,PetscFreeDebug,&debugmalloc);
> PetscMallocRegister(PetscMallocHBW,PetscReallocHBW,PetscFreeHBW,&hbwmalloc);
>
> I'm wondering whether we should also handle calloc() here, and implement PetscCalloc properly. As I understand it, calloc != malloc+memset, and the differences might be important in multicore+multithreading scenarios and the first-touch policy.
Could be done.
>
>
> --
> Lisandro Dalcin
> ============
> Research Scientist
> Computer, Electrical and Mathematical Sciences & Engineering (CEMSE)
> Extreme Computing Research Center (ECRC)
> King Abdullah University of Science and Technology (KAUST)
> http://ecrc.kaust.edu.sa/
>
> 4700 King Abdullah University of Science and Technology
> al-Khawarizmi Bldg (Bldg 1), Office # 0109
> Thuwal 23955-6900, Kingdom of Saudi Arabia
> http://www.kaust.edu.sa
>
> Office Phone: +966 12 808-0459
More information about the petsc-dev
mailing list