From 95582e6fcbd5e62dd8f1148abc1689751357f036 Mon Sep 17 00:00:00 2001 From: Ralf Jung Date: Thu, 9 May 2024 18:27:27 +0200 Subject: codegen: memmove/memset cannot be non-temporal --- compiler/rustc_codegen_llvm/src/builder.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'compiler/rustc_codegen_llvm/src/builder.rs') diff --git a/compiler/rustc_codegen_llvm/src/builder.rs b/compiler/rustc_codegen_llvm/src/builder.rs index 1a1b4ae3831..c85ace2ecd6 100644 --- a/compiler/rustc_codegen_llvm/src/builder.rs +++ b/compiler/rustc_codegen_llvm/src/builder.rs @@ -976,6 +976,7 @@ impl<'a, 'll, 'tcx> BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> { align: Align, flags: MemFlags, ) { + assert!(!flags.contains(MemFlags::NONTEMPORAL), "non-temporal memset not supported"); let is_volatile = flags.contains(MemFlags::VOLATILE); unsafe { llvm::LLVMRustBuildMemSet( -- cgit 1.4.1-3-g733a5