about summary refs log tree commit diff
diff options
context:
space:
mode:
authorRalf Jung <post@ralfj.de>2020-02-24 16:42:26 +0100
committerRalf Jung <post@ralfj.de>2020-02-24 16:42:26 +0100
commit4e867535f3c1ba7c8bbac2d75b7ac39e869fe8f3 (patch)
tree91edde8e4cca5e08298b416bb990872785e10f67
parent79cd224e758f603898b64308e849fbb9be6e6f4d (diff)
downloadrust-4e867535f3c1ba7c8bbac2d75b7ac39e869fe8f3.tar.gz
rust-4e867535f3c1ba7c8bbac2d75b7ac39e869fe8f3.zip
no more codegen for miri_start_panic
-rw-r--r--src/librustc_codegen_ssa/mir/block.rs7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/librustc_codegen_ssa/mir/block.rs b/src/librustc_codegen_ssa/mir/block.rs
index d684f842ddc..a1b54607b80 100644
--- a/src/librustc_codegen_ssa/mir/block.rs
+++ b/src/librustc_codegen_ssa/mir/block.rs
@@ -515,12 +515,9 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
             return;
         }
 
-        // For normal codegen, this Miri-specific intrinsic is just a NOP.
+        // For normal codegen, this Miri-specific intrinsic should never occur.
         if intrinsic == Some("miri_start_panic") {
-            let target = destination.as_ref().unwrap().1;
-            helper.maybe_sideeffect(self.mir, &mut bx, &[target]);
-            helper.funclet_br(self, &mut bx, target);
-            return;
+            bug!("`miri_start_panic` should never end up in compiled code");
         }
 
         // Emit a panic or a no-op for `panic_if_uninhabited`.