parallel_scheduler for P2079 Section 4.1 User Facing API (ref #6601)#6655
parallel_scheduler for P2079 Section 4.1 User Facing API (ref #6601)#6655charan-003 wants to merge 7 commits intoTheHPXProject:masterfrom
Conversation
|
Can one of the admins verify this patch? |
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
cb9d1a7 to
1a77a29
Compare
|
Update:
@hkaiser — ready for re-review when convenient. Thanks for the guidance! |
|
@hkaiser Can you please verify it now? I'm not sure why those 2 tests are failing. |
hkaiser
left a comment
There was a problem hiding this comment.
Wow, I'm impressed! I have a couple of minor comments, though.
|
Also, you may want to move all types that are don't have to visible by users into |
Sure, I'll do that soon |
|
i'm not sure why it's failing for clang_format. i used |
|
@hkaiser The custom bulk chunking might duplicate functionality in Offers a parallel execution option that leverages HPX’s thread pool, maintaining high performance for CPU-bound tasks. While this version lacks P2079R7’s replaceability API (section 4.2) and many more, it could be extended to support it ( will try to work on this :)) |
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
The CI uses an older version of clang-format that does not always agree with newer versions on how to format things. Simply surround the offending lines with to disable it checking those. |
|
@hkaiser @isidorostsa Implement parallel_scheduler wrapping thread_pool_policy_schedulerhpx::launch, aligning with P2079R7 user-facing API:
replaceability API , bulk operations is the next thing i will keep working on. |
|
@hkaiser @isidorostsa this version is using stdexec I'm not sure of the failing test case, any hint on the failing cases ? |
9803589 to
3b4121f
Compare
|
@hkaiser @isidorostsa |
10b035e to
94403fc
Compare
isidorostsa
left a comment
There was a problem hiding this comment.
Great work! Some changes needed, but I am very happy to see you getting the hang of things!
6814725 to
25416ac
Compare
|
@charan-003 please rebase your branch onto top of master to resolve the merge conflicts. |
07d7f6b to
45ed608
Compare
Performance test reportHPX PerformanceComparison
Info
Comparison
Info
Comparison
Info
Explanation of Symbols
|
Performance test reportHPX PerformanceComparison
Info
Comparison
Info
Comparison
Info
Explanation of Symbols
|
Up to standards ✅🟢 Issues
|
| Metric | Results |
|---|---|
| Complexity | 66 |
| Duplication | 22 |
TIP This summary will be updated as you push new changes. Give us feedback
|
Just FYI: https://wg21.link/p4031 |
Fixes #6601
Implement P2079R7 parallel_scheduler in HPX Core
This issue tracks the implementation of
hpx::execution::experimental::parallel_schedulerin HPX core, aligning with P2079R7 (Parallel scheduler, Section 4.1) by wrappingthread_pool_policy_schedulerwithhpx::launchpolicies. The goal is to provide a standards-compliant parallel scheduler with global access, cancellation support, task chaining, and bulk operations.Implementation Checklist
Phase 1: Core Implementation
Implement
hpx::execution::experimental::parallel_schedulerclass per P2079R7 Section 4.1.Add
schedule()returningparallel_senderwithsender_conceptandcompletion_signatures:Supports
set_value_t(),set_stopped_t(),set_error_t(std::exception_ptr).Wrap
thread_pool_policy_schedulerwithhpx::launch(async/sync policies).Implement
noexceptmove/copy constructors and assignment operators.Add
operator==returningtruefor scheduler comparison.Return
forward_progress_guarantee::parallelviaget_forward_progress_guarantee_t.Implement
thenoperation for task chaining withparallel_sender.Code to rely on
STDEXEC.Phase 2: Bulk Support
Extend
bulk_tcustomization to delegate tothread_pool_scheduler_bulk.Implement
bulk_senderfor parallel bulk execution per P2079R7.Support
bulk_chunkedandbulk_unchunkedoperations.Phase 3: Replaceability API
Implement
std::execution::system_context_replaceabilitynamespace per P2079R7 Section 4.2.Add
query_parallel_scheduler_backend()returningshared_ptr<parallel_scheduler>.Support link-time replaceability using weak symbols.
Implement
receiverandbulk_item_receiverinterfaces for frontend-backend interaction.Ensure
storagehandling for scheduling operations.