Skip to content

Commit

Permalink
Print AMReX version at the beginning of Initialize (#3604)
Browse files Browse the repository at this point in the history
Oftentimes, a GPU run dies at the first GPU kernel inside
amrex::Initialize before printing a message showing AMReX with a certain
version has been initialized. Adding a message at the beginning of
amrex::Initialize can provide useful information.
  • Loading branch information
WeiqunZhang authored Oct 19, 2023
1 parent c7b1ac7 commit 7c5ff69
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions Src/Base/AMReX.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -443,6 +443,10 @@ amrex::Initialize (int& argc, char**& argv, bool build_parm_parse,
pp.queryAdd("verbose", system::verbose);
}

if (system::verbose > 0) {
amrex::Print() << "Initializing AMReX (" << amrex::Version() << ")...\n";
}

#ifdef AMREX_USE_MPI
if (system::verbose > 0) {
amrex::Print() << "MPI initialized with "
Expand Down

0 comments on commit 7c5ff69

Please sign in to comment.