Skip to content

Commit

Permalink
Fixing thread number selection
Browse files Browse the repository at this point in the history
The check if a core is disabled needs to honor the thread offset
  • Loading branch information
Thomas Heller committed Sep 7, 2017
1 parent 0c4b3b5 commit 4cc9e6f
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Expand Up @@ -471,7 +471,7 @@ namespace hpx { namespace threads { namespace policies
while (true)
{
auto const& rp = resource::get_partitioner();
auto mask = rp.get_pu_mask(num_thread);
auto mask = rp.get_pu_mask(num_thread + parent_pool_->get_thread_offset());
if(bit_and(mask, parent_pool_->get_used_processing_units()))
break;
else
Expand Down
2 changes: 1 addition & 1 deletion hpx/runtime/threads/policies/local_queue_scheduler.hpp
Expand Up @@ -315,7 +315,7 @@ namespace hpx { namespace threads { namespace policies
while (true)
{
auto const& rp = resource::get_partitioner();
auto mask = rp.get_pu_mask(num_thread);
auto mask = rp.get_pu_mask(num_thread + parent_pool_->get_thread_offset());
if(bit_and(mask, parent_pool_->get_used_processing_units()))
break;
else
Expand Down

0 comments on commit 4cc9e6f

Please sign in to comment.