[llvm-bugs] [Bug 48248] New: Crash on win64 vectorcall with large
via llvm-bugs
llvm-bugs at lists.llvm.org
Sat Nov 21 09:31:27 PST 2020
https://bugs.llvm.org/show_bug.cgi?id=48248
Bug ID: 48248
Summary: Crash on win64 vectorcall with large
Product: clang
Version: trunk
Hardware: PC
OS: Windows XP
Status: NEW
Severity: normal
Priority: P
Component: LLVM Codegen
Assignee: unassignedclangbugs at nondot.org
Reporter: christoffer.lerno at gmail.com
CC: llvm-bugs at lists.llvm.org, neeilans at live.com,
richard-llvm at metafoo.co.uk
I found a possible bug in TargetInfo.cpp, WinX86_64ABIInfo::classify
On rows 4215-4216 we have the following:
} else if (IsReturnType) {
return ABIArgInfo::getExpand();
This would suggest that we use "Expand" as strategy for a return value on a
vector call. However, "Expand" is not a valid strategy for return values, as it
is only for parameters. Hoping to expose this bug, I created large vectors
embedded in structs, which would then hit the "homogenous aggregate" path in
said function.
I finally struck gold with the following:
typedef double foo __attribute__ ((vector_size (64)));
struct Test {
foo a[2];
};
struct Test __vectorcall bar(struct Test a) {
return (struct Test) {};
}
However I am not sure that I'm actually triggering the bug, or if there are
multiple bugs, as this only crashes when "struct Test a" is there, which makes
me suspect that maybe we're hitting some other bug here.
Godbolt link: https://www.godbolt.org/z/EWWaor
--
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/20201121/5efc1c4f/attachment-0001.html>
More information about the llvm-bugs
mailing list