[Mlir-commits] [mlir] Make printing Value to a stream thread-safe (PR #185762)
Jacenty Andruszkiewicz
llvmlistbot at llvm.org
Wed Mar 11 08:52:48 PDT 2026
================
@@ -4142,8 +4142,13 @@ void Value::print(raw_ostream &os, AsmState &state) const {
<< "' at index: " << arg.getArgNumber();
}
+raw_ostream &mlir::operator<<(raw_ostream &os, Value value) {
+ value.print(os, OpPrintingFlags().useLocalScope());
+ return os;
+}
+
void Value::dump() const {
- print(llvm::errs());
+ print(llvm::errs(), OpPrintingFlags().useLocalScope());
----------------
Jacenty-And-Intel wrote:
> When is dump() useful in a threaded context?
In manual debug of concurrently ran OperationPasses could be useful.
I've updated the description with more context, please take a look. @joker-eph
https://github.com/llvm/llvm-project/pull/185762
More information about the Mlir-commits
mailing list