Commit 6d8a039
committed
[TSan] Fix missing Inst cleanup
Commit 44e875a introduced a change that replaces `ReplaceInstWithInst`
with `Instruction::replaceAllUsesWith`, without subsequent instruction
cleanup.
This results in TSan leaving behind useless `load atomic` instructions
after 'replacing' them.
This commit adds cleanup back, consistent with the context.1 parent 4f8187c commit 6d8a039
File tree
2 files changed
+1
-3
lines changed- llvm
- lib/Transforms/Instrumentation
- test/Instrumentation/ThreadSanitizer
2 files changed
+1
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
729 | 729 | | |
730 | 730 | | |
731 | 731 | | |
| 732 | + | |
732 | 733 | | |
733 | 734 | | |
734 | 735 | | |
| |||
Lines changed: 0 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | | - | |
14 | 13 | | |
15 | 14 | | |
16 | 15 | | |
| |||
25 | 24 | | |
26 | 25 | | |
27 | 26 | | |
28 | | - | |
29 | 27 | | |
30 | 28 | | |
31 | 29 | | |
| |||
40 | 38 | | |
41 | 39 | | |
42 | 40 | | |
43 | | - | |
44 | 41 | | |
45 | 42 | | |
46 | 43 | | |
| |||
0 commit comments