https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83505

--- Comment #1 from Yibiao Yang <yangyibiao at nju dot edu.cn> ---
Following is the reduced code for reproducing this issue:

$ cat small.cint main()
{
    int t = 1;
    int *p = &t;
    if (1) {
        if (0)
            return 0;
        return 1;
    }
}

$ gcc small.c -fprofile-rcs -ftest-coverage; ./a.out; gcov small.c; cat
small.c.gcov
File 'small.c'
Lines executed:100.00% of 5
Creating 'small.c.gcov'

        -:    0:Source:small.c
        -:    0:Graph:small.gcno
        -:    0:Data:small.gcda
        -:    0:Runs:1
        -:    0:Programs:1
        1:    1:int main()
        -:    2:{
        1:    3:    int t = 1;
        1:    4:    int *p = &t;
        -:    5:    if (1) {
        -:    6:        if (0)
        1:    7:            return 0;
        1:    8:        return 1;
        -:    9:    }
        -:   10:}

Reply via email to