Skip to content

Rollup of 7 pull requests #142186

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 18 commits into from

Conversation

matthiaskrgr
Copy link
Member

@matthiaskrgr matthiaskrgr commented Jun 8, 2025

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

heiher and others added 18 commits June 5, 2025 07:59
also adjust the wording a little so that we don't say "the error occurred here" for two different spans
Many of `std`'s dependency have a dependency on the crates.io
`compiler-builtins` when used with the feature
`rustc-std-workspace-core`. Use a Cargo patch to select the in-tree
version instead.

`compiler-builtins` is also added as a dependency of
`rustc-std-workspace-core` so these crates can remove their crates.io
dependency in the future.
Make NonZero<char> possible

I'd like to use `NonZero<char>` for representing units of CStr in https://github.com/rust-lang/literal-escaper
…r=bjorn3

Atomic intrinsics : use const generic ordering, part 2

This completes what got started in rust-lang#141507 by using a const generic for the ordering for all intrinsics. It is based on that PR; only the last commit is new.

Blocked on:
- rust-lang#141507
- rust-lang#141687
- rust-lang/stdarch#1811
- rust-lang#141964

r? `@bjorn3`
…jorn3

Use the in-tree `compiler-builtins` for the sysroot

Many of `std`'s dependency have a dependency on the crates.io `compiler-builtins` when used with the feature `rustc-std-workspace-core`. Use a Cargo patch to select the in-tree version instead.

`compiler-builtins` is also added as a dependency of `rustc-std-workspace-core` so these crates can remove their crates.io dependency in the future.

