Skip to content

[Libomptarget] Move API implementations into GenericPluginTy #86683

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

Merged
merged 1 commit into from
Mar 27, 2024

Conversation

jhuber6
Copy link
Contributor

@jhuber6 jhuber6 commented Mar 26, 2024

Summary:
The plan is to remove the entire plugin interface and simply use the
GenericPluginTy inside of libomptarget by statically linking against
it. This means that inside of libomptarget we will simply do
Plugin.data_alloc without the dynamically loaded interface. To reduce
the amount of code required, this patch simply moves all of the RTL
implementation functions inside of the Generic device. Now the
__tgt_rtl_ interface is simply a shallow wrapper that will soon go
away. There is some redundancy here, this will be improved later. For
now what is important is minimizing the changes to the API.

@jhuber6
Copy link
Contributor Author

jhuber6 commented Mar 26, 2024

@jhuber6 jhuber6 force-pushed the ReworkAPIInterface branch 4 times, most recently from af25ad7 to 5b51b25 Compare March 26, 2024 21:38
Summary:
The plan is to remove the entire plugin interface and simply use the
`GenericPluginTy` inside of `libomptarget` by statically linking against
it. This means that inside of `libomptarget` we will simply do
`Plugin.data_alloc` without the dynamically loaded interface. To reduce
the amount of code required, this patch simply moves all of the RTL
implementation functions inside of the Generic device. Now the
`__tgt_rtl_` interface is simply a shallow wrapper that will soon go
away. There is some redundancy here, this will be improved later. For
now what is important is minimizing the changes to the API.
@jhuber6 jhuber6 force-pushed the ReworkAPIInterface branch from 5b51b25 to 976b442 Compare March 27, 2024 13:43
/// to the async versions right away with a NULL AsyncInfoPtr.
#ifdef __cplusplus
extern "C" {
#endif
Copy link
Member

Choose a reason for hiding this comment

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

This is C++, never C.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was already here, but will all be deleted soon enough.

@jhuber6 jhuber6 merged commit ed68aac into llvm:main Mar 27, 2024
searlmc1 pushed a commit to ROCm/llvm-project that referenced this pull request Mar 28, 2024
brings in
[Libomptarget] Move API implementations into GenericPluginTy (llvm#86683)

Change-Id: Id91192d0298a78e7fe80b824f4f28fb02186cd79
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
openmp:libomptarget OpenMP offload runtime
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants