Skip to content

Commit

Permalink
Initialize MPI before timer
Browse files Browse the repository at this point in the history
  • Loading branch information
sebastiangrimberg committed Jan 18, 2024
1 parent 1f58ead commit c24b66a
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions palace/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -173,16 +173,16 @@ static void PrintPalaceInfo(MPI_Comm comm, int np, int nt, mfem::Device &device)

int main(int argc, char *argv[])
{
// Initialize the timer.
BlockTimer bt(Timer::INIT);

// Initialize MPI.
Mpi::Init(argc, argv);
MPI_Comm world_comm = Mpi::World();
bool world_root = Mpi::Root(world_comm);
int world_size = Mpi::Size(world_comm);
Mpi::Print(world_comm, "\n");

// Initialize the timer.
BlockTimer bt(Timer::INIT);

// Parse command-line options.
std::vector<std::string_view> argv_sv(argv, argv + argc);
bool dryrun = false;
Expand Down

0 comments on commit c24b66a

Please sign in to comment.