Skip to content

[mlir] remove-dead-values zero exit code on failure #111757

@mtopalovicTT

Description

@mtopalovicTT

In case remove-dead-values pass emits error like below:

/localdev/mtopalovic/src/tt-mlir/test/ttmlir/Dialect/TTNN/simple_broadcast.mlir:3:1: error: cannot optimize an IR with non-function symbol ops, non-call symbol user ops or branch ops

mlir opt pass doesn't return failure but success.

This was discovered when llvm-lit reported that a test which emitted error above succeeded, but when command llvm-lit run was run manually you could see error above. This is because llvm-lit checks for error code in order to determine if test failed or succeeded.

Are we missing signalPassFailure in removeDeadValuePass

op->emitError() << "cannot optimize an IR with non-function symbol ops, "

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions