Commit 4bb2472
committed
[MLIR] Fix use-after-move issues
This patch addresses two use-after-move issues:
1. Timing.cpp
A variable was std::moved and then immediately passed to an assert() check. Since the moved-from state made the assertion condition trivially true, the check was effectively useless. The assert() is removed.
2. Query.cpp
The `matcher` object was moved-from and then subsequently used as if it still retained valid state. The fix ensures no subsequent use of the moved-from variable.
Testing:
ninja check-mlir1 parent 4c46ae3 commit 4bb2472
2 files changed
+3
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
| 124 | + | |
| 125 | + | |
124 | 126 | | |
125 | 127 | | |
126 | 128 | | |
127 | 129 | | |
128 | | - | |
129 | | - | |
| 130 | + | |
130 | 131 | | |
131 | 132 | | |
132 | 133 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
319 | 319 | | |
320 | 320 | | |
321 | 321 | | |
322 | | - | |
323 | 322 | | |
324 | 323 | | |
325 | 324 | | |
| |||
0 commit comments