Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[mlir][Python] Add a simple PyOpOperand iterator for PyValue uses.
This adds a simple PyOpOperand based on MlirOpOperand, which can has properties for the owner op and operation number. This also adds a PyOpOperandIterator that defines methods for __iter__ and __next__ so PyOpOperands can be iterated over using the the MlirOpOperand C API. Finally, a uses psuedo-container is added to PyValue so the uses can generically be iterated. Depends on D139596 Reviewed By: stellaraccident, jdd Differential Revision: https://reviews.llvm.org/D139597
- Loading branch information
1 parent
b49d3e5
commit afb2ed8
Showing
2 changed files
with
78 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters