Skip to content

Commit

Permalink
Use CodeModel::Kernel for x86_64-unknown-none-elf.
Browse files Browse the repository at this point in the history
  • Loading branch information
mikeleany committed Sep 19, 2021
1 parent 2b57012 commit 108b0d8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion compiler/rustc_target/src/spec/x86_64_unknown_none_elf.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
//
// For example, `-C target-cpu=cortex-a53`.

use super::{LinkerFlavor, LldFlavor, PanicStrategy, Target, TargetOptions};
use super::{CodeModel, LinkerFlavor, LldFlavor, PanicStrategy, Target, TargetOptions};

pub fn target() -> Target {
let opts = TargetOptions {
Expand All @@ -17,6 +17,7 @@ pub fn target() -> Target {
executables: true,
disable_redzone: true,
panic_strategy: PanicStrategy::Abort,
code_model: Some(CodeModel::Kernel),
..Default::default()
};
Target {
Expand Down

0 comments on commit 108b0d8

Please sign in to comment.