<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/tools/rustc-perf, branch 1.89.0</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=1.89.0</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=1.89.0'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2025-05-29T09:00:36+00:00</updated>
<entry>
<title>Bump rustc-perf and update PGO crates</title>
<updated>2025-05-29T09:00:36+00:00</updated>
<author>
<name>Michael Goulet</name>
<email>michael@errs.io</email>
</author>
<published>2025-05-23T14:58:24+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=73382e44174d79510a515488bafc1afa88920811'/>
<id>urn:sha1:73382e44174d79510a515488bafc1afa88920811</id>
<content type='text'>
</content>
</entry>
<entry>
<title>rustc-perf: update to `c0f3b53c8e5de87714d18a5f42998859302ae03a`</title>
<updated>2025-04-07T07:19:38+00:00</updated>
<author>
<name>Jieyou Xu</name>
<email>jieyouxu@outlook.com</email>
</author>
<published>2025-04-07T07:16:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=5f7fa4f97587092a851bfb23f8620ed0919c96c3'/>
<id>urn:sha1:5f7fa4f97587092a851bfb23f8620ed0919c96c3</id>
<content type='text'>
</content>
</entry>
<entry>
<title>bump rustc-perf</title>
<updated>2025-01-09T16:56:50+00:00</updated>
<author>
<name>Rémy Rakic</name>
<email>remy.rakic+github@gmail.com</email>
</author>
<published>2025-01-09T16:56:50+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=958a7722d172ca3864f1abee9f55bcd020b2ef09'/>
<id>urn:sha1:958a7722d172ca3864f1abee9f55bcd020b2ef09</id>
<content type='text'>
in particular to get the new benchmark error handling
</content>
</entry>
<entry>
<title>bump up rustc-perf's version</title>
<updated>2024-08-08T16:24:39+00:00</updated>
<author>
<name>Shina</name>
<email>53410646+s7tya@users.noreply.github.com</email>
</author>
<published>2024-08-08T16:24:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=85ec34182415f8ba475cc157f405c785db05e4be'/>
<id>urn:sha1:85ec34182415f8ba475cc157f405c785db05e4be</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Update `rustc-perf` submodule</title>
<updated>2024-06-12T09:45:52+00:00</updated>
<author>
<name>Jakub Beránek</name>
<email>berykubik@gmail.com</email>
</author>
<published>2024-06-12T09:45:52+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3bbd480f07dcc3a8b9516232d041eada63b10a81'/>
<id>urn:sha1:3bbd480f07dcc3a8b9516232d041eada63b10a81</id>
<content type='text'>
To integrate https://github.com/rust-lang/rustc-perf/pull/1926.
</content>
</entry>
<entry>
<title>chore: update src/tools/rustc-perf</title>
<updated>2024-06-03T15:38:23+00:00</updated>
<author>
<name>Weihang Lo</name>
<email>me@weihanglo.tw</email>
</author>
<published>2024-05-31T13:30:41+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=e9c4eb3cd31cd373867369e78b2695f1f5a3c299'/>
<id>urn:sha1:e9c4eb3cd31cd373867369e78b2695f1f5a3c299</id>
<content type='text'>
This is needed for fixing the missing license issue.

See https://github.com/rust-lang/rust/pull/125465.
</content>
</entry>
<entry>
<title>Update rustc-perf</title>
<updated>2024-05-24T15:25:46+00:00</updated>
<author>
<name>Weihang Lo</name>
<email>me@weihanglo.tw</email>
</author>
<published>2024-05-24T15:25:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=99c9b0775fba00de9a114be430506f30d65a34de'/>
<id>urn:sha1:99c9b0775fba00de9a114be430506f30d65a34de</id>
<content type='text'>
</content>
</entry>
<entry>
<title>refactor: add rustc-perf submodule to src/tools</title>
<updated>2024-05-20T14:56:49+00:00</updated>
<author>
<name>Bernardo Meurer Costa</name>
<email>bemeurer@amazon.com</email>
</author>
<published>2024-05-14T18:47:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=e287044149edf039ffd584557b4bf05507a9f213'/>
<id>urn:sha1:e287044149edf039ffd584557b4bf05507a9f213</id>
<content type='text'>
Currently, it's very challenging to perform a sandboxed `opt-dist`
bootstrap because the tool requires `rustc-perf` to be present, but
there is no proper management/tracking of it. Instead, a specific commit
is hardcoded where it is needed, and a non-checksummed zip is fetched
ad-hoc. This happens in two places:

`src/ci/docker/host-x86_64/dist-x86_64-linux/Dockerfile`:

```dockerfile
ENV PERF_COMMIT 4f313add609f43e928e98132358e8426ed3969ae
RUN curl -LS -o perf.zip https://ci-mirrors.rust-lang.org/rustc/rustc-perf-$PERF_COMMIT.zip &amp;&amp; \
    unzip perf.zip &amp;&amp; \
    mv rustc-perf-$PERF_COMMIT rustc-perf &amp;&amp; \
    rm perf.zip
```

`src/tools/opt-dist/src/main.rs`

```rust
// FIXME: add some mechanism for synchronization of this commit SHA with
// Linux (which builds rustc-perf in a Dockerfile)
// rustc-perf version from 2023-10-22
const PERF_COMMIT: &amp;str = "4f313add609f43e928e98132358e8426ed3969ae";

let url = format!("https://ci-mirrors.rust-lang.org/rustc/rustc-perf-{PERF_COMMIT}.zip");
let client = reqwest::blocking::Client::builder()
    .timeout(Duration::from_secs(60 * 2))
    .connect_timeout(Duration::from_secs(60 * 2))
    .build()?;
let response = retry_action(
    || Ok(client.get(&amp;url).send()?.error_for_status()?.bytes()?.to_vec()),
    "Download rustc-perf archive",
    5,
)?;
```

This causes a few issues:

1. Maintainers need to be careful to bump PERF_COMMIT in both places
   every time
2. In order to run `opt-dist` in a sandbox, you need to provide your own
   `rustc-perf` (https://github.com/rust-lang/rust/pull/125125), but to
   figure out which commit to provide you need to grep the Dockerfile
3. Even if you manage to provide the correct `rustc-perf`, its
   dependencies are not included in the `vendor/` dir created during
   `dist`, so it will fail to build from the published source tarballs
4. It is hard to provide any level of automation around updating the
   `rustc-perf` in use, leading to staleness

Fundamentally, this means `rustc-src` tarballs no longer contain
everything you need to bootstrap Rust, and packagers hoping to leverage
`opt-dist` need to go out of their way to keep track of this "hidden"
dependency on `rustc-perf`.

This change adds rustc-perf as a git submodule, pinned to the current
`PERF_COMMIT` 4f313add609f43e928e98132358e8426ed3969ae. Subsequent
commits ensure the submodule is initialized when necessary, and make use
of it in `opt-dist`.
</content>
</entry>
</feed>
