[LLVMbugs] [Bug 2501] New: probable clang bug
bugzilla-daemon at cs.uiuc.edu
bugzilla-daemon at cs.uiuc.edu
Fri Jun 27 14:02:15 PDT 2008
http://llvm.org/bugs/show_bug.cgi?id=2501
Summary: probable clang bug
Product: new-bugs
Version: unspecified
Platform: PC
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: new bugs
AssignedTo: unassignedbugs at nondot.org
ReportedBy: regehr at cs.utah.edu
CC: llvmbugs at cs.uiuc.edu
On svn 52832 on ubuntu feisty on ia32:
[regehr at babel tmp33]$ ~/z/llvm/Release/bin/clang small.c --emit-llvm -o - |
llvm-as | opt -std-compile-opts | llc | as -o small.o ; gcc small.o -o small
[regehr at babel tmp33]$ ./small
0
[regehr at babel tmp33]$ llvm-gcc -O small.c -o small
small.c: In function ‘main’:
small.c:31: warning: incompatible implicit declaration of built-in function
‘printf’
[regehr at babel tmp33]$ ./small
1
[regehr at babel tmp33]$ cat small.c
typedef short int int16_t;
typedef int int32_t;
typedef unsigned char uint8_t;
typedef unsigned int uint32_t;
volatile int16_t g_60;
uint32_t g_120;
uint8_t g_149;
int32_t func_1 (void);
int32_t func_31 (uint8_t p_33, int16_t p_34, int32_t p_35, int32_t p_37);
int32_t
func_1 (void)
{
uint32_t l_170 = 1;
g_60 = (func_31 (l_170, g_120, g_149, 1));
return 1;
}
int32_t
func_31 (uint8_t p_33, int16_t p_34, int32_t p_35, int32_t p_37)
{
uint32_t l_160 = -9L;
if (0xA68AL <= l_160)
return 1;
return 0;
}
int
main (int argc, char *argv[])
{
func_1 ();
printf ("%d\n", g_60);
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.
More information about the llvm-bugs
mailing list