Skip to content

Commit

Permalink
updated merge
Browse files Browse the repository at this point in the history
  • Loading branch information
Chris Taylor committed May 5, 2024
1 parent da7219a commit d26b61d
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion libs/core/openshmem_base/src/openshmem_environment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,11 @@ namespace hpx::util {
// page_count = num_localities * number of threads
//
const std::size_t page_count = size();
if(page_count < 1) {
HPX_THROW_EXCEPTION(error::invalid_status,
"hpx::util::openshmem_environment::init",
"OPENSHMEM not ready error");
}

// symmetric allocation for number of pages total + number of signals
//
Expand Down Expand Up @@ -420,7 +425,7 @@ namespace hpx::util {

int openshmem_environment::size()
{
int res(-1);
int res(0);
if (enabled()) {
scoped_lock l;
res = static_cast<int>(shmem_n_pes());
Expand Down

0 comments on commit d26b61d

Please sign in to comment.