Skip to content

Conversation

@gabrielrodcanal
Copy link
Collaborator

@gabrielrodcanal gabrielrodcanal commented Aug 1, 2025

This pass transforms a target function generated with the extract-target pass to an HLS compatible format. This PR includes the changes to the extract-target pass to, since this pass depends on it - check #9 for details.

The arguments to the target function are dereferenced, since HLS does not accept pointers to pointers. The operands of the omp.map.info operations are forwarded and so are the operands of the omp.target operation, so that the operations inside its block can manipulate arrays. The omp.target, omp.bounds and omp.map.info operations are removed. Other operations, such as omp.parallel are not treated yet, but will be replaced by the corresponding HLS operation in the hls dialect.

Currently working for offload/ex1.F90

… function. Otherwise, the function will not be present in the symbol table of the calling module
…rated IR does not pass the mlir-opt verifier. Tested on all the offload examples
…tion arguments are dereferenced, since HLS is not compatible with pointers to pointers. OpenMP variables in the omp.map.info operations are forwarded and the omp.target operation is forwarded (operands are forwarded to the block operations). Tested with offload/ex1.F90
@gabrielrodcanal gabrielrodcanal requested a review from mesham August 1, 2025 21:33
@gabrielrodcanal gabrielrodcanal requested a review from mesham August 6, 2025 15:54
@gabrielrodcanal gabrielrodcanal self-assigned this Aug 6, 2025
@gabrielrodcanal gabrielrodcanal marked this pull request as ready for review August 6, 2025 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants