http://llvm.org/bugs/show_bug.cgi?id=15353
Bug ID: 15353
Summary: clang -m32 -O fails with long long function argument
with message "Call result #3 has unhandled type i32"
Product: clang
Version: 3.2
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected]
Classification: Unclassified
Created attachment 10075
--> http://llvm.org/bugs/attachment.cgi?id=10075&action=edit
Here is the results of trying to compile the program
On x86 32 bit architecture with C or C++ program clang fails to compile a
program with a long long argument passed to a function following a for
statement
to set the long long.
This works in 64 bit mode. The problem is only when using optimization levels
from -O to -O3. Without optimization or with -O4 the program compiles
successfully.
The program can be compiled with
clang -m32 -c -O clangfail.c
It will also fail with
clang++ -m32 -c -O clangfail.c
Following is the C file that causes the problem:
/*-----------------------------------------*/
void myfprintf(long long);
void integer_work(long count)
{
long long i;
long long result = 0;
for (i=1; i <= count; i++) {
result+=i;
}
myfprintf(result);
}
--
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