Actual source code: ex6.c
petsc-3.4.2 2013-07-02

      2: static char help[] = "Example of using PetscLikely() and PetscUnlikely().\n\n";

      4: /*T
      5:    Concepts: optimization^likely
      6:    Concepts: optimization^unlikely
      7:    Processors: n
      8: T*/

     10: #include <petscsys.h>

     14: int main(int argc,char **argv)
     15: {
     16:   PetscBool flg = PETSC_TRUE;

     18:   PetscInitialize(&argc,&argv,(char*)0,help);

     20:   if (PetscLikely(flg)) {
     21:     /* do something */
     22:   }

     24:   if (PetscUnlikely(flg)) {
     25:     /* do something */
     26:   }
     27:   PetscFinalize();
     28:   return 0;
     29: }