[LLVMbugs] [Bug 17406] New: SDIV >128bit, DAG->DAG error in LegalizeIntegerTypes
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Sun Sep 29 21:02:02 PDT 2013
http://llvm.org/bugs/show_bug.cgi?id=17406
Bug ID: 17406
Summary: SDIV >128bit, DAG->DAG error in LegalizeIntegerTypes
Product: new-bugs
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: new bugs
Assignee: unassignedbugs at nondot.org
Reporter: eda-qa at disemia.com
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
I'm getting the following error when trying to SDIV integers greater
than 128bit (on an AMD64 target).
LegalizeIntegerTypes.cpp:2047: void
llvm::DAGTypeLegalizer::ExpandIntRes_SDIV(llvm::SDNode*, llvm::SDValue&,
llvm::SDValue&): Assertion `LC != RTLIB::UNKNOWN_LIBCALL && "Unsupported
SDIV!"' failed.
Stack dump:
0. Running pass 'X86 DAG->DAG Instruction Selection' on function
'@_entry'
However, not all SDIV on such integers fails, the below works:
@a = global i200 undef
@b = global i64 undef
define void @_entry() {
entry:
store i200 200, i200* @a
%0 = load i200* @a
%1 = load i200* @a
%2 = sdiv i200 %0, %1
%3 = trunc i200 %2 to i64
store i64 %3, i64* @b
%4 = load i64* @b
call void @trace_integer(i64 %4)
ret void
}
Yet with a simple addition (the same SDIV) it fails:
define void @_entry() {
entry:
store i200 200, i200* @a
%0 = load i200* @a
%1 = load i200* @a
%2 = sdiv i200 %0, %1
%3 = trunc i200 %2 to i64
store i64 %3, i64* @b
%4 = load i200* @a
%5 = load i200* @a
%6 = sdiv i200 %4, %5
store i200 %6, i200* @a
ret void
}
This is on the LLVM 3.3 release (it also happens on 3.2, the reason I updated).
As it appears all integer sizes are intended to be supported I assume this is a
defect.
--
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/20130930/807aa5b2/attachment.html>
More information about the llvm-bugs
mailing list