:orphan: # PetscMemzero Zeros the specified memory. ## Synopsis ``` static inline PetscErrorCode PetscMemzero(void *a, size_t n) ``` Not Collective ## Input Parameters - ***a -*** pointer to beginning memory location - ***n -*** length (in bytes) of memory to initialize ## Compile Option `PETSC_PREFER_BZERO` - on certain machines (the IBM RS6000) the bzero() routine happens to be faster than the memset() routine. This flag causes the bzero() routine to be used. ## Notes Prefer `PetscArrayzero()` ## See Also `PetscMemcpy()`, `PetscMemcmp()`, `PetscArrayzero()`, `PetscArraycmp()`, `PetscArraycpy()`, `PetscMemmove()`, `PetscStrallocpy()` ## Level intermediate ## Location include/petscstring.h ## Examples src/ksp/ksp/tutorials/ex42.c
src/ksp/ksp/tutorials/ex43.c
src/ksp/ksp/tutorials/ex49.c
src/ksp/ksp/tutorials/ex70.c
src/snes/tutorials/ex48.c
src/sys/tutorials/ex5.c
src/ts/tutorials/ex10.c
src/ts/tutorials/ex11.c
src/ts/tutorials/ex11_sa.c
src/ts/tutorials/ex14.c
src/ts/tutorials/ex36.c
--- [Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/include/petscstring.h) [Index of all Sys routines](index.md) [Table of Contents for all manual pages](/manualpages/index.md) [Index of all manual pages](/manualpages/singleindex.md)