[all-commits] [llvm/llvm-project] f8fcff: [mlir] Convert from Async dialect to LLVM coroutines
Eugene Zhulenev via All-commits
all-commits at lists.llvm.org
Thu Oct 22 06:31:11 PDT 2020
Branch: refs/heads/master
Home: https://github.com/llvm/llvm-project
Commit: f8fcff5a9d7ee948add3f28382d4ced5710edaaf
https://github.com/llvm/llvm-project/commit/f8fcff5a9d7ee948add3f28382d4ced5710edaaf
Author: Eugene Zhulenev <ezhulenev at google.com>
Date: 2020-10-22 (Thu, 22 Oct 2020)
Changed paths:
A mlir/include/mlir/Conversion/AsyncToLLVM/AsyncToLLVM.h
M mlir/include/mlir/Conversion/Passes.h
M mlir/include/mlir/Conversion/Passes.td
M mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
A mlir/include/mlir/ExecutionEngine/AsyncRuntime.h
A mlir/lib/Conversion/AsyncToLLVM/AsyncToLLVM.cpp
A mlir/lib/Conversion/AsyncToLLVM/CMakeLists.txt
M mlir/lib/Conversion/CMakeLists.txt
A mlir/lib/ExecutionEngine/AsyncRuntime.cpp
M mlir/lib/ExecutionEngine/CMakeLists.txt
M mlir/lib/ExecutionEngine/OptUtils.cpp
M mlir/test/CMakeLists.txt
A mlir/test/Conversion/AsyncToLLVM/convert-to-llvm.mlir
A mlir/test/mlir-cpu-runner/async.mlir
Log Message:
-----------
[mlir] Convert from Async dialect to LLVM coroutines
Lower from Async dialect to LLVM by converting async regions attached to `async.execute` operations into LLVM coroutines (https://llvm.org/docs/Coroutines.html):
1. Outline all async regions to functions
2. Add LLVM coro intrinsics to mark coroutine begin/end
3. Use MLIR conversion framework to convert all remaining async types and ops to LLVM + Async runtime function calls
All `async.await` operations inside async regions converted to coroutine suspension points. Await operation outside of a coroutine converted to the blocking wait operations.
Implement simple runtime to support concurrent execution of coroutines.
Reviewed By: herhut
Differential Revision: https://reviews.llvm.org/D89292
More information about the All-commits
mailing list