error checking macros with optimization
Lisandro Dalcin
dalcinl at gmail.com
Fri Nov 23 09:25:06 CST 2007
I would to propose some changes to error checking macros for optimized builds.
1.- SETERRQXXX: define them as
#define SETERRQ[1|2|..](ierr,...) return ierr
2.- CHKERRQ: define them as
#define CHKERRQ(ierr) if (ierr) return ierr
For (1), it should be no performace impact. For (2), the extra check
at almost every line of PETSc source code could impact performace, but
any of you have a clear idea of how much?
--
Lisandro Dalcín
---------------
Centro Internacional de Métodos Computacionales en Ingeniería (CIMEC)
Instituto de Desarrollo Tecnológico para la Industria Química (INTEC)
Consejo Nacional de Investigaciones Científicas y Técnicas (CONICET)
PTLC - Güemes 3450, (3000) Santa Fe, Argentina
Tel/Fax: +54-(0)342-451.1594
More information about the petsc-dev
mailing list