[all-commits] [llvm/llvm-project] 126f03: Add a structured if operation (#67234)
Gil Rapaport via All-commits
all-commits at lists.llvm.org
Wed Sep 27 12:40:30 PDT 2023
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 126f0374cbc2110aa97e2141ac898014a8b9531a
https://github.com/llvm/llvm-project/commit/126f0374cbc2110aa97e2141ac898014a8b9531a
Author: Gil Rapaport <gil.rapaport at mobileye.com>
Date: 2023-09-27 (Wed, 27 Sep 2023)
Changed paths:
M mlir/docs/Dialects/emitc.md
M mlir/include/mlir/Conversion/Passes.h
M mlir/include/mlir/Conversion/Passes.td
A mlir/include/mlir/Conversion/SCFToEmitC/SCFToEmitC.h
M mlir/include/mlir/Dialect/EmitC/IR/EmitC.h
M mlir/include/mlir/Dialect/EmitC/IR/EmitC.td
M mlir/lib/Conversion/CMakeLists.txt
A mlir/lib/Conversion/SCFToEmitC/CMakeLists.txt
A mlir/lib/Conversion/SCFToEmitC/SCFToEmitC.cpp
M mlir/lib/Dialect/EmitC/IR/EmitC.cpp
M mlir/lib/Target/Cpp/TranslateToCpp.cpp
A mlir/test/Conversion/SCFToEmitC/if.mlir
M mlir/test/Dialect/EmitC/invalid_ops.mlir
M mlir/test/Dialect/EmitC/ops.mlir
M mlir/test/Target/Cpp/if.mlir
Log Message:
-----------
Add a structured if operation (#67234)
Add an emitc.if op to the EmitC dialect. A new convert-scf-to-emitc
pass replaces the existing direct translation of scf.if to C; The
translator now handles emitc.if instead.
The emitc.if op doesn't return any value and its then/else regions are
terminated with a new scf.yield op. Values returned by scf.if are
lowered using emitc.variable ops, assigned to in the then/else regions
using a new emitc.assign op.
More information about the All-commits
mailing list