From ad552bc17e9e494e039f3db180d4e63be44fe889 Mon Sep 17 00:00:00 2001 From: Joe Richey Date: Mon, 26 Oct 2020 03:46:54 -0700 Subject: Add compiler support for LLVM's x86 ERMSB feature This change is needed for compiler-builtins to check for this feature when implementing memcpy/memset. See: https://github.com/rust-lang/compiler-builtins/pull/365 The change just does compile-time detection. I think that runtime detection will have to come in a follow-up CL to std-detect. Like all the CPU feature flags, this just references #44839 Signed-off-by: Joe Richey --- compiler/rustc_codegen_ssa/src/target_features.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'compiler/rustc_codegen_ssa') diff --git a/compiler/rustc_codegen_ssa/src/target_features.rs b/compiler/rustc_codegen_ssa/src/target_features.rs index a8d88a95f7a..000ddf42604 100644 --- a/compiler/rustc_codegen_ssa/src/target_features.rs +++ b/compiler/rustc_codegen_ssa/src/target_features.rs @@ -63,6 +63,7 @@ const X86_ALLOWED_FEATURES: &[(&str, Option)] = &[ ("bmi1", None), ("bmi2", None), ("cmpxchg16b", Some(sym::cmpxchg16b_target_feature)), + ("ermsb", Some(sym::ermsb_target_feature)), ("f16c", Some(sym::f16c_target_feature)), ("fma", None), ("fxsr", None), -- cgit 1.4.1-3-g733a5