diff --git a/compiler/rustc_target/src/spec/x86_64_unknown_uefi.rs b/compiler/rustc_target/src/spec/x86_64_unknown_uefi.rs index b7dcce5f895..be0e62bea02 100644 --- a/compiler/rustc_target/src/spec/x86_64_unknown_uefi.rs +++ b/compiler/rustc_target/src/spec/x86_64_unknown_uefi.rs @@ -5,7 +5,7 @@ // The win64 ABI is used. It differs from the sysv64 ABI, so we must use a windows target with // LLVM. "x86_64-unknown-windows" is used to get the minimal subset of windows-specific features. -use crate::spec::{CodeModel, Target}; +use crate::spec::Target; pub fn target() -> Target { let mut base = super::uefi_msvc_base::opts(); @@ -19,15 +19,11 @@ pub fn target() -> Target { // to leave these uninitialized, thus triggering exceptions if we make use of them. Which is // why we avoid them and instead use soft-floats. This is also what GRUB and friends did so // far. + // // If you initialize FP units yourself, you can override these flags with custom linker // arguments, thus giving you access to full MMX/SSE acceleration. base.features = "-mmx,-sse,+soft-float".to_string(); - // UEFI systems run without a host OS, hence we cannot assume any code locality. We must tell - // LLVM to expect code to reference any address in the address-space. The "large" code-model - // places no locality-restrictions, so it fits well here. - base.code_model = Some(CodeModel::Large); - Target { llvm_target: "x86_64-unknown-windows".to_string(), pointer_width: 64,