about summary refs log tree commit diff
path: root/compiler/rustc_codegen_ssa/src/mir
diff options
context:
space:
mode:
authorAndreas Jonson <andjo403@users.noreply.github.com>2021-11-14 14:01:30 +0100
committerAndreas Jonson <andjo403@users.noreply.github.com>2021-11-14 16:35:09 +0100
commit50ec47aa06e96a195707fb5ee92fcd32299ca272 (patch)
tree866f4b070575fc032100f6b86b62da6e012d47e4 /compiler/rustc_codegen_ssa/src/mir
parentf820d9d4e5af7d298ffdc3145b48e206b65e8e28 (diff)
Remove workaround for the forward progress handling in LLVM
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/mir')
-rw-r--r--compiler/rustc_codegen_ssa/src/mir/block.rs11
1 files changed, 0 insertions, 11 deletions
diff --git a/compiler/rustc_codegen_ssa/src/mir/block.rs b/compiler/rustc_codegen_ssa/src/mir/block.rs
index a9471f7b771..c8f388bfa1d 100644
--- a/compiler/rustc_codegen_ssa/src/mir/block.rs
+++ b/compiler/rustc_codegen_ssa/src/mir/block.rs
@@ -980,17 +980,6 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
             }
 
             mir::TerminatorKind::Goto { target } => {
-                if bb == target {
-                    // This is an unconditional branch back to this same basic block. That means we
-                    // have something like a `loop {}` statement. LLVM versions before 12.0
-                    // miscompile this because they assume forward progress. For older versions
-                    // try to handle just this specific case which comes up commonly in practice
-                    // (e.g., in embedded code).
-                    //
-                    // NB: the `sideeffect` currently checks for the LLVM version used internally.
-                    bx.sideeffect();
-                }
-
                 helper.funclet_br(self, &mut bx, target);
             }