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

fix: Fix nontrivial input port size support #133

Merged
merged 6 commits into from
Oct 24, 2024

Conversation

dexter2206
Copy link
Contributor

Description

Fixes #127 by introducing relevant logic for handling non-trivial input port sizes depending on other ports.

Please verify that you have completed the following steps

  • I have self-reviewed my code.
  • I have included test cases validating introduced feature/fix.
  • I have updated documentation.

@dexter2206 dexter2206 requested a review from mstechly October 24, 2024 13:27
@cla-bot cla-bot bot added the cla-signed label Oct 24, 2024
Copy link
Contributor

@mstechly mstechly left a comment

Choose a reason for hiding this comment

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

Looks good, one minor coment!

@@ -141,3 +141,48 @@ def test_compile_errors(routine, expected_error, backend):
compile_routine(
routine, preprocessing_stages=[introduce_port_variables], backend=backend, skip_verification=True
)


def test_compilation_introduces_constraints_stemming_from_relation_between_port_sizes(backend):
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it's also worth adding a fun(N) to make sure parsing functions also works in this context?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Done!

@dexter2206 dexter2206 merged commit 759a367 into main Oct 24, 2024
7 checks passed
@dexter2206 dexter2206 deleted the 127-fix-nontrivial-input-port-size-support branch October 24, 2024 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

Nontrivial input port sizes are incorrectly handled if they are functions of other port size
2 participants