rustc_target/spec/targets/
thumbv8m_main_nuttx_eabihf.rs

1// Targets the Cortex-M33 processor (Armv8-M Mainline architecture profile),
2// with the Floating Point extension.
3
4use crate::spec::{FloatAbi, Target, TargetOptions, base, cvs};
5
6pub(crate) fn target() -> Target {
7    Target {
8        llvm_target: "thumbv8m.main-none-eabihf".into(),
9        metadata: crate::spec::TargetMetadata {
10            description: None,
11            tier: Some(3),
12            host_tools: None,
13            std: Some(true),
14        },
15        pointer_width: 32,
16        data_layout: "e-m:e-p:32:32-Fi8-i64:64-v128:64:128-a:0:32-n32-S64".into(),
17        arch: "arm".into(),
18
19        options: TargetOptions {
20            families: cvs!["unix"],
21            os: "nuttx".into(),
22            abi: "eabihf".into(),
23            llvm_floatabi: Some(FloatAbi::Hard),
24            // If the Floating Point extension is implemented in the Cortex-M33
25            // processor, the Cortex-M33 Technical Reference Manual states that
26            // the FPU uses the FPv5 architecture, single-precision instructions
27            // and 16 D registers.
28            features: "+fp-armv8d16sp".into(),
29            max_atomic_width: Some(32),
30            ..base::thumb::opts()
31        },
32    }
33}