Skip to content
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

Structure Support to NestedSDFGs and Python Frontend #1366

Merged
merged 92 commits into from
Feb 22, 2024

Conversation

alexnick83
Copy link
Contributor

@alexnick83 alexnick83 commented Sep 6, 2023

Adds basic support for nested data (Structures) to the Python frontend. It also resolves issues with the use of Structures in nested SDFG scopes (mostly code generation).

NOTE: This PR handles only CPU code generation and fixes issues with libraries and transformations discovered during testing. It doesn't handle GPU/FPGA code generation, which will be studied in subsequent PRs.

…of the name is a Structure. Do not make Structure-related pointers const. When emitting memlet references, recursivly visit Structures and their members.
…tion. Commented out writing-one-index corner case (triggers obsolete ArrayViews).
…itor method now handles nested data. Slicing states replace dots with underscores in their name. Changed Memlet API used. Subscript visitor method extracts the true name for nested data and uses NestedDict for parsing memlet expressions.
…s. Use the root of the data name to infer storage from parent.
@tbennun tbennun added the in the merge queue waiting for CI to work again label Jan 18, 2024
JanKleine added a commit to JanKleine/dace that referenced this pull request Feb 14, 2024
@tbennun
Copy link
Collaborator

tbennun commented Feb 19, 2024

@alexnick83 there are two consistently failing tests in this PR (GPU).

@alexnick83
Copy link
Contributor Author

alexnick83 commented Feb 19, 2024

@alexnick83 there are two consistently failing tests in this PR (GPU).

I don't see something in the PR that should directly cause these issues, but maybe the changes assisted in bringing to light pre-existing bugs.

Specifically, the adi test fails because __tmp62 and __tmp63 are not passed as arguments to the GPU kernels. The interesting thing here is that both of them have as original allocation scope the GPU kernel itself. However, the allocation scope changes to the corresponding State because they are placed in GPU global memory instead of registers. I will try to fix the argument passing (some other PR may have broken it), but we should look into fixing the storage types.

The conv2d test fails because the GPUAuto reduction expansion has some error. I confirmed this by disabling the expansion in the auto-optimizer to make it fall back to the CUDA (device) expansion. With the latter, the test passes. I will make a new PR to fix GPUAuto and disable the test for now.

@alexnick83 alexnick83 enabled auto-merge (squash) February 20, 2024 16:15
@alexnick83 alexnick83 added this pull request to the merge queue Feb 20, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks Feb 20, 2024
@alexnick83 alexnick83 added this pull request to the merge queue Feb 21, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to no response for status checks Feb 21, 2024
@alexnick83 alexnick83 added this pull request to the merge queue Feb 21, 2024
@phschaad phschaad removed this pull request from the merge queue due to the queue being cleared Feb 22, 2024
@alexnick83 alexnick83 added this pull request to the merge queue Feb 22, 2024
Merged via the queue into master with commit ab6647b Feb 22, 2024
11 checks passed
@alexnick83 alexnick83 deleted the frontend-add-structure-support branch February 22, 2024 23:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in the merge queue waiting for CI to work again
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants