Gil Rapaport 5622a92df0
[mlir][emitc] Turn constant into CExpression (#156450)
The `emitc.constant` op was so far left out of `emit.expression`'s as
its ConstantLike trait could cause CSE to invalidate `emitc.expression`
ops in two ways:

- Remove the root of a constant-only expression, leaving the expression
empty.
- Simplify within the expression, violating the single-use requirement.

The first issue was recently resolved by making `emitc.expression`
isolated-from-above. The second is resolved here by limiting the
single-use requirement to CExpressions with side effects, as ops with no
side effects can safely be cloned as needed.
2025-09-06 13:10:43 +03:00
..