<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/compiler/rustc_codegen_cranelift/src/base.rs, branch perf-tmp</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2025-10-02T01:54:48+00:00</updated>
<entry>
<title>Auto merge of #147055 - beepster4096:subtype_is_not_a_projection, r=lcnr</title>
<updated>2025-10-02T01:54:48+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2025-10-02T01:54:48+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=42b384ec0dfcd528d99a4db0a337d9188a9eecaa'/>
<id>urn:sha1:42b384ec0dfcd528d99a4db0a337d9188a9eecaa</id>
<content type='text'>
Turn ProjectionElem::Subtype into CastKind::Subtype

I noticed that drop elaboration can't, in general, handle `ProjectionElem::SubType`. It creates a disjoint move path that overlaps with other move paths. (`Subslice` does too, and I'm working on a different PR to make that special case less fragile.) If its skipped and treated as the same move path as its parent then `MovePath.place` has multiple possible projections. (It would probably make sense to remove all `Subtype` projections for the canonical place but it doesn't make sense to have this special case for a problem that doesn't actually occur in real MIR.)

The only reason this doesn't break is that `Subtype` is always the sole projection of the local its applied to. For the same reason, it works fine as a `CastKind` so I figured that makes more sense than documenting and validating this hidden invariant.

cc rust-lang/rust#112651, rust-lang/rust#133258

