[LLVMbugs] [Bug 15417] New: small code triggers assert with un-constant-foldable extractvalue
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Fri Mar 1 20:53:28 PST 2013
http://llvm.org/bugs/show_bug.cgi?id=15417
Bug ID: 15417
Summary: small code triggers assert with un-constant-foldable
extractvalue
Product: libraries
Version: 3.2
Hardware: PC
OS: All
Status: NEW
Severity: normal
Priority: P
Component: Core LLVM classes
Assignee: unassignedbugs at nondot.org
Reporter: flld0 at greynode.net
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
The following code is a (contrived) example of a use of a constant extractvalue
which cannot be constant folded. It triggers an assert in code which can only
handle cases it can fold. Under similar circumstances, other constant
expression cases fall back to building unfolded constants. Perhaps extractvalue
should do something similar.
@0 = global i8 extractvalue ([1 x i8] select (i1 ptrtoint (i32* @1 to i1), [1 x
i8] [ i8 1 ], [1 x i8] [ i8 2 ]), 0)
@1 = external global i32
Assertion failed: (FC && "ExtractValue constant expr couldn't be folded!"),
function getExtractValue, file Constants.cpp, line 1926
This case is contrived. I concocted it (and other cases like it which work for
other constant expressions) deliberately not to constant fold. As such it might
be considered lower priority, depending on how you prioritize such things. On
the other hand less contrived examples may exist.
--
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/20130302/0c0d925e/attachment.html>
More information about the llvm-bugs
mailing list