http://llvm.org/bugs/show_bug.cgi?id=8266

           Summary: wrongful crash bug
           Product: new-bugs
           Version: trunk
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P
         Component: new bugs
        AssignedTo: [email protected]
        ReportedBy: [email protected]
                CC: [email protected]


I reported a bug like this just the other day but then it went into hiding or
was fixed.  Hopefully you folks can nail it this time.


[reg...@gamow ~]$ clang -v
clang version 2.9 (trunk 115236)
Target: x86_64-unknown-linux-gnu
Thread model: posix
[reg...@gamow ~]$ clang -O1 small.c -o small
[reg...@gamow ~]$ ./small 
Segmentation fault
[reg...@gamow ~]$ cat small.c
struct S0 {
   int  f0;
   int  f1;
   int  f2;
   int  f3;
   int  f4;
};

struct S0 g_20 = {0,0,0,0,0};

int func_4(int  p_6, struct S0 p_7)
{
    return p_6;
}

int main (void)
{
    struct S0 l_10[1] = {{1,1,1,1,1}};
    if(func_4(1, l_10[0]))
    {
    }
    else
    {
        for (g_20.f1 = 0; g_20.f1 < 1; g_20.f1 = g_20.f1+1)
        {
            struct S0 tmp = {2,2,2,2,2};
            l_10[g_20.f2] = tmp;
        }
    }
    return 0;
}

-- 
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
_______________________________________________
LLVMbugs mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/llvmbugs

Reply via email to