libMesh::MacroFunctions Namespace Reference

Functions

void here (const char *file, int line, const char *date, const char *time)
 
void stop (const char *file, int line, const char *date, const char *time)
 
void report_error (const char *file, int line, const char *date, const char *time)
 

Function Documentation

void libMesh::MacroFunctions::here ( const char *  file,
int  line,
const char *  date,
const char *  time 
)

Definition at line 35 of file libmesh_common.C.

References libMesh::err, and libMesh::processor_id().

Referenced by report_error(), and stop().

36  {
37  libMesh::err << "[" << static_cast<std::size_t>(libMesh::processor_id()) << "] "
38  << file
39  << ", line " << line
40  << ", compiled " << date
41  << " at " << time
42  << std::endl;
43  }
void libMesh::MacroFunctions::report_error ( const char *  file,
int  line,
const char *  date,
const char *  time 
)

Definition at line 63 of file libmesh_common.C.

References here(), libMesh::n_processors(), libMesh::print_trace(), and libMesh::write_traceout().

64  {
65  if (libMesh::n_processors() == 1)
67  else
69  libMesh::MacroFunctions::here(file, line, date, time);
70  }
void libMesh::MacroFunctions::stop ( const char *  file,
int  line,
const char *  date,
const char *  time 
)

Definition at line 47 of file libmesh_common.C.

References here(), libMesh::n_processors(), and libMesh::out.

Referenced by libMesh::PetscMatrix< T >::row_start(), and libMesh::PetscMatrix< T >::row_stop().

48  {
49  if (libMesh::n_processors() == 1)
50  {
51  libMesh::MacroFunctions::here(file, line, date, time);
52 #ifdef LIBMESH_HAVE_CSIGNAL
53  libMesh::out << "Stopping process " << getpid() << "..." << std::endl;
54  std::raise(SIGSTOP);
55  libMesh::out << "Continuing process " << getpid() << "..." << std::endl;
56 #else
57  libMesh::out << "WARNING: libmesh_stop() does not work without the <csignal> header file!" << std::endl;
58 #endif
59  }
60  }

Site Created By: libMesh Developers
Last modified: February 07 2014 16:57:33 UTC

Hosted By:
SourceForge.net Logo