about summary refs log tree commit diff
path: root/library/std/src/sys
diff options
context:
space:
mode:
authorDirreke <mingyang_ge@163.com>2023-07-13 22:19:59 +0800
committerdirreke <mingyang_ge@163.com>2023-08-14 23:02:36 +0800
commitd16409fe228f07c8a702ace7b42c1e1196ff85e6 (patch)
tree3e8ff9bcf8ce8a8cccd58511150bc24adff55301 /library/std/src/sys
parent3071e0aef6dfd0a150c3fb1da0abad4ec86ca0aa (diff)
downloadrust-d16409fe228f07c8a702ace7b42c1e1196ff85e6.tar.gz
rust-d16409fe228f07c8a702ace7b42c1e1196ff85e6.zip
add a csky-unknown-linux-gnuabiv2 target
Diffstat (limited to 'library/std/src/sys')
-rw-r--r--library/std/src/sys/common/alloc.rs1
-rw-r--r--library/std/src/sys/personality/gcc.rs3
2 files changed, 4 insertions, 0 deletions
diff --git a/library/std/src/sys/common/alloc.rs b/library/std/src/sys/common/alloc.rs
index 3ccea3ce0e3..d58aa6c27b8 100644
--- a/library/std/src/sys/common/alloc.rs
+++ b/library/std/src/sys/common/alloc.rs
@@ -8,6 +8,7 @@ use crate::ptr;
     target_arch = "x86",
     target_arch = "arm",
     target_arch = "m68k",
+    target_arch = "csky",
     target_arch = "mips",
     target_arch = "mips32r6",
     target_arch = "powerpc",
diff --git a/library/std/src/sys/personality/gcc.rs b/library/std/src/sys/personality/gcc.rs
index dc9636ac8c9..e477a0cd7ab 100644
--- a/library/std/src/sys/personality/gcc.rs
+++ b/library/std/src/sys/personality/gcc.rs
@@ -67,6 +67,9 @@ const UNWIND_DATA_REG: (i32, i32) = (0, 1); // D0, D1
 ))]
 const UNWIND_DATA_REG: (i32, i32) = (4, 5); // A0, A1
 
+#[cfg(target_arch = "csky")]
+const UNWIND_DATA_REG: (i32, i32) = (0, 1); // R0, R1
+
 #[cfg(any(target_arch = "powerpc", target_arch = "powerpc64"))]
 const UNWIND_DATA_REG: (i32, i32) = (3, 4); // R3, R4 / X3, X4