Commit fc62659
[Flang2] Fix duplicate TBAA type systems across modules
In Flang, functions within the same module are assigned unique TBAA
type system IDs based on their order, but functions in different
modules can unintentionally receive the same ID, leading to incorrect
non-aliasing results. This commit resolves the issue by appending a
hash of the module name to each function type system metadata, ensuring
unique type systems across modules and preventing aliasing errors.1 parent 2b33e62 commit fc62659
File tree
5 files changed
+90
-18
lines changed- test/llvm_ir_correct
- Inputs
- tools/flang2/flang2exe
5 files changed
+90
-18
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
13 | 17 | | |
| 18 | + | |
| 19 | + | |
14 | 20 | | |
15 | | - | |
16 | | - | |
17 | 21 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | 25 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
31 | | - | |
| 26 | + | |
32 | 27 | | |
33 | | - | |
34 | | - | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
35 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
36 | 37 | | |
37 | 38 | | |
38 | 39 | | |
| |||
2639 | 2640 | | |
2640 | 2641 | | |
2641 | 2642 | | |
2642 | | - | |
| 2643 | + | |
2643 | 2644 | | |
2644 | 2645 | | |
2645 | 2646 | | |
2646 | | - | |
| 2647 | + | |
| 2648 | + | |
2647 | 2649 | | |
2648 | 2650 | | |
2649 | 2651 | | |
| |||
0 commit comments