[llvm-bugs] [Bug 24386] New: compiler aborted with "Function return type does not match operand type of return inst!"
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Aug 6 14:43:56 PDT 2015
https://llvm.org/bugs/show_bug.cgi?id=24386
Bug ID: 24386
Summary: compiler aborted with "Function return type does not
match operand type of return inst!"
Product: libraries
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: Backend: ARM
Assignee: unassignedbugs at nondot.org
Reporter: chh at google.com
CC: llvm-bugs at lists.llvm.org
Classification: Unclassified
The test case is reduced from main-05c473.cpp in
https://code.google.com/p/android/issues/detail?id=182036
$ cat test.cpp
struct Vec2 {
union {
struct {
float x, y;
};
float data[2];
};
};
Vec2 getVec2()
{
Vec2 out;
union { Vec2* v; unsigned char* u; } x;
x.v = &out;
return out;
}
$ clang++ \
-cc1 \
-triple armv7-none-linux-androideabi \
-target-cpu cortex-a8 \
-target-abi aapcs-linux \
-mfloat-abi hard \
-x c++ -emit-llvm \
test.cpp
Clang++ aborted with error message:
Function return type does not match operand type of return inst!
ret void <badref>
%struct.Vec2 = type { %union.anon }fatal error: error in backend: Broken
function found, compilation aborted!
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20150806/ab8e413e/attachment.html>
More information about the llvm-bugs
mailing list