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

Add support for control flow lowering in the VM to emitc target #5208

Merged
merged 7 commits into from
Mar 24, 2021

Conversation

simon-camp
Copy link
Contributor

Depends on #5207

@google-cla google-cla bot added the cla: yes label Mar 23, 2021
@benvanik benvanik added the compiler/dialects Relating to the IREE compiler dialects (flow, hal, vm) label Mar 23, 2021
iree/vm/ops.h Outdated Show resolved Hide resolved
@@ -148,11 +148,88 @@ static LogicalResult initializeGlobals(IREE::VM::ModuleOp moduleOp,
return success();
}

static LogicalResult translateBranchOp(IREE::VM::BranchOp branchOp,
Copy link
Collaborator

Choose a reason for hiding this comment

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

are there any lit tests that could be added for these? it'd help demonstrate what's happening and be good examples of the conversion

Copy link
Member

Choose a reason for hiding this comment

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

We have those for the mlir::BranchOp and the mlir::CondBranchOp (https://github.com/iml130/mlir-emitc/blob/main/test/Target/control_flow.mlir), so we can also add similar lit tests to IREE.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I've added the test (and fixed all broken tests in the directory :D)

@benvanik
Copy link
Collaborator

Exciting!

@benvanik benvanik merged commit c9f3742 into iree-org:main Mar 24, 2021
@ScottTodd ScottTodd mentioned this pull request Mar 25, 2021
copybara-service bot pushed a commit that referenced this pull request Mar 25, 2021
* da64c93 Integrate MLIR-EmitC at iml130/mlir-emitc@dde739f (#5228)
* a8d6c2a Fix doc publication by escaping our IR snippets in markdown. (#5227)
* bd5e535 Introduce RVV VLS code-gen (#5199)
* d496bc9 Avoid allocating temporary buffer for tensors derived from read-only tensors (..
* 1a93557 Tidying up a few pages of documentation. (#5225)
* 46e8331 Add a dedicated iree_c_module CMake module (#5214)
* 603b208 Merge google -> main (#5219)
* c9f3742 Add support for control flow lowering in the VM to emitc target (#5208)
* c8a7b2f Sort descriptors as expected by the native module (#5207)
* 47183fb Revise compiler tracing to enable statistics aggregation. (#5218)
* 500ec7b Set author to match committer for llvm submodule update action. (#5217)
* 881de81 Generate and use the iree_hal_executable_library_t metadata. (#5195)
* cf8180e Increase K tile size for small matrices. (#5213)
* f5804ec Fix problem bug in MobileBert with vectorization enable. (#5211)

COPYBARA_INTEGRATE_REVIEW=#5229 from ScottTodd:main-to-google da64c93
PiperOrigin-RevId: 365076337
iree-github-actions-bot pushed a commit that referenced this pull request Mar 25, 2021
* da64c93 Integrate MLIR-EmitC at iml130/mlir-emitc@dde739f (#5228)
* a8d6c2a Fix doc publication by escaping our IR snippets in markdown. (#5227)
* bd5e535 Introduce RVV VLS code-gen (#5199)
* d496bc9 Avoid allocating temporary buffer for tensors derived from read-only tensors (..
* 1a93557 Tidying up a few pages of documentation. (#5225)
* 46e8331 Add a dedicated iree_c_module CMake module (#5214)
* 603b208 Merge google -> main (#5219)
* c9f3742 Add support for control flow lowering in the VM to emitc target (#5208)
* c8a7b2f Sort descriptors as expected by the native module (#5207)
* 47183fb Revise compiler tracing to enable statistics aggregation. (#5218)
* 500ec7b Set author to match committer for llvm submodule update action. (#5217)
* 881de81 Generate and use the iree_hal_executable_library_t metadata. (#5195)
* cf8180e Increase K tile size for small matrices. (#5213)
* f5804ec Fix problem bug in MobileBert with vectorization enable. (#5211)

PiperOrigin-RevId: 365076337
@simon-camp simon-camp deleted the emitc-control-flow branch January 12, 2023 08:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
compiler/dialects Relating to the IREE compiler dialects (flow, hal, vm)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants