From 4d65dd04104d167b6ccf1c0ed9656c5c7193ef06 Mon Sep 17 00:00:00 2001 From: James Duley Date: Sun, 20 Jan 2019 11:44:11 +0000 Subject: [PATCH 1/2] Fix aarch64 typo --- src/libcore/ffi.rs | 4 ++-- src/librustc_codegen_llvm/va_arg.rs | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/libcore/ffi.rs b/src/libcore/ffi.rs index 644380c69f2c7..8ee7297a8cc52 100644 --- a/src/libcore/ffi.rs +++ b/src/libcore/ffi.rs @@ -47,7 +47,7 @@ impl fmt::Debug for c_void { /// Basic implementation of a `va_list`. #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), not(target_arch = "x86_64")), - all(target_arch = "aarch4", target_os = "ios"), + all(target_arch = "aarch64", target_os = "ios"), windows))] #[unstable(feature = "c_variadic", reason = "the `c_variadic` feature has not been properly tested on \ @@ -193,7 +193,7 @@ impl<'a> VaList<'a> { where F: for<'copy> FnOnce(VaList<'copy>) -> R { #[cfg(any(all(not(target_arch = "aarch64"), not(target_arch = "powerpc"), not(target_arch = "x86_64")), - all(target_arch = "aarch4", target_os = "ios"), + all(target_arch = "aarch64", target_os = "ios"), windows))] let mut ap = va_copy(self); #[cfg(all(any(target_arch = "aarch64", target_arch = "powerpc", target_arch = "x86_64"), diff --git a/src/librustc_codegen_llvm/va_arg.rs b/src/librustc_codegen_llvm/va_arg.rs index 9239f85a8f230..960118a7b08bc 100644 --- a/src/librustc_codegen_llvm/va_arg.rs +++ b/src/librustc_codegen_llvm/va_arg.rs @@ -109,12 +109,12 @@ pub(super) fn emit_va_arg( Align::from_bytes(4).unwrap(), true) } // Windows Aarch64 - ("aarch4", true) => { + ("aarch64", true) => { emit_ptr_va_arg(bx, addr, target_ty, false, Align::from_bytes(8).unwrap(), false) } // iOS Aarch64 - ("aarch4", _) if target.target_os == "ios" => { + ("aarch64", _) if target.target_os == "ios" => { emit_ptr_va_arg(bx, addr, target_ty, false, Align::from_bytes(8).unwrap(), true) } From c1858f298a39e12616755726a593a76a6dedbc52 Mon Sep 17 00:00:00 2001 From: James Duley Date: Sun, 20 Jan 2019 11:47:29 +0000 Subject: [PATCH 2/2] Fix AArch64 typo in comments --- src/libcore/ffi.rs | 2 +- src/librustc_codegen_llvm/va_arg.rs | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libcore/ffi.rs b/src/libcore/ffi.rs index 8ee7297a8cc52..583c155a78795 100644 --- a/src/libcore/ffi.rs +++ b/src/libcore/ffi.rs @@ -67,7 +67,7 @@ impl fmt::Debug for VaListImpl { } /// AArch64 ABI implementation of a `va_list`. See the -/// [Aarch64 Procedure Call Standard] for more details. +/// [AArch64 Procedure Call Standard] for more details. /// /// [AArch64 Procedure Call Standard]: /// http://infocenter.arm.com/help/topic/com.arm.doc.ihi0055b/IHI0055B_aapcs64.pdf diff --git a/src/librustc_codegen_llvm/va_arg.rs b/src/librustc_codegen_llvm/va_arg.rs index 960118a7b08bc..7d4770d6b8272 100644 --- a/src/librustc_codegen_llvm/va_arg.rs +++ b/src/librustc_codegen_llvm/va_arg.rs @@ -108,12 +108,12 @@ pub(super) fn emit_va_arg( emit_ptr_va_arg(bx, addr, target_ty, false, Align::from_bytes(4).unwrap(), true) } - // Windows Aarch64 + // Windows AArch64 ("aarch64", true) => { emit_ptr_va_arg(bx, addr, target_ty, false, Align::from_bytes(8).unwrap(), false) } - // iOS Aarch64 + // iOS AArch64 ("aarch64", _) if target.target_os == "ios" => { emit_ptr_va_arg(bx, addr, target_ty, false, Align::from_bytes(8).unwrap(), true)