5 Commits

Author SHA1 Message Date
Marius Brehler
dea855de46
[mlir][EmitC] Drop unused code (NFC) (#80325)
To register the conversion the autogenerated function
`registerSCFToEmitC()` calls `createSCFToEmitC()`, which itself is also
autogenerated. The removed function, however, isn't used in the upstream
codebase.
2024-02-04 18:51:47 +01:00
Gil Rapaport
2633d94f28
[mlir][emitc] Add a structured for operation (#68206)
Add an emitc.for op to the EmitC dialect as a lowering target for
scf.for, replacing its current direct translation to C; The translator
now handles emitc.for instead.
2023-10-26 16:40:18 +03:00
Gil Rapaport
a5b4ada6fe Recommit "Add a structured if operation (#67234)"
This patch recommits 126f0374cbc2110aa97e2141ac898014a8b9531a, reverted by
3ada774d0f65b44f21b360d222f446e533df1a34, along with the missing dependence.
2023-09-28 01:52:30 +03:00
Gil Rapaport
3ada774d0f Revert "Add a structured if operation (#67234)"
This reverts commit 126f0374cbc2110aa97e2141ac898014a8b9531a.

Reverting due to bot failures.
2023-09-28 00:22:42 +03:00
Gil Rapaport
126f0374cb
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.
2023-09-27 22:40:15 +03:00