rust/compiler/rustc_codegen_ssa/src/traits
bors d6eb0f5a09 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
2024-03-23 13:57:55 +00:00
..
abi.rs Merge apply_attrs_callsite into call and invoke 2022-10-01 17:01:31 +00:00
asm.rs Implement asm goto for LLVM and GCC backend 2024-02-24 18:50:09 +00:00
backend.rs Remove CodegenBackend::target_override. 2024-03-21 11:48:49 +11:00
builder.rs Let codegen decide when to mem::swap with immediates 2024-03-17 11:59:18 -07:00
consts.rs cg_ssa: remove pointee types and pointercast/bitcast-of-ptr 2023-07-29 13:18:20 -04:00
coverageinfo.rs Remove trait CoverageInfoMethods, since non-LLVM backends don't need it 2023-07-05 20:40:40 +10:00
debuginfo.rs Deduplicate inlined function debug info, but create a new lexical scope to child subsequent scopes and variables from colliding 2023-09-01 14:27:21 -07:00
declare.rs Remove DeclareMethods 2020-09-18 13:11:59 +02:00
intrinsic.rs Teach llvm backend how to fall back to default bodies 2024-02-12 17:50:39 +00:00
misc.rs Remove several unused methods from MiscMethods 2022-10-01 16:45:07 +00:00
mod.rs Implement printing to file in llvm_util 2023-07-20 11:04:31 -07:00
statics.rs Check whether a static is mutable instead of passing it down 2024-03-12 05:53:46 +00:00
type_.rs Let codegen decide when to mem::swap with immediates 2024-03-17 11:59:18 -07:00
write.rs Rename many DiagCtxt arguments. 2023-12-18 16:06:22 +11:00