[LLVMbugs] [Bug 11426] New: Assertion `V->getType()->isPointerTy() && "Capture is for pointers only!"' failed.
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Wed Nov 23 09:29:35 PST 2011
http://llvm.org/bugs/show_bug.cgi?id=11426
Bug #: 11426
Summary: Assertion `V->getType()->isPointerTy() && "Capture is
for pointers only!"' failed.
Product: new-bugs
Version: trunk
Platform: PC
OS/Version: Linux
Status: NEW
Severity: enhancement
Priority: P
Component: new bugs
AssignedTo: unassignedbugs at nondot.org
ReportedBy: baldrick at free.fr
CC: llvmbugs at cs.uiuc.edu
Classification: Unclassified
$ opt -dse non-ptr-malloc.ll -disable-output
opt: llvm/lib/Analysis/CaptureTracking.cpp:76: void
llvm::PointerMayBeCaptured(const llvm::Value*, llvm::CaptureTracker*):
Assertion `V->getType()->isPointerTy() && "Capture is for pointers only!"'
failed.
...
Here is the testcase. Probably someone is assuming that a function called
"malloc" has to return a pointer.
target datalayout =
"e-p:64:64:64-S128-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-f128:128:128-n8:16:32:64"
target triple = "x86_64-unknown-linux-gnu"
define i64 @unc_memops__alloc(i64 %size) uwtable {
entry:
%0 = tail call i64 @malloc(i64 %size)
unreachable
}
declare i64 @malloc(i64)
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list