Skip to content

Conversation

@fee1-dead
Copy link
Member

@fee1-dead fee1-dead commented Oct 19, 2025

Example:

const X: &'static [u32] = {
    let mut v = Vec::with_capacity(6);
    let mut x = 1;
    while x < 42 {
        v.push(x);
        x *= 2;
    }
    assert!(v.len() == 6);
    v.const_make_global()
};

assert_eq!([1, 2, 4, 8, 16, 32], X);

Oh this is fun...

  • We split out the implementation of Global such that it calls intrinsics::const_allocate and intrinsics::const_deallocate during compile time. This is achieved using const_eval_select
  • This allows us to impl const Allocator for Global
  • We then constify everything necessary for Vec::with_capacity and Vec::push.
  • Added Vec::const_make_global to leak and intern the final value via intrinsics::const_make_global. If we see any pointer in the final value of a const that did not call const_make_global, we error as implemented in add const_make_global; err for const_allocate ptrs if didn't call #143595.

r? @rust-lang/wg-const-eval

To-do for me:

  • Assess the rustdoc impact of additional bounds in the method
  • Increase test coverage I think this is enough for an unstable feature.

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue. labels Oct 20, 2025
@fee1-dead fee1-dead marked this pull request as draft October 20, 2025 00:00
@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Oct 20, 2025
@rust-log-analyzer

This comment has been minimized.

@oli-obk oli-obk assigned oli-obk and unassigned RalfJung Oct 20, 2025
Copy link
Member

@RalfJung RalfJung left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We used to have the plan to have a dedicated compile-time allocator type... this is an interesting alternative. Given that it also involves the library surface, we should probably involve t-libs-api.

Why have you picked Vec as the first type for this? I think it'd make more sense for Box to go first since that is the most primitive type for heap allocations.

View changes since this review

Comment on lines 377 to 382
let mut offset = 0;
while offset < size {
offset += 1;
// SAFETY: the pointer returned by `const_allocate` is valid to write to.
ptr.add(offset).write(0)
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be much more efficient to use write_bytes here.

/// `Vec<T>` created during compile time.
#[unstable(feature = "const_heap", issue = "79597")]
#[rustc_const_unstable(feature = "const_heap", issue = "79597")]
pub const fn const_leak(mut self) -> &'static [T] {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is conceptually quite different from leak which IMO should be reflected in the name, so I would indeed prefer const_make_global.

/// `Vec<T>` created during compile time.
#[unstable(feature = "const_heap", issue = "79597")]
#[rustc_const_unstable(feature = "const_heap", issue = "79597")]
pub const fn const_leak(mut self) -> &'static [T] {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This needs a where T: Freeze for soundness.

}

/// Leaks the `Vec<T>` to be interned statically. This mut be done for all
/// `Vec<T>` created during compile time.
Copy link
Member

@RalfJung RalfJung Oct 20, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't need to be done for all Vec created during compile-time -- only for those that you want to carry over to runtime. You can use intermediate Vec as scratch space or so during compile time that you never call this method on.

@fee1-dead
Copy link
Member Author

I think it'd make more sense for Box to go first since that is the most primitive type for heap allocations.

That will either require us doing a const_eval_select to do box_new in runtime and something else in compile time, or to constify box_new. I chose Vec because I thought it would be much more useful than Box.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@oli-obk
Copy link
Contributor

oli-obk commented Oct 26, 2025

@bors try @rust-timer queue
This affects core pieces of vec and alloc, let's make sure everything gets optimized well

@rust-timer

This comment has been minimized.

@rust-bors

This comment has been minimized.

rust-bors bot added a commit that referenced this pull request Oct 26, 2025
@rustbot rustbot added the S-waiting-on-perf Status: Waiting on a perf run to be completed. label Oct 26, 2025
@rust-bors
Copy link

rust-bors bot commented Oct 26, 2025

☀️ Try build successful (CI)
Build commit: b3f7ade (b3f7ade975cf0d5d02740da43e496064c977dfb4, parent: f977dfc388ea39c9886b7f8c49abce26e6918df6)

