1 ; Test -sanitizer-coverage-trace-divs=1
2 ; RUN: opt < %s -sancov -sanitizer-coverage-level=1 -sanitizer-coverage-trace-divs=1 -S | FileCheck %s
3 ; RUN: opt < %s -passes='module(sancov-module)' -sanitizer-coverage-level=1 -sanitizer-coverage-trace-divs=1 -S | FileCheck %s
5 target datalayout = "e-p:64:64:64-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-n8:16:32:64"
6 target triple = "x86_64-unknown-linux-gnu"
8 define i32 @div_a_b(i32 %a, i32 %b) local_unnamed_addr {
10 %div = sdiv i32 %a, %b
14 ; CHECK-LABEL: @div_a_b
15 ; CHECK: call void @__sanitizer_cov_trace_div4(i32 %b)
19 define i32 @div_a_10(i32 %a) local_unnamed_addr {
21 %div = sdiv i32 %a, 10
25 ; CHECK-LABEL: @div_a_10
26 ; CHECK-NOT: __sanitizer_cov_trace_div
29 define i64 @div_a_b_64(i64 %a, i64 %b) local_unnamed_addr {
31 %div = udiv i64 %a, %b
35 ; CHECK-LABEL: @div_a_b_64
36 ; CHECK: call void @__sanitizer_cov_trace_div8(i64 %b)