Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit f7b4354

Browse files
committedMar 14, 2025
Auto merge of rust-lang#138480 - jhpratt:rollup-y3b8wu5, r=jhpratt
Rollup of 16 pull requests Successful merges: - rust-lang#136001 (Overhaul examples for PermissionsExt) - rust-lang#136230 (Reword incorrect documentation about SocketAddr having varying layout) - rust-lang#136892 (Sync Fuchsia target spec with clang Fuchsia driver) - rust-lang#136911 (Add documentation URL to selected jobs) - rust-lang#137870 ( Improve HashMap docs for const and static initializers) - rust-lang#138179 (Add `src/tools/x` to the main workspace) - rust-lang#138389 (use `expect` instead of `allow`) - rust-lang#138396 (Enable metrics and verbose tests in PR CI) - rust-lang#138398 (atomic intrinsics: clarify which types are supported and (if applicable) what happens with provenance) - rust-lang#138432 (fix: remove the check of lld not supporting `@response-file)` - rust-lang#138434 (Visit `PatField` when collecting lint levels) - rust-lang#138441 (update error message) - rust-lang#138442 (EUV: fix place of deref pattern's interior's scrutinee) - rust-lang#138457 (Remove usage of legacy scheme paths on RedoxOS) - rust-lang#138461 (Remove an outdated line from a test comment) - rust-lang#138466 (Remove myself from libs review) Failed merges: - rust-lang#138452 (Remove `RUN_CHECK_WITH_PARALLEL_QUERIES`) r? `@ghost` `@rustbot` modify labels: rollup
2 parents 523c507 + dea8a15 commit f7b4354

File tree

49 files changed

+488
-212
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+488
-212
lines changed
 
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,28 @@
1-
use crate::spec::{SanitizerSet, StackProbeType, Target, TargetMetadata, TargetOptions, base};
1+
use crate::spec::{
2+
Cc, LinkerFlavor, Lld, SanitizerSet, StackProbeType, Target, TargetMetadata, base,
3+
};
24

35
pub(crate) fn target() -> Target {
6+
let mut base = base::fuchsia::opts();
7+
base.cpu = "generic".into();
8+
base.features = "+v8a,+crc,+aes,+sha2,+neon".into();
9+
base.max_atomic_width = Some(128);
10+
base.stack_probes = StackProbeType::Inline;
11+
base.supported_sanitizers = SanitizerSet::ADDRESS
12+
| SanitizerSet::CFI
13+
| SanitizerSet::LEAK
14+
| SanitizerSet::SHADOWCALLSTACK;
15+
base.supports_xray = true;
16+
17+
base.add_pre_link_args(
18+
LinkerFlavor::Gnu(Cc::No, Lld::No),
19+
&[
20+
"--execute-only",
21+
// Enable the Cortex-A53 errata 843419 mitigation by default
22+
"--fix-cortex-a53-843419",
23+
],
24+
);
25+
426
Target {
527
llvm_target: "aarch64-unknown-fuchsia".into(),
628
metadata: TargetMetadata {
@@ -12,14 +34,6 @@ pub(crate) fn target() -> Target {
1234
pointer_width: 64,
1335
data_layout: "e-m:e-p270:32:32-p271:32:32-p272:64:64-i8:8:32-i16:16:32-i64:64-i128:128-n32:64-S128-Fn32".into(),
1436
arch: "aarch64".into(),
15-
options: TargetOptions {
16-
features: "+v8a".into(),
17-
max_atomic_width: Some(128),
18-
stack_probes: StackProbeType::Inline,
19-
supported_sanitizers: SanitizerSet::ADDRESS
20-
| SanitizerSet::CFI
21-
| SanitizerSet::SHADOWCALLSTACK,
22-
..base::fuchsia::opts()
23-
},
37+
options: base,
2438
}
2539
}
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,16 @@
1-
use crate::spec::{CodeModel, SanitizerSet, Target, TargetMetadata, TargetOptions, base};
1+
use crate::spec::{CodeModel, SanitizerSet, StackProbeType, Target, TargetMetadata, base};
22

33
pub(crate) fn target() -> Target {
4+
let mut base = base::fuchsia::opts();
5+
base.code_model = Some(CodeModel::Medium);
6+
base.cpu = "generic-rv64".into();
7+
base.features = "+m,+a,+f,+d,+c".into();
8+
base.llvm_abiname = "lp64d".into();
9+
base.max_atomic_width = Some(64);
10+
base.stack_probes = StackProbeType::Inline;
11+
base.supported_sanitizers = SanitizerSet::SHADOWCALLSTACK;
12+
base.supports_xray = true;
13+
414
Target {
515
llvm_target: "riscv64-unknown-fuchsia".into(),
616
metadata: TargetMetadata {
@@ -12,14 +22,6 @@ pub(crate) fn target() -> Target {
1222
pointer_width: 64,
1323
data_layout: "e-m:e-p:64:64-i64:64-i128:128-n32:64-S128".into(),
1424
arch: "riscv64".into(),
15-
options: TargetOptions {
16-
code_model: Some(CodeModel::Medium),
17-
cpu: "generic-rv64".into(),
18-
features: "+m,+a,+f,+d,+c".into(),
19-
llvm_abiname: "lp64d".into(),
20-
max_atomic_width: Some(64),
21-
supported_sanitizers: SanitizerSet::SHADOWCALLSTACK,
22-
..base::fuchsia::opts()
23-
},
25+
options: base,
2426
}
2527
}

‎compiler/rustc_target/src/spec/targets/x86_64_unknown_fuchsia.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,10 @@ pub(crate) fn target() -> Target {
44
let mut base = base::fuchsia::opts();
55
base.cpu = "x86-64".into();
66
base.plt_by_default = false;
7-
base.max_atomic_width = Some(64);
7+
// See https://fuchsia.dev/fuchsia-src/contribute/governance/rfcs/0073_x86_64_platform_requirement,
8+
// which corresponds to x86-64-v2.
9+
base.features = "+cx16,+sahf,+popcnt,+sse3,+sse4.1,+sse4.2,+ssse3".into();
10+
base.max_atomic_width = Some(128);
811
base.stack_probes = StackProbeType::Inline;
912
base.supported_sanitizers = SanitizerSet::ADDRESS | SanitizerSet::CFI | SanitizerSet::LEAK;
1013
base.supports_xray = true;
There was a problem loading the remainder of the diff.

0 commit comments

Comments
 (0)
Failed to load comments.