Skip to content

Commit 0b58e52

Browse files
committed
Auto merge of rust-lang#92816 - tmiasko:rm-llvm-asm, r=Amanieu
Remove deprecated LLVM-style inline assembly The `llvm_asm!` was deprecated back in rust-lang#87590 1.56.0, with intention to remove it once `asm!` was stabilized, which already happened in rust-lang#91728 1.59.0. Now it is time to remove `llvm_asm!` to avoid continued maintenance cost. Closes rust-lang#70173. Closes rust-lang#92794. Closes rust-lang#87612. Closes rust-lang#82065. cc `@rust-lang/wg-inline-asm` r? `@Amanieu`
2 parents eef3530 + 7ec4de3 commit 0b58e52

File tree

2 files changed

+1
-13
lines changed

2 files changed

+1
-13
lines changed

src/base.rs

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -749,18 +749,6 @@ fn codegen_stmt<'tcx>(
749749
| StatementKind::Retag { .. }
750750
| StatementKind::AscribeUserType(..) => {}
751751

752-
StatementKind::LlvmInlineAsm(asm) => {
753-
match asm.asm.asm.as_str().trim() {
754-
"" => {
755-
// Black box
756-
}
757-
_ => fx.tcx.sess.span_fatal(
758-
stmt.source_info.span,
759-
"Legacy `llvm_asm!` inline assembly is not supported. \
760-
Try using the new `asm!` instead.",
761-
),
762-
}
763-
}
764752
StatementKind::Coverage { .. } => fx.tcx.sess.fatal("-Zcoverage is unimplemented"),
765753
StatementKind::CopyNonOverlapping(inner) => {
766754
let dst = codegen_operand(fx, &inner.dst);

src/constant.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -508,7 +508,7 @@ pub(crate) fn mir_operand_get_const_val<'tcx>(
508508
{
509509
return None;
510510
}
511-
StatementKind::LlvmInlineAsm(_) | StatementKind::CopyNonOverlapping(_) => {
511+
StatementKind::CopyNonOverlapping(_) => {
512512
return None;
513513
} // conservative handling
514514
StatementKind::Assign(_)

0 commit comments

Comments
 (0)