[llvm-bugs] [Bug 49545] New: opt crashes with "opt -O2 -attributor-enable=cgscc ": Assertion `isa<X>(Val) && "cast<Ty>() argument of incompatible type!"' failed.
via llvm-bugs
llvm-bugs at lists.llvm.org
Thu Mar 11 11:08:03 PST 2021
https://bugs.llvm.org/show_bug.cgi?id=49545
Bug ID: 49545
Summary: opt crashes with "opt -O2 -attributor-enable=cgscc ":
Assertion `isa<X>(Val) && "cast<Ty>() argument of
incompatible type!"' failed.
Product: libraries
Version: trunk
Hardware: PC
OS: All
Status: NEW
Severity: enhancement
Priority: P
Component: Interprocedural Optimizations
Assignee: unassignedbugs at nondot.org
Reporter: zequanwu at google.com
CC: llvm-bugs at lists.llvm.org
$ cat reduced.ll
target datalayout =
"e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"
define hidden void @f1() align 2 {
entry:
call void @f2()
ret void
}
define linkonce_odr hidden void @f2() unnamed_addr align 2 {
entry:
call void @f3()
ret void
}
define linkonce_odr hidden void @f3() unnamed_addr align 2 {
entry:
call void @f4()
ret void
}
define available_externally void @f4() align 2 {
entry:
br label %if.end
if.end: ; preds = %entry
br label %if.else
if.else: ; preds = %if.end
%call7 = call i8* @f5()
ret void
}
define linkonce_odr hidden i8* @f5() align 2 {
entry:
%call = call i8* @f6()
ret i8* %call
}
define linkonce_odr hidden i8* @f6() align 2 {
if.end:
%call2 = call i8* @f7()
ret i8* %call2
}
define linkonce_odr hidden i8* @f7() {
entry:
br label %if.then
if.then: ; preds = %entry
call void @llvm.assume(i1 true) [ "align"(i8* undef, i64 undef) ]
br label %return
return: ; preds = %if.then
ret i8* undef
}
; Function Attrs: nofree nosync nounwind willreturn
declare void @llvm.assume(i1 noundef) #2
attributes #0 = { argmemonly nofree nosync nounwind willreturn }
attributes #1 = { argmemonly nofree nosync nounwind willreturn writeonly }
attributes #2 = { nofree nosync nounwind willreturn }
--
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/20210311/02932f5a/attachment.html>
More information about the llvm-bugs
mailing list