[llvm] [llvm-debuginfo-analyzer] Fixed some DWARF related bugs (PR #153318)
Adam Yang via llvm-commits
llvm-commits at lists.llvm.org
Mon Aug 18 11:56:20 PDT 2025
adam-yang wrote:
> I assume that your changes are fixing issues. Which is great.
>
> The initial approach for the logical view was to have the high PC value as inclusive, as it reduced the amount of additional checks.
>
> If we decide to have the high PC value as exclusive (as the DWARF approach), I think all readers (DWARF, CodeView, etc) should be aware of the new approach.
>
> Have you verified if the CodeView Reader , requires any adjustments? A simple way is to generate CodeView and DWARF for the same input file and the logical views should be similar (line numbers).
```
/*1*/
/*2*/ int main(void) {
/*3*/ float ret = 0;
/*4*/ for (int i = 0; i < 10; i++) {
/*5*/ ret += i;
/*6*/ }
/*7*/ return ret;
/*8*/ }
/*9*/
```
Tested with a simple program. LV CodeView does not include line 7 in the loop scope (which is what I would expect), but LV DWARF did before this change. I could add the DWARF for this to the PR as well as a test.
https://github.com/llvm/llvm-project/pull/153318
More information about the llvm-commits
mailing list