1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-18 18:42:46 +02:00
llvm-mirror/test/Other/cfg-printer-branch-weights-percent.ll
Arthur Eubanks f762198a61 [test] Fix tests using -analyze that fail under NPM
Many of these tests don't use the output of -analyze.
2020-10-21 21:54:30 -07:00

20 lines
470 B
LLVM

;RUN: opt < %s -dot-cfg -cfg-weights -cfg-dot-filename-prefix=%t 2>/dev/null
;RUN: FileCheck %s -input-file=%t.f.dot
define void @f(i32) {
entry:
%check = icmp sgt i32 %0, 0
br i1 %check, label %if, label %exit, !prof !0
; CHECK: label="0.50%"
; CHECK-NOT: ["];
if: ; preds = %entry
br label %exit
; CHECK: label="99.50%"
; CHECK-NOT: ["];
exit: ; preds = %entry, %if
ret void
}
!0 = !{!"branch_weights", i32 1, i32 200}