Zulip discussion: [#t-compiler > Using in-tree compiler-builtins](https://rust-lang.zulipchat.com/#narrow/channel/131828-t-compiler/topic/Using.20in-tree.20compiler-builtins/with/522445336)

Once this merges, the following PRs will need to make it to a release for the relevant crates:

- rust-lang/getopts#119 (can merge at any time)
- rust-lang/hashbrown#625 (can merge at any time)
- rust-lang/stdarch#1825
- rust-lang/rustc-demangle#80
- rust-lang/cfg-if#84
- unicode-rs/unicode-width#77

The above should cover all tier 1 targets with no `std` features enabled. The remaining cover the rest:

- alexcrichton/dlmalloc-rs#50 (wasm, xous, sgx)
- gimli-rs/gimli#769
- r-efi/r-efi#89 (efi)
- r-efi/r-efi-alloc#9 (efi)
- fortanix/rust-sgx#770 (sgx)
- hermit-os/hermit-rs#718 (hermit)
- bytecodealliance/wasi-rs#108 (wasi)
- gimli-rs/addr2line#345
- oyvindln/adler2#2
- BurntSushi/memchr#180
- Frommi/miniz_oxide#173
- gimli-rs/object#777

try-job: dist-x86_64-linux
try-job: x86_64-gnu
try-job: x86_64-gnu-aux
try-job: test-various
…oli-obk

const-eval error: always say in which item the error occurred

I don't see why "is this generic" should make a difference. It may be reasonable to key this on whether the error occurs in a `const fn` that was invoked by a const (making it non-obvious which constant it is) vs inside the body of the const.

r? ``@oli-obk``
Add new Tier-3 targets: `loongarch32-unknown-none*`

MCP: rust-lang/compiler-team#865

NOTE: LoongArch32 ELF object support is available starting with object v0.37.0.
`tests/ui`: A New Order [6/N]

> [!NOTE]
>
> Intermediate commits are intended to help review, but will be squashed prior to merge.

Some `tests/ui/` housekeeping, to trim down number of tests directly under `tests/ui/`. Part of rust-lang#133895.

r? `@jieyouxu`

auxiliary tag means some changes in realted auxiliary file for test
… r=workingjubilee

store `target.min_global_align` as an `Align`

Parse the alignment properly when the target is defined/parsed, and error out on invalid alignment values. That means this work doesn't need to happen for every global in each backend.
@rustbot rustbot added A-compiler-builtins Area: compiler-builtins (https://github.com/rust-lang/compiler-builtins) A-compiletest Area: The compiletest test runner A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-linux Operating system: Linux S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. rollup A PR which is a rollup labels Jun 8, 2025
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Collaborator

bors commented Jun 8, 2025

📌 Commit a292c65 has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jun 8, 2025
@bors
Copy link
Collaborator

bors commented Jun 8, 2025

⌛ Testing commit a292c65 with merge aee342b...

bors added a commit that referenced this pull request Jun 8, 2025
Rollup of 7 pull requests

Successful merges:

 - #141001 (Make NonZero<char> possible)
 - #141700 (Atomic intrinsics : use const generic ordering, part 2)
 - #141993 (Use the in-tree `compiler-builtins` for the sysroot)
 - #142008 (const-eval error: always say in which item the error occurred)
 - #142053 (Add new Tier-3 targets: `loongarch32-unknown-none*`)
 - #142132 (`tests/ui`: A New Order [6/N])
 - #142179 (store `target.min_global_align` as an `Align`)

r? `@ghost`
`@rustbot` modify labels: rollup
@rust-log-analyzer
Copy link
Collaborator

The job dist-android failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
[RUSTC-TIMING] profiler_builtins test:false 0.025
error[E0133]: call to unsafe function `core::intrinsics::transmute` is unsafe and requires unsafe block
 --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:7:55
  |
7 |     let f: extern "C" fn(u32, u32, *mut u32) -> u32 = mem::transmute(0xffff0fc0usize as *const ());
  |                                                       ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
  |
  = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
  = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
 --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:6:1
  |
6 | unsafe fn __kuser_cmpxchg(oldval: u32, newval: u32, ptr: *mut u32) -> bool {
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  = note: `-D unsafe-op-in-unsafe-fn` implied by `-D warnings`
  = help: to override `-D warnings` add `#[allow(unsafe_op_in_unsafe_fn)]`

error[E0133]: call to unsafe function `core::intrinsics::transmute` is unsafe and requires unsafe block
  --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:12:30
   |
12 |     let f: extern "C" fn() = mem::transmute(0xffff0fa0usize as *const ());
   |                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
   |
   = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
   = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
---

error[E0133]: call to unsafe function `arm_linux::atomic_load_aligned` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:103:30
    |
103 |         let curval_aligned = atomic_load_aligned::<T>(aligned_ptr);
    |                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:98:1
    |
98  | unsafe fn atomic_rmw<T, F: Fn(u32) -> u32, G: Fn(u32, u32) -> u32>(ptr: *mut T, f: F, g: G) -> u32 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0133]: call to unsafe function `arm_linux::__kuser_cmpxchg` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:107:12
    |
107 |         if __kuser_cmpxchg(curval_aligned, newval_aligned, aligned_ptr) {
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior

error[E0133]: call to unsafe function `arm_linux::atomic_load_aligned` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:119:30
    |
119 |         let curval_aligned = atomic_load_aligned::<T>(aligned_ptr);
    |                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:114:1
    |
114 | unsafe fn atomic_cmpxchg<T>(ptr: *mut T, oldval: u32, newval: u32) -> u32 {
    | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

error[E0133]: call to unsafe function `arm_linux::__kuser_cmpxchg` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:125:12
    |
125 |         if __kuser_cmpxchg(curval_aligned, newval_aligned, aligned_ptr) {
    |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
158 |   atomic_rmw!(@old __sync_fetch_and_add_1, u8, |a: u8, b: u8| a.wrapping_add(b));
    |   ------------------------------------------------------------------------------ in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
141 |   |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |   |          ------------------------------------------ in this macro invocation (#2)
...     |
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
158 |      atomic_rmw!(@old __sync_fetch_and_add_1, u8, |a: u8, b: u8| a.wrapping_add(b));
    |      ------------------------------------------------------------------------------ in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
159 | / atomic_rmw!(@old __sync_fetch_and_add_2, u16, |a: u16, b: u16| a
160 | |     .wrapping_add(b));
    | |_____________________- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
159 |     / atomic_rmw!(@old __sync_fetch_and_add_2, u16, |a: u16, b: u16| a
160 |     |     .wrapping_add(b));
    |     |_____________________- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
161 | / atomic_rmw!(@old __sync_fetch_and_add_4, u32, |a: u32, b: u32| a
162 | |     .wrapping_add(b));
    | |_____________________- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
161 |     / atomic_rmw!(@old __sync_fetch_and_add_4, u32, |a: u32, b: u32| a
162 |     |     .wrapping_add(b));
    |     |_____________________- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
145 | |         atomic_rmw!($name, $ty, $op, |_, new| new);
    | |         ------------------------------------------ in this macro invocation (#2)
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
164 |   atomic_rmw!(@new __sync_add_and_fetch_1, u8, |a: u8, b: u8| a.wrapping_add(b));
    |   ------------------------------------------------------------------------------ in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
145 |   |          atomic_rmw!($name, $ty, $op, |_, new| new);
    |   |          ------------------------------------------ in this macro invocation (#2)
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
164 |      atomic_rmw!(@new __sync_add_and_fetch_1, u8, |a: u8, b: u8| a.wrapping_add(b));
    |      ------------------------------------------------------------------------------ in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
145 | |         atomic_rmw!($name, $ty, $op, |_, new| new);
    | |         ------------------------------------------ in this macro invocation (#2)
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
165 | / atomic_rmw!(@new __sync_add_and_fetch_2, u16, |a: u16, b: u16| a
166 | |     .wrapping_add(b));
    | |_____________________- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
145 |    |          atomic_rmw!($name, $ty, $op, |_, new| new);
    |    |          ------------------------------------------ in this macro invocation (#2)
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
165 |     / atomic_rmw!(@new __sync_add_and_fetch_2, u16, |a: u16, b: u16| a
166 |     |     .wrapping_add(b));
    |     |_____________________- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
145 | |         atomic_rmw!($name, $ty, $op, |_, new| new);
    | |         ------------------------------------------ in this macro invocation (#2)
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
167 | / atomic_rmw!(@new __sync_add_and_fetch_4, u32, |a: u32, b: u32| a
168 | |     .wrapping_add(b));
    | |_____________________- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
145 |    |          atomic_rmw!($name, $ty, $op, |_, new| new);
    |    |          ------------------------------------------ in this macro invocation (#2)
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
167 |     / atomic_rmw!(@new __sync_add_and_fetch_4, u32, |a: u32, b: u32| a
168 |     |     .wrapping_add(b));
    |     |_____________________- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
170 |   atomic_rmw!(@old __sync_fetch_and_sub_1, u8, |a: u8, b: u8| a.wrapping_sub(b));
    |   ------------------------------------------------------------------------------ in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
141 |   |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |   |          ------------------------------------------ in this macro invocation (#2)
...     |
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
170 |      atomic_rmw!(@old __sync_fetch_and_sub_1, u8, |a: u8, b: u8| a.wrapping_sub(b));
    |      ------------------------------------------------------------------------------ in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
214 |     / atomic_rmw!(@old __sync_fetch_and_max_1, i8, |a: i8, b: i8| if a > b {
215 |     |     a
216 |     | } else {
217 |     |     b
218 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
219 | / atomic_rmw!(@old __sync_fetch_and_max_2, i16, |a: i16, b: i16| if a > b {
220 | |     a
221 | | } else {
222 | |     b
223 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
219 |     / atomic_rmw!(@old __sync_fetch_and_max_2, i16, |a: i16, b: i16| if a > b {
220 |     |     a
221 |     | } else {
222 |     |     b
223 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
224 | / atomic_rmw!(@old __sync_fetch_and_max_4, i32, |a: i32, b: i32| if a > b {
225 | |     a
226 | | } else {
227 | |     b
228 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
224 |     / atomic_rmw!(@old __sync_fetch_and_max_4, i32, |a: i32, b: i32| if a > b {
225 |     |     a
226 |     | } else {
227 |     |     b
228 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
230 | / atomic_rmw!(@old __sync_fetch_and_umax_1, u8, |a: u8, b: u8| if a > b {
231 | |     a
232 | | } else {
233 | |     b
234 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
230 |     / atomic_rmw!(@old __sync_fetch_and_umax_1, u8, |a: u8, b: u8| if a > b {
231 |     |     a
232 |     | } else {
233 |     |     b
234 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
235 | / atomic_rmw!(@old __sync_fetch_and_umax_2, u16, |a: u16, b: u16| if a > b {
236 | |     a
237 | | } else {
238 | |     b
239 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
235 |     / atomic_rmw!(@old __sync_fetch_and_umax_2, u16, |a: u16, b: u16| if a > b {
236 |     |     a
237 |     | } else {
238 |     |     b
239 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
240 | / atomic_rmw!(@old __sync_fetch_and_umax_4, u32, |a: u32, b: u32| if a > b {
241 | |     a
242 | | } else {
243 | |     b
244 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
240 |     / atomic_rmw!(@old __sync_fetch_and_umax_4, u32, |a: u32, b: u32| if a > b {
241 |     |     a
242 |     | } else {
243 |     |     b
244 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
246 | / atomic_rmw!(@old __sync_fetch_and_min_1, i8, |a: i8, b: i8| if a < b {
247 | |     a
248 | | } else {
249 | |     b
250 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
246 |     / atomic_rmw!(@old __sync_fetch_and_min_1, i8, |a: i8, b: i8| if a < b {
247 |     |     a
248 |     | } else {
249 |     |     b
250 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
251 | / atomic_rmw!(@old __sync_fetch_and_min_2, i16, |a: i16, b: i16| if a < b {
252 | |     a
253 | | } else {
254 | |     b
255 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
251 |     / atomic_rmw!(@old __sync_fetch_and_min_2, i16, |a: i16, b: i16| if a < b {
252 |     |     a
253 |     | } else {
254 |     |     b
255 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
256 | / atomic_rmw!(@old __sync_fetch_and_min_4, i32, |a: i32, b: i32| if a < b {
257 | |     a
258 | | } else {
259 | |     b
260 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
256 |     / atomic_rmw!(@old __sync_fetch_and_min_4, i32, |a: i32, b: i32| if a < b {
257 |     |     a
258 |     | } else {
259 |     |     b
260 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
262 | / atomic_rmw!(@old __sync_fetch_and_umin_1, u8, |a: u8, b: u8| if a < b {
263 | |     a
264 | | } else {
265 | |     b
266 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
262 |     / atomic_rmw!(@old __sync_fetch_and_umin_1, u8, |a: u8, b: u8| if a < b {
263 |     |     a
264 |     | } else {
265 |     |     b
266 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
267 | / atomic_rmw!(@old __sync_fetch_and_umin_2, u16, |a: u16, b: u16| if a < b {
268 | |     a
269 | | } else {
270 | |     b
271 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
267 |     / atomic_rmw!(@old __sync_fetch_and_umin_2, u16, |a: u16, b: u16| if a < b {
268 |     |     a
269 |     | } else {
270 |     |     b
271 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
272 | / atomic_rmw!(@old __sync_fetch_and_umin_4, u32, |a: u32, b: u32| if a < b {
273 | |     a
274 | | } else {
275 | |     b
276 | | });
    | |__- in this macro invocation (#1)
---
    |
52  | /     macro_rules! intrinsics {
53  | |         () => ();
...   |
469 | |             pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |         );
486 | |     }
    | |_____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |    /  macro_rules! atomic_rmw {
132 |    |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |    |/         intrinsics! {
134 |    ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |    ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |    ||             }
137 |    ||         }
    |    ||_________- in this macro invocation (#3)
...      |
141 |    |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |    |          ------------------------------------------ in this macro invocation (#2)
...      |
146 |    |      };
147 |    |  }
    |    |  -
    |    |  |
    |    |__in this expansion of `atomic_rmw!` (#1)
    |       in this expansion of `atomic_rmw!` (#2)
...
272 |     / atomic_rmw!(@old __sync_fetch_and_umin_4, u32, |a: u32, b: u32| if a < b {
273 |     |     a
274 |     | } else {
275 |     |     b
276 |     | });
    |     |__- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
278 |   atomic_rmw!(@old __sync_lock_test_and_set_1, u8, |_: u8, b: u8| b);
    |   ------------------------------------------------------------------ in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
141 |   |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |   |          ------------------------------------------ in this macro invocation (#2)
...     |
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
278 |      atomic_rmw!(@old __sync_lock_test_and_set_1, u8, |_: u8, b: u8| b);
    |      ------------------------------------------------------------------ in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
279 |   atomic_rmw!(@old __sync_lock_test_and_set_2, u16, |_: u16, b: u16| b);
    |   --------------------------------------------------------------------- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
141 |   |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |   |          ------------------------------------------ in this macro invocation (#2)
...     |
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
279 |      atomic_rmw!(@old __sync_lock_test_and_set_2, u16, |_: u16, b: u16| b);
    |      --------------------------------------------------------------------- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_rmw` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:135:17
    |
131 | / macro_rules! atomic_rmw {
132 | |     ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 | |         intrinsics! {
134 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 | |                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
141 | |         atomic_rmw!($name, $ty, $op, |old, _| old);
    | |         ------------------------------------------ in this macro invocation (#2)
...   |
146 | |     };
147 | | }
    | | -
    | | |
    | |_in this expansion of `atomic_rmw!` (#1)
    |   in this expansion of `atomic_rmw!` (#2)
...
280 |   atomic_rmw!(@old __sync_lock_test_and_set_4, u32, |_: u32, b: u32| b);
    |   --------------------------------------------------------------------- in this macro invocation (#1)
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /    macro_rules! intrinsics {
53  | |        () => ();
...   |
469 | |            pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |        );
486 | |    }
    | |____- in this expansion of `intrinsics!` (#3)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:131:1
    |
131 |   /  macro_rules! atomic_rmw {
132 |   |      ($name:ident, $ty:ty, $op:expr, $fetch:expr) => {
133 |   |/         intrinsics! {
134 |   ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, val: $ty) -> $ty {
135 |   ||                 atomic_rmw(ptr, |x| $op(x as $ty, val) as u32, |old, new| $fetch(old, new)) as $ty
136 |   ||             }
137 |   ||         }
    |   ||_________- in this macro invocation (#3)
...     |
141 |   |          atomic_rmw!($name, $ty, $op, |old, _| old);
    |   |          ------------------------------------------ in this macro invocation (#2)
...     |
146 |   |      };
147 |   |  }
    |   |  -
    |   |  |
    |   |__in this expansion of `atomic_rmw!` (#1)
    |      in this expansion of `atomic_rmw!` (#2)
...
280 |      atomic_rmw!(@old __sync_lock_test_and_set_4, u32, |_: u32, b: u32| b);
    |      --------------------------------------------------------------------- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_cmpxchg` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:152:17
    |
148 | / macro_rules! atomic_cmpxchg {
149 | |     ($name:ident, $ty:ty) => {
150 | |         intrinsics! {
151 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 | |                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
155 | |     };
156 | | }
    | |_- in this expansion of `atomic_cmpxchg!`
...
282 |   atomic_cmpxchg!(__sync_val_compare_and_swap_1, u8);
    |   -------------------------------------------------- in this macro invocation
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /   macro_rules! intrinsics {
53  | |       () => ();
...   |
469 | |           pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |       );
486 | |   }
    | |___- in this expansion of `intrinsics!` (#2)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:148:1
    |
148 |  /  macro_rules! atomic_cmpxchg {
149 |  |      ($name:ident, $ty:ty) => {
150 |  |/         intrinsics! {
151 |  ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 |  ||                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
153 |  ||             }
154 |  ||         }
    |  ||_________- in this macro invocation (#2)
155 |  |      };
156 |  |  }
    |  |__- in this expansion of `atomic_cmpxchg!` (#1)
...
282 |     atomic_cmpxchg!(__sync_val_compare_and_swap_1, u8);
    |     -------------------------------------------------- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_cmpxchg` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:152:17
    |
148 | / macro_rules! atomic_cmpxchg {
149 | |     ($name:ident, $ty:ty) => {
150 | |         intrinsics! {
151 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 | |                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
155 | |     };
156 | | }
    | |_- in this expansion of `atomic_cmpxchg!`
...
283 |   atomic_cmpxchg!(__sync_val_compare_and_swap_2, u16);
    |   --------------------------------------------------- in this macro invocation
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /   macro_rules! intrinsics {
53  | |       () => ();
...   |
469 | |           pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |       );
486 | |   }
    | |___- in this expansion of `intrinsics!` (#2)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:148:1
    |
148 |  /  macro_rules! atomic_cmpxchg {
149 |  |      ($name:ident, $ty:ty) => {
150 |  |/         intrinsics! {
151 |  ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 |  ||                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
153 |  ||             }
154 |  ||         }
    |  ||_________- in this macro invocation (#2)
155 |  |      };
156 |  |  }
    |  |__- in this expansion of `atomic_cmpxchg!` (#1)
...
283 |     atomic_cmpxchg!(__sync_val_compare_and_swap_2, u16);
    |     --------------------------------------------------- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::atomic_cmpxchg` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:152:17
    |
148 | / macro_rules! atomic_cmpxchg {
149 | |     ($name:ident, $ty:ty) => {
150 | |         intrinsics! {
151 | |             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 | |                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
    | |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
...   |
155 | |     };
156 | | }
    | |_- in this expansion of `atomic_cmpxchg!`
...
284 |   atomic_cmpxchg!(__sync_val_compare_and_swap_4, u32);
    |   --------------------------------------------------- in this macro invocation
    |
    = note: for more information, see <https://doc.rust-lang.org/nightly/edition-guide/rust-2024/unsafe-op-in-unsafe-fn.html>
    = note: consult the function's documentation for information on how to avoid undefined behavior
note: an unsafe function restricts its caller, but its body is safe by default
   --> library/compiler-builtins/compiler-builtins/src/macros.rs:469:9
    |
52  | /   macro_rules! intrinsics {
53  | |       () => ();
...   |
469 | |           pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |       );
486 | |   }
    | |___- in this expansion of `intrinsics!` (#2)
    |
   ::: library/compiler-builtins/compiler-builtins/src/arm_linux.rs:148:1
    |
148 |  /  macro_rules! atomic_cmpxchg {
149 |  |      ($name:ident, $ty:ty) => {
150 |  |/         intrinsics! {
151 |  ||             pub unsafe extern "C" fn $name(ptr: *mut $ty, oldval: $ty, newval: $ty) -> $ty {
152 |  ||                 atomic_cmpxchg(ptr, oldval as u32, newval as u32) as $ty
153 |  ||             }
154 |  ||         }
    |  ||_________- in this macro invocation (#2)
155 |  |      };
156 |  |  }
    |  |__- in this expansion of `atomic_cmpxchg!` (#1)
...
284 |     atomic_cmpxchg!(__sync_val_compare_and_swap_4, u32);
    |     --------------------------------------------------- in this macro invocation (#1)

error[E0133]: call to unsafe function `arm_linux::__kuser_memory_barrier` is unsafe and requires unsafe block
   --> library/compiler-builtins/compiler-builtins/src/arm_linux.rs:288:9
    |
288 |         __kuser_memory_barrier();
    |         ^^^^^^^^^^^^^^^^^^^^^^^^ call to unsafe function
    |
---
    |
52  | /  macro_rules! intrinsics {
53  | |      () => ();
...   |
469 | |          pub $(unsafe $($empty)?)? extern $abi fn $name( $($argname: $ty),* ) $(-> $ret)? {
    | |          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
...   |
485 | |      );
486 | |  }
    | |__- in this expansion of `intrinsics!`

@bors
Copy link
Collaborator

bors commented Jun 8, 2025

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jun 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-compiler-builtins Area: compiler-builtins (https://github.com/rust-lang/compiler-builtins) A-compiletest Area: The compiletest test runner A-LLVM Area: Code generation parts specific to LLVM. Both correctness bugs and optimization-related issues. A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc O-linux Operating system: Linux rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants