-
Notifications
You must be signed in to change notification settings - Fork 12.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update bootstrap to recognize the cputype 'sparcv9' (used on Solaris) * Change to never use -fomit-frame-pointer on Solaris or for sparc * Adds rust target sparcv9-sun-solaris Fixes #39901
- Loading branch information
1 parent
087c233
commit 2e756e2
Showing
4 changed files
with
47 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
// Copyright 2016 The Rust Project Developers. See the COPYRIGHT | ||
// file at the top-level directory of this distribution and at | ||
// http://rust-lang.org/COPYRIGHT. | ||
// | ||
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or | ||
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license | ||
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your | ||
// option. This file may not be copied, modified, or distributed | ||
// except according to those terms. | ||
|
||
use target::{Target, TargetResult}; | ||
|
||
pub fn target() -> TargetResult { | ||
let mut base = super::solaris_base::opts(); | ||
base.pre_link_args.push("-m64".to_string()); | ||
// llvm calls this "v9" | ||
base.cpu = "v9".to_string(); | ||
base.max_atomic_width = Some(64); | ||
|
||
Ok(Target { | ||
llvm_target: "sparcv9-sun-solaris".to_string(), | ||
target_endian: "big".to_string(), | ||
target_pointer_width: "64".to_string(), | ||
data_layout: "E-m:e-i64:64-n32:64-S128".to_string(), | ||
// Use "sparc64" instead of "sparcv9" here, since the former is already | ||
// used widely in the source base. If we ever needed ABI | ||
// differentiation from the sparc64, we could, but that would probably | ||
// just be confusing. | ||
arch: "sparc64".to_string(), | ||
target_os: "solaris".to_string(), | ||
target_env: "".to_string(), | ||
target_vendor: "sun".to_string(), | ||
options: base, | ||
}) | ||
} |