rust/compiler/rustc_codegen_ssa
许杰友 Jieyou Xu (Joe) 2d3b1e014b
Rollup merge of #124251 - scottmcm:unop-ptr-metadata, r=oli-obk
Add an intrinsic for `ptr::metadata`

The follow-up to #123840, so we can remove `PtrComponents` and `PtrRepr` from libcore entirely (well, after a bootstrap update).

As discussed in <https://rust-lang.zulipchat.com/#narrow/stream/189540-t-compiler.2Fwg-mir-opt/topic/.60ptr_metadata.60.20in.20MIR/near/435637808>, this introduces `UnOp::PtrMetadata` taking a raw pointer and returning the associated metadata value.

By no longer going through a `union`, this should also help future PRs better optimize pointer operations.

r? ``@oli-obk``
2024-05-29 03:25:07 +01:00
..
src Rollup merge of #124251 - scottmcm:unop-ptr-metadata, r=oli-obk 2024-05-29 03:25:07 +01:00
Cargo.toml Make SSA aggregates without needing an alloca 2024-05-08 20:38:04 -07:00
messages.ftl emit an error if we can't find a path to the self-contained linker 2024-05-23 15:47:35 +00:00
README.md mv compiler to compiler/ 2020-08-30 18:45:07 +03:00

Please read the rustc-dev-guide chapter on Backend Agnostic Codegen.