1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
use crate::spec::abi::Abi;
use crate::spec::{LinkerFlavor, MergeFunctions, PanicStrategy, Target, TargetOptions};
pub fn target() -> Target {
Target {
arch: "nvptx64".to_string(),
data_layout: "e-i64:64-i128:128-v16:16-v32:32-n16:32:64".to_string(),
llvm_target: "nvptx64-nvidia-cuda".to_string(),
pointer_width: 64,
options: TargetOptions {
os: "cuda".to_string(),
vendor: "nvidia".to_string(),
linker_flavor: LinkerFlavor::PtxLinker,
linker: Some("rust-ptx-linker".to_string()),
cpu: "sm_30".to_string(),
max_atomic_width: Some(64),
panic_strategy: PanicStrategy::Abort,
dynamic_linking: true,
executables: true,
only_cdylib: true,
obj_is_bitcode: true,
dll_prefix: "".to_string(),
dll_suffix: ".ptx".to_string(),
exe_suffix: ".ptx".to_string(),
merge_functions: MergeFunctions::Disabled,
unsupported_abis: vec![
Abi::Cdecl,
Abi::Stdcall,
Abi::Fastcall,
Abi::Vectorcall,
Abi::Thiscall,
Abi::Aapcs,
Abi::Win64,
Abi::SysV64,
Abi::Msp430Interrupt,
Abi::X86Interrupt,
Abi::AmdGpuKernel,
],
..Default::default()
},
}
}