Skip to content

Commit 6777146

Browse files
authored
Rollup merge of rust-lang#81455 - Amanieu:aarch64_ilp32, r=sanxiyn
Add AArch64 big-endian and ILP32 targets This PR adds 3 new AArch64 targets: - `aarch64_be-unknown-linux-gnu` - `aarch64-unknown-linux-gnu_ilp32` - `aarch64_be-unknown-linux-gnu_ilp32` It also fixes some ABI issues on big-endian ARM and AArch64.
2 parents 1d26014 + e886a3f commit 6777146

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

std/src/os/linux/raw.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -247,17 +247,17 @@ mod arch {
247247
use crate::os::raw::{c_int, c_long};
248248

249249
#[stable(feature = "raw_ext", since = "1.1.0")]
250-
pub type blkcnt_t = u64;
250+
pub type blkcnt_t = i64;
251251
#[stable(feature = "raw_ext", since = "1.1.0")]
252-
pub type blksize_t = u64;
252+
pub type blksize_t = i32;
253253
#[stable(feature = "raw_ext", since = "1.1.0")]
254254
pub type ino_t = u64;
255255
#[stable(feature = "raw_ext", since = "1.1.0")]
256-
pub type nlink_t = u64;
256+
pub type nlink_t = u32;
257257
#[stable(feature = "raw_ext", since = "1.1.0")]
258-
pub type off_t = u64;
258+
pub type off_t = i64;
259259
#[stable(feature = "raw_ext", since = "1.1.0")]
260-
pub type time_t = i64;
260+
pub type time_t = c_long;
261261

262262
#[repr(C)]
263263
#[derive(Clone)]
@@ -288,15 +288,15 @@ mod arch {
288288
#[stable(feature = "raw_ext", since = "1.1.0")]
289289
pub st_blocks: i64,
290290
#[stable(feature = "raw_ext", since = "1.1.0")]
291-
pub st_atime: i64,
291+
pub st_atime: time_t,
292292
#[stable(feature = "raw_ext", since = "1.1.0")]
293293
pub st_atime_nsec: c_long,
294294
#[stable(feature = "raw_ext", since = "1.1.0")]
295-
pub st_mtime: i64,
295+
pub st_mtime: time_t,
296296
#[stable(feature = "raw_ext", since = "1.1.0")]
297297
pub st_mtime_nsec: c_long,
298298
#[stable(feature = "raw_ext", since = "1.1.0")]
299-
pub st_ctime: i64,
299+
pub st_ctime: time_t,
300300
#[stable(feature = "raw_ext", since = "1.1.0")]
301301
pub st_ctime_nsec: c_long,
302302
#[stable(feature = "raw_ext", since = "1.1.0")]

unwind/src/libunwind.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,12 @@ pub const unwinder_private_data_size: usize = 20;
3636
#[cfg(all(target_arch = "arm", target_os = "ios"))]
3737
pub const unwinder_private_data_size: usize = 5;
3838

39-
#[cfg(target_arch = "aarch64")]
39+
#[cfg(all(target_arch = "aarch64", target_pointer_width = "64"))]
4040
pub const unwinder_private_data_size: usize = 2;
4141

42+
#[cfg(all(target_arch = "aarch64", target_pointer_width = "32"))]
43+
pub const unwinder_private_data_size: usize = 5;
44+
4245
#[cfg(target_arch = "mips")]
4346
pub const unwinder_private_data_size: usize = 2;
4447

0 commit comments

Comments
 (0)