Skip to content

Add tutorial for creating custom executors #4359

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: master
Choose a base branch
from

Conversation

shrijitsingh99
Copy link
Contributor

No description provided.

Copy link
Member

@kunaltyagi kunaltyagi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please format the cpp file (eg: std::cout << notice the added spaces between different literals)

Also, CMakeLists.txt is missing


.. note::
This is an advanced topic and requires some knowledge on working of executors
and its implementation in PCL.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any location at the moment to where we can point the reader for additional info?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The idea was to link them to the design document and Code API.
Both are yet to be merged.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create an issue to link them (in your fork or PCL) so we don't forget

Comment on lines +8 to +10
// Forward declaration for custom executor
template <typename Blocking, typename ProtoAllocator>
struct omp_benchmark_executor;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this forward declaration required? What happens if you move the is_executor_available after the class is defined?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is needed since we check for this inside the class:

static_assert(is_executor_available_v<omp_executor>, "OpenMP benchmark executor unavailable");

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That static assert checks for omp_executor, not omp_benchmark_executor

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops. Fixed now.

@kunaltyagi kunaltyagi added the needs: more work Specify why not closed/merged yet label Aug 27, 2020
@shrijitsingh99
Copy link
Contributor Author

Made the requested changes.

Rendered Preview

screencapture-file-home-shrijit-pcl-doc-build-doc-tutorials-html-custom-executor-html-2020-08-30-00_01_49


.. note::
This is an advanced topic and requires some knowledge on working of executors
and its implementation in PCL.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Create an issue to link them (in your fork or PCL) so we don't forget

Copy link
Member

@kunaltyagi kunaltyagi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Tutorial and code are simple enough :)

@SergioRAgostinho
Copy link
Member

again. Do not merge until executors are merged into the main repo

@kunaltyagi kunaltyagi added needs: pr merge Specify why not closed/merged yet and removed needs: more work Specify why not closed/merged yet labels Aug 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module: tutorials needs: pr merge Specify why not closed/merged yet priority: gsoc Reason for prioritization
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants