Skip to content

Fix/improve operation verification #456

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
bitwalker opened this issue Mar 26, 2025 · 0 comments · May be fixed by #516
Open

Fix/improve operation verification #456

bitwalker opened this issue Mar 26, 2025 · 0 comments · May be fixed by #516
Labels
good first issue Good for newcomers ir Improvements to, or bugs in, the implementation of the IR

Comments

@bitwalker
Copy link
Contributor

Currently, the OperationBuilder runs verification when an operation is built. Unfortunately, because this happens before the op is inserted into a block, it means that various operation traits with associated validation rules, fail automatically. This has caused us to disable/comment out those validation rules temporarily.

After a review, we can fix this situation as follows:

  • Remove the call to op.verify() in OperationBuilder
  • Re-enable/uncomment all of the disabled validation rules
  • Rely on the PassManager to run verification when so configured. This is a built-in feature of the PassManager implementation, so it is not necessary for us to also run verification when constructing ops, especially because it presents the problem described above.
@bitwalker bitwalker added feature good first issue Good for newcomers ir Improvements to, or bugs in, the implementation of the IR and removed feature labels Mar 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers ir Improvements to, or bugs in, the implementation of the IR
Projects
None yet
1 participant