about summary refs log tree commit diff
path: root/compiler/rustc_transmute/src/lib.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-03-23 13:57:55 +0000
committerbors <bors@rust-lang.org>2024-03-23 13:57:55 +0000
commitd6eb0f5a09247ff8443e68b4d17e0350c74bafb1 (patch)
treeaa13e444d15635e819516aa6b016ab83061d7022 /compiler/rustc_transmute/src/lib.rs
parentc3b05c6e5b5b59613350b8c2875b0add67ed74df (diff)
parent75d2e5b1236afc5f8211726ac24887f59f47f09b (diff)
downloadrust-d6eb0f5a09247ff8443e68b4d17e0350c74bafb1.tar.gz
rust-d6eb0f5a09247ff8443e68b4d17e0350c74bafb1.zip
Auto merge of #122582 - scottmcm:swap-intrinsic-v2, r=oli-obk
Let codegen decide when to `mem::swap` with immediates

Making `libcore` decide this is silly; the backend has so much better information about when it's a good idea.

Thus this PR introduces a new `typed_swap` intrinsic with a fallback body, and replaces that fallback implementation when swapping immediates or scalar pairs.

r? oli-obk

Replaces #111744, and means we'll never need more libs PRs like #111803 or #107140
Diffstat (limited to 'compiler/rustc_transmute/src/lib.rs')
0 files changed, 0 insertions, 0 deletions