
Remove support for the icmp and fcmp constant expressions. This is part of: https://discourse.llvm.org/t/rfc-remove-most-constant-expressions/63179 As usual, many of the updated tests will no longer test what they were originally intended to -- this is hard to preserve when constant expressions get removed, and in many cases just impossible as the existence of a specific kind of constant expression was the cause of the issue in the first place.
24 lines
370 B
LLVM
24 lines
370 B
LLVM
; RUN: opt -passes=lint < %s
|
|
|
|
; lint shouldn't crash on any of the below functions
|
|
|
|
@g_1 = external global [3 x i32]
|
|
@g_2 = external global [2 x i32]
|
|
|
|
define void @test1() {
|
|
entry:
|
|
tail call void @f1(i1 ptrtoint (ptr @g_2 to i1))
|
|
ret void
|
|
}
|
|
|
|
declare void @f1(i1)
|
|
|
|
define void @test2() {
|
|
tail call void inttoptr (i64 -1 to ptr)()
|
|
|
|
ret void
|
|
}
|
|
|
|
declare void @f2()
|
|
|