about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/context.rs
diff options
context:
space:
mode:
authorZalathar <Zalathar@users.noreply.github.com>2024-10-25 13:25:19 +1100
committerZalathar <Zalathar@users.noreply.github.com>2024-10-25 14:01:36 +1100
commitb3d65852c3addf4e8e6be96965ead86c2d4fb8be (patch)
tree3994f2b8c2299fd65c060c5ed536902ebfec7dc7 /compiler/rustc_codegen_llvm/src/context.rs
parent4923e856be61bfb8faac18eaf1f2b0d8e70ea3be (diff)
downloadrust-b3d65852c3addf4e8e6be96965ead86c2d4fb8be.tar.gz
rust-b3d65852c3addf4e8e6be96965ead86c2d4fb8be.zip
coverage: Emit MC/DC intrinsics using the normal helper method
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/context.rs')
-rw-r--r--compiler/rustc_codegen_llvm/src/context.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/rustc_codegen_llvm/src/context.rs b/compiler/rustc_codegen_llvm/src/context.rs
index 2f830d6f941..fb845c0087b 100644
--- a/compiler/rustc_codegen_llvm/src/context.rs
+++ b/compiler/rustc_codegen_llvm/src/context.rs
@@ -1099,6 +1099,10 @@ impl<'ll> CodegenCx<'ll, '_> {
 
         if self.sess().instrument_coverage() {
             ifn!("llvm.instrprof.increment", fn(ptr, t_i64, t_i32, t_i32) -> void);
+            if crate::llvm_util::get_version() >= (19, 0, 0) {
+                ifn!("llvm.instrprof.mcdc.parameters", fn(ptr, t_i64, t_i32) -> void);
+                ifn!("llvm.instrprof.mcdc.tvbitmap.update", fn(ptr, t_i64, t_i32, ptr) -> void);
+            }
         }
 
         ifn!("llvm.type.test", fn(ptr, t_metadata) -> i1);