@rust-timer

This comment has been minimized.

@rust-timer
Copy link
Collaborator

Finished benchmarking commit (b3f7ade): comparison URL.

Overall result: ❌✅ regressions and improvements - please read the text below

Benchmarking this pull request means it may be perf-sensitive – we'll automatically label it not fit for rolling up. You can override this, but we strongly advise not to, due to possible changes in compiler perf.

Next Steps: If you can justify the regressions found in this try perf run, please do so in sufficient writing along with @rustbot label: +perf-regression-triaged. If not, please fix the regressions and do another perf run. If its results are neutral or positive, the label will be automatically removed.

@bors rollup=never
@rustbot label: -S-waiting-on-perf +perf-regression

Instruction count

Our most reliable metric. Used to determine the overall result above. However, even this metric can be noisy.

mean range count
Regressions ❌
(primary)
0.3% [0.3%, 0.3%] 1
Regressions ❌
(secondary)
0.2% [0.1%, 0.2%] 3
Improvements ✅
(primary)
-0.6% [-0.6%, -0.6%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) -0.2% [-0.6%, 0.3%] 2

Max RSS (memory usage)

Results (primary 0.4%, secondary -0.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
2.7% [1.3%, 4.5%] 5
Regressions ❌
(secondary)
3.7% [3.7%, 3.7%] 1
Improvements ✅
(primary)
-2.0% [-3.3%, -0.4%] 5
Improvements ✅
(secondary)
-2.3% [-3.1%, -1.6%] 2
All ❌✅ (primary) 0.4% [-3.3%, 4.5%] 10

Cycles

Results (primary 3.3%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
3.3% [3.3%, 3.3%] 1
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 3.3% [3.3%, 3.3%] 1

Binary size

Results (primary 0.3%, secondary 0.6%)

A less reliable metric. May be of interest, but not used to determine the overall result above.

mean range count
Regressions ❌
(primary)
0.4% [0.0%, 1.5%] 33
Regressions ❌
(secondary)
0.6% [0.0%, 1.0%] 66
Improvements ✅
(primary)
-0.2% [-0.5%, -0.0%] 5
Improvements ✅
(secondary)
-0.1% [-0.1%, -0.1%] 1
All ❌✅ (primary) 0.3% [-0.5%, 1.5%] 38

Bootstrap: 473.751s -> 473.82s (0.01%)
Artifact size: 390.43 MiB -> 390.55 MiB (0.03%)

@rustbot rustbot added perf-regression Performance regression. and removed S-waiting-on-perf Status: Waiting on a perf run to be completed. labels Oct 27, 2025
@fee1-dead fee1-dead marked this pull request as ready for review October 28, 2025 21:51
@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Oct 28, 2025
@fee1-dead fee1-dead removed the S-blocked Status: Blocked on something else such as an RFC or other implementation work. label Dec 21, 2025
@fee1-dead
Copy link
Member Author

Updated and the rustdoc regression should be minimal now (just things getting regrouped under different impl blocks).

As this is going to be a nightly feature I think the amount of testing is okay here, let me know if you want some edge cases to be tested.

@oli-obk
Copy link
Contributor

oli-obk commented Dec 27, 2025

@bors r+

@bors
Copy link
Collaborator

bors commented Dec 27, 2025

📌 Commit 3cc8d08 has been approved by oli-obk

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Dec 27, 2025
bors added a commit that referenced this pull request Dec 28, 2025
`Vec::push` in consts MVP

Example:

```rust
const X: &'static [u32] = {
    let mut v = Vec::with_capacity(6);
    let mut x = 1;
    while x < 42 {
        v.push(x);
        x *= 2;
    }
    assert!(v.len() == 6);
    v.const_make_global()
};

assert_eq!([1, 2, 4, 8, 16, 32], X);
```

Oh this is fun...

* We split out the implementation of `Global` such that it calls `intrinsics::const_allocate` and `intrinsics::const_deallocate` during compile time. This is achieved using `const_eval_select`
* This allows us to `impl const Allocator for Global`
* We then constify everything necessary for `Vec::with_capacity` and `Vec::push`.
* Added `Vec::const_make_global` to leak and intern the final value via `intrinsics::const_make_global`. If we see any pointer in the final value of a `const` that did not call `const_make_global`, we error as implemented in #143595.

r? `@rust-lang/wg-const-eval`

To-do for me:
* [x] Assess the rustdoc impact of additional bounds in the method
* [x] ~~Increase test coverage~~ I think this is enough for an unstable feature.
@bors
Copy link
Collaborator

bors commented Dec 28, 2025

⌛ Testing commit 3cc8d08 with merge cdaf12b...

@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Collaborator

bors commented Dec 28, 2025

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Dec 28, 2025
@RalfJung
Copy link
Member

Cc @rust-lang/libs FYI

@rustbot

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@RalfJung
Copy link
Member

RalfJung commented Dec 29, 2025

Interesting, seems like that test needs to be made deterministic, and also there's some sort of bug in Miri causing an ICE here. Either way it's unrelated to the changes in this PR.

EDIT: rust-lang/miri#4796 should fix that

@RalfJung
Copy link
Member

If you rebase, the strange Miri failure should be gone.

@rustbot
Copy link
Collaborator

rustbot commented Dec 30, 2025

This PR was rebased onto a different main commit. Here's a range-diff highlighting what actually changed.

Rebasing is a normal part of keeping PRs up to date, so no action is needed—this note is just to help reviewers.

@rust-log-analyzer
Copy link
Collaborator

The job x86_64-gnu-miri failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
tests/fail-dep/libc/fs/unix_open_missing_required_mode.rs ... ok
tests/fail-dep/libc/fs/write_to_stdin.rs ... ok

FAILED TEST: tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs
command: MIRI_ENV_VAR_TEST="0" MIRI_TEMP="/tmp/miri-uitest-Xuqd3Y" RUST_BACKTRACE="1" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu/release/miri" "--error-format=json" "--sysroot=/checkout/obj/build/x86_64-unknown-linux-gnu/miri-sysroot" "-Dwarnings" "-Dunused" "-Ainternal_features" "-Zui-testing" "--out-dir" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu/tmp/miri_ui/0/tests/fail-dep/concurrency" "tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs" "--extern" "cfg_if=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libcfg_if-ad2cf6b565231a44.rlib" "--extern" "cfg_if=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libcfg_if-ad2cf6b565231a44.rmeta" "--extern" "getrandom_01=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-1f527dc5af1b71b3.rlib" "--extern" "getrandom_01=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-1f527dc5af1b71b3.rmeta" "--extern" "getrandom_02=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-7be25cd6ed6a0f03.rlib" "--extern" "getrandom_02=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-7be25cd6ed6a0f03.rmeta" "--extern" "getrandom_03=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-7b3c2e37d6654726.rlib" "--extern" "getrandom_03=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libgetrandom-7b3c2e37d6654726.rmeta" "--extern" "libc=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/liblibc-3a10e4992cf85e2b.rlib" "--extern" "libc=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/liblibc-3a10e4992cf85e2b.rmeta" "--extern" "num_cpus=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libnum_cpus-c6c07b57904abbdc.rlib" "--extern" "num_cpus=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libnum_cpus-c6c07b57904abbdc.rmeta" "--extern" "futures=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libfutures-1b76519c7143196f.rlib" "--extern" "futures=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libfutures-1b76519c7143196f.rmeta" "--extern" "page_size=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libpage_size-2d9255210c0c8300.rlib" "--extern" "page_size=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libpage_size-2d9255210c0c8300.rmeta" "--extern" "tempfile=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libtempfile-a1187bf1aab90aac.rlib" "--extern" "tempfile=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libtempfile-a1187bf1aab90aac.rmeta" "--extern" "tokio=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libtokio-4b3ab5e181d55056.rlib" "--extern" "tokio=/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps/libtokio-4b3ab5e181d55056.rmeta" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/debug/deps" "-L" "/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/aarch64-apple-darwin/debug/deps" "--edition" "2021" "--target" "aarch64-apple-darwin"

error: actual output differed from expected
Execute `./miri test --bless` to update `tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.stderr` to the actual output
--- tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.stderr
+++ <stderr output>
-error: Undefined Behavior: read of `os_unfair_lock` is forbidden while the queue is non-empty
+error: Undefined Behavior: Race condition detected between (1) 1-byte atomic store on thread `unnamed-ID` and (2) 4-byte atomic load on thread `unnamed-ID` at ALLOC
   --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:LL:CC
    |
 LL |             let _val = atomic_ref.load(Ordering::Relaxed);
-   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Undefined Behavior occurred here
+   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ (2) just happened here
    |
+help: and (1) occurred earlier here
+  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:LL:CC
+   |
+LL |             unsafe { libc::os_unfair_lock_lock(lock.get()) };
+   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
+   = help: overlapping unsynchronized atomic accesses must use the same access size
+   = help: see https://doc.rust-lang.org/nightly/std/sync/atomic/index.html#memory-model-for-atomic-accesses for more information about the Rust memory model
    = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
    = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
... 3 lines skipped ...
 error: aborting due to 1 previous error
 

Full unnormalized output:
error: Undefined Behavior: Race condition detected between (1) 1-byte atomic store on thread `unnamed-1` and (2) 4-byte atomic load on thread `unnamed-3` at alloc180
##[error]  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:26:24
   |
LL |             let _val = atomic_ref.load(Ordering::Relaxed);
   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ (2) just happened here
   |
help: and (1) occurred earlier here
  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:14:22
   |
LL |             unsafe { libc::os_unfair_lock_lock(lock.get()) };
   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: overlapping unsynchronized atomic accesses must use the same access size
   = help: see https://doc.rust-lang.org/nightly/std/sync/atomic/index.html#memory-model-for-atomic-accesses for more information about the Rust memory model
   = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
   = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information

note: some details are omitted, run with `MIRIFLAGS=-Zmiri-backtrace=full` for a verbose backtrace

error: aborting due to 1 previous error



error: `read of `os_unfair_lock` is forbidden while the queue is non-empty` not found in diagnostics on line 26
##[error]  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:26:70
   |
26 |             let _val = atomic_ref.load(Ordering::Relaxed); //~ERROR: read of `os_unfair_lock` is forbidden while the queue is non-empty
   |                                                                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected because of this pattern
   |

error: there was 1 unmatched diagnostic
##[error]  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:26:24
   |
26 |             let _val = atomic_ref.load(Ordering::Relaxed); //~ERROR: read of `os_unfair_lock` is forbidden while the queue is non-empty
   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ Error: Undefined Behavior: Race condition detected between (1) 1-byte atomic store on thread `unnamed-1` and (2) 4-byte atomic load on thread `unnamed-3` at alloc180
   |

full stderr:
error: Undefined Behavior: Race condition detected between (1) 1-byte atomic store on thread `unnamed-1` and (2) 4-byte atomic load on thread `unnamed-3` at alloc180
##[error]  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:26:24
   |
LL |             let _val = atomic_ref.load(Ordering::Relaxed);
   |                        ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ (2) just happened here
   |
help: and (1) occurred earlier here
  --> tests/fail-dep/concurrency/apple_os_unfair_lock_move_with_queue.rs:14:22
   |
LL |             unsafe { libc::os_unfair_lock_lock(lock.get()) };
   |                      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   = help: overlapping unsynchronized atomic accesses must use the same access size
   = help: see https://doc.rust-lang.org/nightly/std/sync/atomic/index.html#memory-model-for-atomic-accesses for more information about the Rust memory model
   = help: this indicates a bug in the program: it performed an invalid operation, and caused Undefined Behavior
   = help: see https://doc.rust-lang.org/nightly/reference/behavior-considered-undefined.html for further information
---
Location:
   /cargo/registry/src/index.crates.io-1949cf8c6b5b557f/ui_test-0.30.3/src/lib.rs:365

  ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ BACKTRACE ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
   1: <color_eyre[bccc80a860c3b331]::config::EyreHook>::into_eyre_hook::{closure#0}<unknown>
      at <unknown source file>:<unknown line>
   2: <eyre[1f5fe82b02d625ec]::Report>::from_adhoc::<&str><unknown>
      at <unknown source file>:<unknown line>
   3: ui_test[8dc37830080a69a4]::run_tests_generic::<ui_test[8dc37830080a69a4]::default_file_filter, ui[707f26238f1ec3ff]::run_tests::{closure#1}, alloc[fc43d269efba3461]::boxed::Box<dyn ui_test[8dc37830080a69a4]::status_emitter::StatusEmitter>><unknown>
      at <unknown source file>:<unknown line>
   4: ui[707f26238f1ec3ff]::ui<unknown>
      at <unknown source file>:<unknown line>
   5: ui[707f26238f1ec3ff]::main<unknown>
      at <unknown source file>:<unknown line>
   6: std[152826768b13abf3]::sys::backtrace::__rust_begin_short_backtrace::<fn() -> core[e7f16902ebb0f573]::result::Result<(), eyre[1f5fe82b02d625ec]::Report>, core[e7f16902ebb0f573]::result::Result<(), eyre[1f5fe82b02d625ec]::Report>><unknown>
      at <unknown source file>:<unknown line>
   7: std[152826768b13abf3]::rt::lang_start::<core[e7f16902ebb0f573]::result::Result<(), eyre[1f5fe82b02d625ec]::Report>>::{closure#0}<unknown>
      at <unknown source file>:<unknown line>
   8: std[152826768b13abf3]::rt::lang_start_internal<unknown>
      at <unknown source file>:<unknown line>
   9: main<unknown>
      at <unknown source file>:<unknown line>
  10: __libc_start_main<unknown>
      at <unknown source file>:<unknown line>
  11: _start<unknown>
      at <unknown source file>:<unknown line>

Run with COLORBT_SHOW_HIDDEN=1 environment variable to disable frame filtering.
Run with RUST_BACKTRACE=full to include source snippets.
error: test failed, to rerun pass `--test ui`

Caused by:
  process didn't exit successfully: `/checkout/obj/build/x86_64-unknown-linux-gnu/stage2-tools/x86_64-unknown-linux-gnu/release/deps/ui-aee5a65a90ee7bb1` (exit status: 1)
Command `/checkout/obj/build/x86_64-unknown-linux-gnu/stage0/bin/cargo test -Zwarnings --target x86_64-unknown-linux-gnu -Zbinary-dep-depinfo -j 4 -Zroot-dir=/checkout --locked --color=always --release --manifest-path /checkout/src/tools/miri/Cargo.toml -- [workdir=/checkout]` failed with exit code 1
Created at: src/bootstrap/src/core/build_steps/tool.rs:191:21
Executed at: src/bootstrap/src/core/build_steps/test.rs:732:19

Command has failed. Rerun with -v to see more details.
Bootstrap failed while executing `test --stage 2 src/tools/miri src/tools/miri/cargo-miri --target aarch64-apple-darwin`
Build completed unsuccessfully in 0:02:56
  local time: Tue Dec 30 22:22:25 UTC 2025
  network time: Tue, 30 Dec 2025 22:22:25 GMT
##[error]Process completed with exit code 1.

@fee1-dead
Copy link
Member Author

I don't understand what is going on with the miri differences, @RalfJung what should I change here? Bless the test? Or change something so that the test still retains the original message?

@bors
Copy link
Collaborator

bors commented Dec 30, 2025

☔ The latest upstream changes (presumably #147247) made this pull request unmergeable. Please resolve the merge conflicts.

@RalfJung
Copy link
Member

Ah dang, I fixed the ICE but forgot to fix the non-determinism...

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

perf-regression Performance regression. S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-libs Relevant to the library team, which will review and decide on the PR/issue.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants