about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/debuginfo/utils.rs
diff options
context:
space:
mode:
authorJubilee Young <workingjubilee@gmail.com>2024-07-19 16:52:33 -0700
committerJubilee Young <workingjubilee@gmail.com>2024-07-20 00:16:44 -0700
commitce7b069fd840916415adf2357c6133e2c1e4625b (patch)
treed9fc894c05be64c81e35036bc2c6fa768945a242 /compiler/rustc_codegen_llvm/src/debuginfo/utils.rs
parent9057c3ffec44926d5e149dc13ff3ce1613b69cce (diff)
downloadrust-ce7b069fd840916415adf2357c6133e2c1e4625b.tar.gz
rust-ce7b069fd840916415adf2357c6133e2c1e4625b.zip
compiler: Never debug_assert in codegen
The gains in performance are not worth the costs in correctness.
This is partly because the gains are zero and the costs are unknown.
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/debuginfo/utils.rs')
-rw-r--r--compiler/rustc_codegen_llvm/src/debuginfo/utils.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_llvm/src/debuginfo/utils.rs b/compiler/rustc_codegen_llvm/src/debuginfo/utils.rs
index 155e7a89fd8..9bd2ccceadf 100644
--- a/compiler/rustc_codegen_llvm/src/debuginfo/utils.rs
+++ b/compiler/rustc_codegen_llvm/src/debuginfo/utils.rs
@@ -81,7 +81,7 @@ pub(crate) fn fat_pointer_kind<'ll, 'tcx>(
         ty::Dynamic(..) => Some(FatPtrKind::Dyn),
         ty::Foreign(_) => {
             // Assert that pointers to foreign types really are thin:
-            debug_assert_eq!(
+            assert_eq!(
                 cx.size_of(Ty::new_imm_ptr(cx.tcx, pointee_tail_ty)),
                 cx.size_of(Ty::new_imm_ptr(cx.tcx, cx.tcx.types.u8))
             );