r? Icnr (bc you've been the main person dealing with `Subtype` it looks like)
</content>
</entry>
<entry>
<title>remove explicit deref of AbiAlign for most methods</title>
<updated>2025-09-28T22:02:14+00:00</updated>
<author>
<name>Jubilee Young</name>
<email>workingjubilee@gmail.com</email>
</author>
<published>2025-09-28T21:40:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=0c9d0dfe046f0674f0507df564504ac3bac862d9'/>
<id>urn:sha1:0c9d0dfe046f0674f0507df564504ac3bac862d9</id>
<content type='text'>
Much of the compiler calls functions on Align projected from AbiAlign.
AbiAlign impls Deref to its inner Align, so we can simplify these away.
Also, it will minimize disruption when AbiAlign is removed.

For now, preserve usages that might resolve to PartialOrd or PartialEq,
as those have odd inference.
</content>
</entry>
<entry>
<title>ProjectionElem::Subtype -&gt; CastKind::Subtype</title>
<updated>2025-09-26T08:25:26+00:00</updated>
<author>
<name>beepster4096</name>
<email>19316085+beepster4096@users.noreply.github.com</email>
</author>
<published>2025-09-26T03:54:54+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=aa5a21450a070fdea66a07d3cab3b69e6735c328'/>
<id>urn:sha1:aa5a21450a070fdea66a07d3cab3b69e6735c328</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Remove Rvalue::Len.</title>
<updated>2025-09-16T22:23:19+00:00</updated>
<author>
<name>Camille Gillot</name>
<email>gillot.camille@gmail.com</email>
</author>
<published>2025-09-14T22:29:04+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=53b91ea87fe4b430c33bd22dfdaaa6289bf9466a'/>
<id>urn:sha1:53b91ea87fe4b430c33bd22dfdaaa6289bf9466a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Introduce `MirDumper` and `MirWriter`.</title>
<updated>2025-08-31T23:19:03+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2025-08-15T04:38:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=5ce3797073ee5e6cc487b80effbc682533d9425c'/>
<id>urn:sha1:5ce3797073ee5e6cc487b80effbc682533d9425c</id>
<content type='text'>
MIR dumping is a mess. There are lots of functions and entry points,
e.g. `dump_mir`, `dump_mir_with_options`, `dump_polonius_mir`,
`dump_mir_to_writer`. Also, it's crucial that `create_dump_file` is
never called without `dump_enabled` first being checked, but there is no
mechanism for ensuring this and it's hard to tell if it is satisfied on
all paths. (`dump_enabled` is checked twice on some paths, however!)

This commit introduces `MirWriter`, which controls the MIR writing, and
encapsulates the `extra_data` closure and `options`. Two existing
functions are now methods of this type. It sets reasonable defaults,
allowing the removal of many `|_, _| Ok(())` closures.

The commit also introduces `MirDumper`, which is layered on top of
`MirWriter`, and which manages the creation of the dump files,
encapsulating pass names, disambiguators, etc. Four existing functions
are now methods of this type.
- `MirDumper::new` will only succeed if dumps are enabled, and will
  return `None` otherwise, which makes it impossible to dump when you
  shouldn't.
- It also sets reasonable defaults for various things like
  disambiguators, which means you no longer need to specify them in many
  cases. When they do need to be specified, it's now done via setter
  methods.
- It avoids some repetition. E.g. `dump_nll_mir` previously specifed the
  pass name `"nll"` four times and the disambiguator `&amp;0` three times;
  now it specifies them just once, to put them in the `MirDumper`.
- For Polonius, the `extra_data` closure can now be specified earlier,
  which avoids having to pass some arguments through some functions.
</content>
</entry>
<entry>
<title>Avoid unnecessary `mut`-ness for various closures.</title>
<updated>2025-08-31T22:52:34+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2025-08-14T23:13:23+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d7faa5630daf13c3d298e81ac329bf048a0d5a01'/>
<id>urn:sha1:d7faa5630daf13c3d298e81ac329bf048a0d5a01</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Remove support for dyn*</title>
<updated>2025-07-01T19:00:21+00:00</updated>
<author>
<name>Michael Goulet</name>
<email>michael@errs.io</email>
</author>
<published>2025-06-26T02:01:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=2516c339829cd9193c15464218a981b8547157ca'/>
<id>urn:sha1:2516c339829cd9193c15464218a981b8547157ca</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Insert checks for enum discriminants when debug assertions are enabled</title>
<updated>2025-06-27T09:37:36+00:00</updated>
<author>
<name>Bastian Kersting</name>
<email>bkersting@google.com</email>
</author>
<published>2025-05-15T19:09:13+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1087042e22ae3d14ff856f621a84eaa3e15cc537'/>
<id>urn:sha1:1087042e22ae3d14ff856f621a84eaa3e15cc537</id>
<content type='text'>
Similar to the existing nullpointer and alignment checks, this checks
for valid enum discriminants on creation of enums through unsafe
transmutes. Essentially this sanitizes patterns like the following:
```rust
let val: MyEnum = unsafe { std::mem::transmute&lt;u32, MyEnum&gt;(42) };
```
An extension of this check will be done in a follow-up that explicitly
sanitizes for extern enum values that come into Rust from e.g. C/C++.

This check is similar to Miri's capabilities of checking for valid
construction of enum values.

This PR is inspired by saethlin@'s PR
https://github.com/rust-lang/rust/pull/104862. Thank you so much for
keeping this code up and the detailed comments!

I also pair-programmed large parts of this together with vabr-g@.
</content>
</entry>
<entry>
<title>Replace some `Option&lt;Span&gt;` with `Span` and use DUMMY_SP instead of None</title>
<updated>2025-06-05T14:14:59+00:00</updated>
<author>
<name>Oli Scherer</name>
<email>github333195615777966@oli-obk.de</email>
</author>
<published>2025-06-04T06:26:56+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=fd3da4bebdff63b7529483ff7025986ef16bf463'/>
<id>urn:sha1:fd3da4bebdff63b7529483ff7025986ef16bf463</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Merge commit '979dcf8e2f213e4f4b645cb62e7fe9f4f2c0c785' into sync_cg_clif-2025-05-25</title>
<updated>2025-05-25T18:51:16+00:00</updated>
<author>
<name>bjorn3</name>
<email>17426603+bjorn3@users.noreply.github.com</email>
</author>
<published>2025-05-25T18:51:16+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3816385b09db445ab580043ed45218df8c1198ad'/>
<id>urn:sha1:3816385b09db445ab580043ed45218df8c1198ad</id>
<content type='text'>
</content>
</entry>
</feed>
