diff options
| author | Alistair Francis <alistair.francis@wdc.com> | 2020-09-16 08:42:39 -0700 |
|---|---|---|
| committer | Alistair Francis <alistair.francis@wdc.com> | 2020-09-16 08:42:55 -0700 |
| commit | de0d55cb3c197b13d90922c8998bf90399f3b8a2 (patch) | |
| tree | 960ef743f1386cfe58d958099eba79c1b58e3781 /library/panic_unwind/src | |
| parent | e968f86f7162304e9a59bd89bd0fe40e8db1ac6d (diff) | |
| download | rust-de0d55cb3c197b13d90922c8998bf90399f3b8a2.tar.gz rust-de0d55cb3c197b13d90922c8998bf90399f3b8a2.zip | |
library/panic_unwind: Add UNWIND_DATA_REG for RISC-V 32-bit
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Diffstat (limited to 'library/panic_unwind/src')
| -rw-r--r-- | library/panic_unwind/src/gcc.rs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/library/panic_unwind/src/gcc.rs b/library/panic_unwind/src/gcc.rs index 85a2a18947d..81b7b556eb4 100644 --- a/library/panic_unwind/src/gcc.rs +++ b/library/panic_unwind/src/gcc.rs @@ -123,6 +123,9 @@ const UNWIND_DATA_REG: (i32, i32) = (0, 1); // R0, R1 #[cfg(target_arch = "riscv64")] const UNWIND_DATA_REG: (i32, i32) = (10, 11); // x10, x11 +#[cfg(target_arch = "riscv32")] +const UNWIND_DATA_REG: (i32, i32) = (10, 11); // x10, x11 + // The following code is based on GCC's C and C++ personality routines. For reference, see: // https://github.com/gcc-mirror/gcc/blob/master/libstdc++-v3/libsupc++/eh_personality.cc // https://github.com/gcc-mirror/gcc/blob/trunk/libgcc/unwind-c.c |
