about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-09-27 17:28:47 +0000
committerbors <bors@rust-lang.org>2024-09-27 17:28:47 +0000
commitfa724e5d8cbbdfbd1e53c4c656121af01b694406 (patch)
treecb03957ec3e5050d456cb76445a55c146af42ce6 /compiler/rustc_codegen_llvm/src
parenta3f76a26e045a760bb1163b7eab36872985242d5 (diff)
parent966a0b76bc21ba65071b4d50dfb0536e0581604f (diff)
downloadrust-fa724e5d8cbbdfbd1e53c4c656121af01b694406.tar.gz
rust-fa724e5d8cbbdfbd1e53c4c656121af01b694406.zip
Auto merge of #130934 - matthiaskrgr:rollup-4puticr, r=matthiaskrgr
Rollup of 7 pull requests

Successful merges:

 - #129087 (Stabilize `option_get_or_insert_default`)
 - #130435 (Move Apple linker args from `rustc_target` to `rustc_codegen_ssa`)
 - #130459 (delete sub build directory "debug" to not delete the change-id file)
 - #130873 (rustc_target: Add powerpc64 atomic-related features)
 - #130916 (Use `&raw` in the compiler)
 - #130917 (Fix error span if arg to `asm!()` is a macro call)
 - #130927 (update outdated comments)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'compiler/rustc_codegen_llvm/src')
-rw-r--r--compiler/rustc_codegen_llvm/src/back/archive.rs2
-rw-r--r--compiler/rustc_codegen_llvm/src/lib.rs4
-rw-r--r--compiler/rustc_codegen_llvm/src/llvm_util.rs2
3 files changed, 4 insertions, 4 deletions
diff --git a/compiler/rustc_codegen_llvm/src/back/archive.rs b/compiler/rustc_codegen_llvm/src/back/archive.rs
index 1b4f6682af0..33a956e552f 100644
--- a/compiler/rustc_codegen_llvm/src/back/archive.rs
+++ b/compiler/rustc_codegen_llvm/src/back/archive.rs
@@ -123,7 +123,7 @@ fn get_llvm_object_symbols(
         llvm::LLVMRustGetSymbols(
             buf.as_ptr(),
             buf.len(),
-            std::ptr::addr_of_mut!(*state) as *mut c_void,
+            (&raw mut *state) as *mut c_void,
             callback,
             error_callback,
         )
diff --git a/compiler/rustc_codegen_llvm/src/lib.rs b/compiler/rustc_codegen_llvm/src/lib.rs
index bdfc0f626f8..b85d28a2f1f 100644
--- a/compiler/rustc_codegen_llvm/src/lib.rs
+++ b/compiler/rustc_codegen_llvm/src/lib.rs
@@ -167,7 +167,7 @@ impl WriteBackendMethods for LlvmCodegenBackend {
     fn print_pass_timings(&self) {
         unsafe {
             let mut size = 0;
-            let cstr = llvm::LLVMRustPrintPassTimings(std::ptr::addr_of_mut!(size));
+            let cstr = llvm::LLVMRustPrintPassTimings(&raw mut size);
             if cstr.is_null() {
                 println!("failed to get pass timings");
             } else {
@@ -180,7 +180,7 @@ impl WriteBackendMethods for LlvmCodegenBackend {
     fn print_statistics(&self) {
         unsafe {
             let mut size = 0;
-            let cstr = llvm::LLVMRustPrintStatistics(std::ptr::addr_of_mut!(size));
+            let cstr = llvm::LLVMRustPrintStatistics(&raw mut size);
             if cstr.is_null() {
                 println!("failed to get pass stats");
             } else {
diff --git a/compiler/rustc_codegen_llvm/src/llvm_util.rs b/compiler/rustc_codegen_llvm/src/llvm_util.rs
index 71fd7afb148..a2a5499597c 100644
--- a/compiler/rustc_codegen_llvm/src/llvm_util.rs
+++ b/compiler/rustc_codegen_llvm/src/llvm_util.rs
@@ -478,7 +478,7 @@ pub(crate) fn print(req: &PrintRequest, mut out: &mut String, sess: &Session) {
                     &tm,
                     cpu_cstring.as_ptr(),
                     callback,
-                    std::ptr::addr_of_mut!(out) as *mut c_void,
+                    (&raw mut out) as *mut c_void,
                 );
             }
         }