aboutsummaryrefslogtreecommitdiff
path: root/llvm/test/tools/llvm-reduce/custom-delta-passes.ll
blob: 0be76ab1bf743815f550ed7734f5edafde08bdd7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
; RUN: llvm-reduce --abort-on-invalid-reduction --delta-passes=module-data --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t
; RUN: FileCheck --check-prefix=CHECK-NOCHANGE %s < %t
; RUN: llvm-reduce --abort-on-invalid-reduction --delta-passes=function-bodies --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t
; RUN: FileCheck --check-prefix=CHECK-CHANGE %s < %t
; RUN: llvm-reduce --abort-on-invalid-reduction --delta-passes=function-bodies,module-data --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t
; RUN: FileCheck --check-prefix=CHECK-CHANGE %s < %t

; RUN: not llvm-reduce --abort-on-invalid-reduction --delta-passes=foo --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t 2>&1 | FileCheck %s --check-prefix=ERROR
; RUN: not llvm-reduce --abort-on-invalid-reduction --delta-passes='function-bodies;module-data' --test FileCheck --test-arg --check-prefixes=CHECK-INTERESTINGNESS --test-arg %s --test-arg --input-file %s -o %t 2>&1 | FileCheck %s --check-prefix=ERROR

; RUN: llvm-reduce --print-delta-passes --test FileCheck %s 2>&1 | FileCheck %s --check-prefix=PRINT

; CHECK-INTERESTINGNESS: @f

; CHECK-NOCHANGE: define {{.*}} @f
; CHECK-CHANGE: declare {{.*}} @f

; ERROR: unknown

; PRINT: function-bodies

define void @f() {
  ret void
}