<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/compiler/rustc_incremental/src/persist, branch stable</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=stable</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=stable'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2025-05-01T08:20:31+00:00</updated>
<entry>
<title>Use thread local dep graph encoding</title>
<updated>2025-05-01T08:20:31+00:00</updated>
<author>
<name>John Kåre Alsaker</name>
<email>john.kare.alsaker@gmail.com</email>
</author>
<published>2025-04-11T19:27:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d3ec14bbec7d3647a3c1a3bfdf2cafb0f72bf937'/>
<id>urn:sha1:d3ec14bbec7d3647a3c1a3bfdf2cafb0f72bf937</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Replace infallible `name_or_empty` methods with fallible `name` methods.</title>
<updated>2025-04-16T23:50:52+00:00</updated>
<author>
<name>Nicholas Nethercote</name>
<email>n.nethercote@gmail.com</email>
</author>
<published>2025-04-10T04:33:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=2fef0a30ae6b2687dfb286cb544d2a542f7e2335'/>
<id>urn:sha1:2fef0a30ae6b2687dfb286cb544d2a542f7e2335</id>
<content type='text'>
I'm removing empty identifiers everywhere, because in practice they
always mean "no identifier" rather than "empty identifier". (An empty
identifier is impossible.) It's better to use `Option` to mean "no
identifier" because you then can't forget about the "no identifier"
possibility.

Some specifics:
- When testing an attribute for a single name, the commit uses the
  `has_name` method.
- When testing an attribute for multiple names, the commit uses the new
  `has_any_name` method.
- When using `match` on an attribute, the match arms now have `Some` on
  them.

In the tests, we now avoid printing empty identifiers by not printing
the identifier in the `error:` line at all, instead letting the carets
point out the problem.
</content>
</entry>
<entry>
<title>Remove safe remove</title>
<updated>2025-04-14T18:47:15+00:00</updated>
<author>
<name>Chris Denton</name>
<email>chris@chrisdenton.dev</email>
</author>
<published>2025-04-14T18:35:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1d757833c6aa126e468275c1cd7285dee53a1de6'/>
<id>urn:sha1:1d757833c6aa126e468275c1cd7285dee53a1de6</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Auto merge of #138629 - Zoxc:graph-anon-hashmap, r=oli-obk</title>
<updated>2025-03-24T15:02:09+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2025-03-24T15:02:09+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=4510e86a41388733675465a8647d4235f3bf2023'/>
<id>urn:sha1:4510e86a41388733675465a8647d4235f3bf2023</id>
<content type='text'>
Only use the new node hashmap for anonymous nodes

This is a rebase of https://github.com/rust-lang/rust/pull/112469.

cc `@cjgillot`
</content>
</entry>
<entry>
<title>Auto merge of #128320 - saethlin:link-me-maybe, r=compiler-errors</title>
<updated>2025-03-21T21:03:49+00:00</updated>
<author>
<name>bors</name>
<email>bors@rust-lang.org</email>
</author>
<published>2025-03-21T21:03:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=48b36c9d5943a4aef49aa04b8059b92d65ff31a9'/>
<id>urn:sha1:48b36c9d5943a4aef49aa04b8059b92d65ff31a9</id>
<content type='text'>
Avoid no-op unlink+link dances in incr comp

Incremental compilation scales quite poorly with the number of CGUs. This PR improves one reason for that.

The incr comp process hard-links all the files from an old session into a new one, then it runs the backend, which may just hard-link the new session files into the output directory. Then codegen hard-links all the output files back to the new session directory.

This PR (perhaps unimaginatively) fixes the silliness that ensues in the last step. The old `link_or_copy` implementation would be passed pairs of paths which are already the same inode, then it would blindly delete the destination and re-create the hard-link that it just deleted. This PR lets us skip both those operations. We don't skip the other two hard-links.

`cargo +stage1 b &amp;&amp; touch crates/core/main.rs &amp;&amp; strace -cfw -elink,linkat,unlink,unlinkat cargo +stage1 b` before and then after on `ripgrep-13.0.0`:
```
% time     seconds  usecs/call     calls    errors syscall
------ ----------- ----------- --------- --------- ----------------
 52.56    0.024950          25       978       485 unlink
 34.38    0.016318          22       727           linkat
 13.06    0.006200          24       249           unlinkat
------ ----------- ----------- --------- --------- ----------------
100.00    0.047467          24      1954       485 total
```
```
% time     seconds  usecs/call     calls    errors syscall
------ ----------- ----------- --------- --------- ----------------
 42.83    0.014521          57       252           unlink
 38.41    0.013021          26       486           linkat
 18.77    0.006362          25       249           unlinkat
------ ----------- ----------- --------- --------- ----------------
100.00    0.033904          34       987           total
```

This reduces the number of hard-links that are causing perf troubles, noted in https://github.com/rust-lang/rust/issues/64291 and https://github.com/rust-lang/rust/issues/137560
</content>
</entry>
<entry>
<title>Pass in dep kind names to the duplicate dep node check</title>
<updated>2025-03-19T19:12:37+00:00</updated>
<author>
<name>John Kåre Alsaker</name>
<email>john.kare.alsaker@gmail.com</email>
</author>
<published>2025-03-18T21:26:44+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=68fd771bc1f186bfa7e825d8a87ac8f06a6efced'/>
<id>urn:sha1:68fd771bc1f186bfa7e825d8a87ac8f06a6efced</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Only use the new node hashmap for anonymous nodes.</title>
<updated>2025-03-19T19:12:37+00:00</updated>
<author>
<name>Camille GILLOT</name>
<email>gillot.camille@gmail.com</email>
</author>
<published>2023-03-12T10:56:20+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=5a21f890e9b6aad452638a45e0ebce025da7334f'/>
<id>urn:sha1:5a21f890e9b6aad452638a45e0ebce025da7334f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Update rand to 0.9.0</title>
<updated>2025-03-10T01:21:57+00:00</updated>
<author>
<name>Chris Denton</name>
<email>chris@chrisdenton.dev</email>
</author>
<published>2025-02-01T19:35:47+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=1c7aaf95e1bb77c99437fa260f84124ac30808f0'/>
<id>urn:sha1:1c7aaf95e1bb77c99437fa260f84124ac30808f0</id>
<content type='text'>
</content>
</entry>
<entry>
<title>compiler: Use size_of from the prelude instead of imported</title>
<updated>2025-03-07T21:37:04+00:00</updated>
<author>
<name>Thalia Archibald</name>
<email>thalia@archibald.dev</email>
</author>
<published>2025-03-05T04:28:38+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=38fad984c616cf4d10f653fa50c85cdc01083373'/>
<id>urn:sha1:38fad984c616cf4d10f653fa50c85cdc01083373</id>
<content type='text'>
Use `std::mem::{size_of, size_of_val, align_of, align_of_val}` from the
prelude instead of importing or qualifying them.

These functions were added to all preludes in Rust 1.80.
</content>
</entry>
<entry>
<title>Avoid no-op unlink+link dances in incr comp</title>
<updated>2025-02-25T00:46:48+00:00</updated>
<author>
<name>Ben Kimock</name>
<email>kimockb@gmail.com</email>
</author>
<published>2024-07-28T20:54:14+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=cae7c76d509386ea29a90c4001bb8dbc59c79d22'/>
<id>urn:sha1:cae7c76d509386ea29a90c4001bb8dbc59c79d22</id>
<content type='text'>
</content>
</entry>
</feed>
