rust icon indicating copy to clipboard operation
rust copied to clipboard

derive(PartialEq) via bitwise comparison where possible

Open saethlin opened this issue 3 weeks ago • 27 comments

saethlin avatar Nov 24 '25 01:11 saethlin

The job tidy failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)

rust-log-analyzer avatar Nov 24 '25 01:11 rust-log-analyzer

The job aarch64-gnu-llvm-20-2 failed! Check out the build log: (web) (plain enhanced) (plain)

Click to see the possible cause of the failure (guessed by this bot)
---- parser::tests::string_to_tts_1 stdout ----

thread 'parser::tests::string_to_tts_1' (53827) panicked at compiler/rustc_parse/src/parser/tests.rs:2377:9:
assertion `left == right` failed
  left: TokenStream([Token(Token { kind: Ident("fn", No), span: Span { lo: BytePos(0), hi: BytePos(2), ctxt: #0 } }, Alone), Token(Token { kind: Ident("a", No), span: Span { lo: BytePos(3), hi: BytePos(4), ctxt: #0 } }, JointHidden), Delimited(DelimSpan { open: Span { lo: BytePos(4), hi: BytePos(5), ctxt: #0 }, close: Span { lo: BytePos(11), hi: BytePos(12), ctxt: #0 } }, DelimSpacing { open: JointHidden, close: Alone }, Parenthesis, TokenStream([Token(Token { kind: Ident("b", No), span: Span { lo: BytePos(5), hi: BytePos(6), ctxt: #0 } }, Joint), Token(Token { kind: Colon, span: Span { lo: BytePos(6), hi: BytePos(7), ctxt: #0 } }, Alone), Token(Token { kind: Ident("i32", No), span: Span { lo: BytePos(8), hi: BytePos(11), ctxt: #0 } }, JointHidden)])), Delimited(DelimSpan { open: Span { lo: BytePos(13), hi: BytePos(14), ctxt: #0 }, close: Span { lo: BytePos(18), hi: BytePos(19), ctxt: #0 } }, DelimSpacing { open: Alone, close: Alone }, Brace, TokenStream([Token(Token { kind: Ident("b", No), span: Span { lo: BytePos(15), hi: BytePos(16), ctxt: #0 } }, Joint), Token(Token { kind: Semi, span: Span { lo: BytePos(16), hi: BytePos(17), ctxt: #0 } }, Alone)]))])
 right: TokenStream([Token(Token { kind: Ident("fn", No), span: Span { lo: BytePos(0), hi: BytePos(2), ctxt: #0 } }, Alone), Token(Token { kind: Ident("a", No), span: Span { lo: BytePos(3), hi: BytePos(4), ctxt: #0 } }, JointHidden), Delimited(DelimSpan { open: Span { lo: BytePos(4), hi: BytePos(5), ctxt: #0 }, close: Span { lo: BytePos(11), hi: BytePos(12), ctxt: #0 } }, DelimSpacing { open: JointHidden, close: Alone }, Parenthesis, TokenStream([Token(Token { kind: Ident("b", No), span: Span { lo: BytePos(5), hi: BytePos(6), ctxt: #0 } }, Joint), Token(Token { kind: Colon, span: Span { lo: BytePos(6), hi: BytePos(7), ctxt: #0 } }, Alone), Token(Token { kind: Ident("i32", No), span: Span { lo: BytePos(8), hi: BytePos(11), ctxt: #0 } }, JointHidden)])), Delimited(DelimSpan { open: Span { lo: BytePos(13), hi: BytePos(14), ctxt: #0 }, close: Span { lo: BytePos(18), hi: BytePos(19), ctxt: #0 } }, DelimSpacing { open: Alone, close: Alone }, Brace, TokenStream([Token(Token { kind: Ident("b", No), span: Span { lo: BytePos(15), hi: BytePos(16), ctxt: #0 } }, Joint), Token(Token { kind: Semi, span: Span { lo: BytePos(16), hi: BytePos(17), ctxt: #0 } }, Alone)]))])
stack backtrace:
   0: __rustc::rust_begin_unwind
   1: core::panicking::panic_fmt
   2: core::panicking::assert_failed_inner
   3: core::panicking::assert_failed::<rustc_ast::tokenstream::TokenStream, rustc_ast::tokenstream::TokenStream>
   4: <scoped_tls::ScopedKey<rustc_span::SessionGlobals>>::set::<rustc_parse::parser::tests::string_to_tts_1::{closure#0}, ()>
   5: rustc_span::create_session_globals_then::<(), rustc_parse::parser::tests::string_to_tts_1::{closure#0}>
   6: <rustc_parse::parser::tests::string_to_tts_1::{closure#0} as core::ops::function::FnOnce<()>>::call_once
note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace.
---- parser::tests::string_to_tts_1 stdout end ----

failures:
    parser::tests::string_to_tts_1

test result: FAILED. 250 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 26.12ms

rust-log-analyzer avatar Nov 24 '25 02:11 rust-log-analyzer

That's not right.

saethlin avatar Nov 24 '25 03:11 saethlin

@bors try @rust-timer queue

saethlin avatar Nov 24 '25 13:11 saethlin

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

rust-timer avatar Nov 24 '25 13:11 rust-timer

:hourglass: Trying commit 507666c7663e83fdb6f2fd90c4bdde914a61a0a0 with merge 4ca5d8859eb246cbe04c84e29d4429f61cd2165e…

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/19635971252

rust-bors[bot] avatar Nov 24 '25 13:11 rust-bors[bot]

:sunny: Try build successful (CI) Build commit: 4ca5d8859eb246cbe04c84e29d4429f61cd2165e (4ca5d8859eb246cbe04c84e29d4429f61cd2165e, parent: 42ec52babac2cbf2bb2b9d794f980cbcb3ebe413)

rust-bors[bot] avatar Nov 24 '25 15:11 rust-bors[bot]

Queued 4ca5d8859eb246cbe04c84e29d4429f61cd2165e with parent 42ec52babac2cbf2bb2b9d794f980cbcb3ebe413, future comparison URL. There are currently 0 preceding artifacts in the queue. It will probably take at least ~1.3 hours until the benchmark run finishes.

rust-timer avatar Nov 24 '25 15:11 rust-timer

Finished benchmarking commit (4ca5d8859eb246cbe04c84e29d4429f61cd2165e): 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.2% [0.2%, 0.2%] 3
Regressions ❌
(secondary)
1.1% [0.3%, 1.4%] 10
Improvements ✅
(primary)
-0.3% [-0.5%, -0.1%] 16
Improvements ✅
(secondary)
-0.4% [-1.3%, -0.1%] 6
All ❌✅ (primary) -0.3% [-0.5%, 0.2%] 19

Max RSS (memory usage)

Results (primary 2.1%)

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

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

Cycles

Results (secondary -0.4%)

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

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

Binary size

Results (primary 0.0%, secondary 0.1%)

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

mean range count
Regressions ❌
(primary)
0.0% [0.0%, 0.0%] 1
Regressions ❌
(secondary)
0.1% [0.0%, 0.2%] 7
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.0% [0.0%, 0.0%] 1

Bootstrap: 471.257s -> 470.709s (-0.12%) Artifact size: 388.26 MiB -> 388.27 MiB (0.00%)

rust-timer avatar Nov 24 '25 17:11 rust-timer

@bors try @rust-timer queue

saethlin avatar Nov 30 '25 21:11 saethlin

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

rust-timer avatar Nov 30 '25 21:11 rust-timer

:hourglass: Trying commit 6c5a7213c4ae3721999b1eace420fc7bd3b4a7a6 with merge e44f742bf18fd0d12074d5616b865b3b06408b46…

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/19804774027

rust-bors[bot] avatar Nov 30 '25 21:11 rust-bors[bot]

:sunny: Try build successful (CI) Build commit: e44f742bf18fd0d12074d5616b865b3b06408b46 (e44f742bf18fd0d12074d5616b865b3b06408b46, parent: f40a70d2bcd830a4f1f8c7ca1a7f93f1d9d703d6)

rust-bors[bot] avatar Nov 30 '25 23:11 rust-bors[bot]

Queued e44f742bf18fd0d12074d5616b865b3b06408b46 with parent f40a70d2bcd830a4f1f8c7ca1a7f93f1d9d703d6, future comparison URL. There are currently 0 preceding artifacts in the queue. It will probably take at least ~1.3 hours until the benchmark run finishes.

rust-timer avatar Nov 30 '25 23:11 rust-timer

Finished benchmarking commit (e44f742bf18fd0d12074d5616b865b3b06408b46): 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.2% [0.1%, 0.2%] 3
Regressions ❌
(secondary)
1.0% [0.2%, 1.3%] 11
Improvements ✅
(primary)
-0.3% [-0.6%, -0.1%] 21
Improvements ✅
(secondary)
-0.2% [-1.2%, -0.1%] 40
All ❌✅ (primary) -0.3% [-0.6%, 0.2%] 24

Max RSS (memory usage)

Results (secondary 1.4%)

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

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

Cycles

Results (primary -2.4%)

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

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

Binary size

Results (secondary 0.1%)

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

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
0.1% [0.1%, 0.2%] 6
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Bootstrap: 469.915s -> 474.851s (1.05%) Artifact size: 386.98 MiB -> 386.96 MiB (-0.00%)

rust-timer avatar Dec 01 '25 00:12 rust-timer

@bors try @rust-timer queue

saethlin avatar Dec 06 '25 15:12 saethlin

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

rust-timer avatar Dec 06 '25 15:12 rust-timer

:hourglass: Trying commit f2018e82ebdf002bb46f0d97fdcb3655c5a94d31 with merge b5d90197198f0cf8d1d63e6c89d591cdc0fee505…

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/19990524477

rust-bors[bot] avatar Dec 06 '25 15:12 rust-bors[bot]

:sunny: Try build successful (CI) Build commit: b5d90197198f0cf8d1d63e6c89d591cdc0fee505 (b5d90197198f0cf8d1d63e6c89d591cdc0fee505, parent: da2544bfbe84df7b24d83c029c74299ebf6112c6)

rust-bors[bot] avatar Dec 06 '25 17:12 rust-bors[bot]

Queued b5d90197198f0cf8d1d63e6c89d591cdc0fee505 with parent da2544bfbe84df7b24d83c029c74299ebf6112c6, future comparison URL. There are currently 0 preceding artifacts in the queue. It will probably take at least ~1.3 hours until the benchmark run finishes.

rust-timer avatar Dec 06 '25 17:12 rust-timer

Finished benchmarking commit (b5d90197198f0cf8d1d63e6c89d591cdc0fee505): 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.2% [0.1%, 0.2%] 3
Regressions ❌
(secondary)
1.1% [0.3%, 1.4%] 10
Improvements ✅
(primary)
-0.3% [-0.6%, -0.1%] 25
Improvements ✅
(secondary)
-0.3% [-1.2%, -0.0%] 32
All ❌✅ (primary) -0.2% [-0.6%, 0.2%] 28

Max RSS (memory usage)

Results (primary 6.8%)

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

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

Cycles

Results (secondary 3.4%)

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

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
3.4% [2.4%, 5.1%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) - - 0

Binary size

Results (primary -0.2%, secondary 0.1%)

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

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

Bootstrap: 471.557s -> 469.215s (-0.50%) Artifact size: 388.95 MiB -> 388.87 MiB (-0.02%)

rust-timer avatar Dec 06 '25 19:12 rust-timer

@bors try @rust-timer queue

saethlin avatar Dec 07 '25 00:12 saethlin

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

rust-timer avatar Dec 07 '25 00:12 rust-timer

:hourglass: Trying commit f67692a3069323baef14e140eb0701e0bd2311e8 with merge 3c3569a7a0d01d4956cb13b0c8985f54c24ab633…

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/19996141073

rust-bors[bot] avatar Dec 07 '25 00:12 rust-bors[bot]

:sunny: Try build successful (CI) Build commit: 3c3569a7a0d01d4956cb13b0c8985f54c24ab633 (3c3569a7a0d01d4956cb13b0c8985f54c24ab633, parent: ba86c0460b0233319e01fd789a42a7276eade805)

rust-bors[bot] avatar Dec 07 '25 02:12 rust-bors[bot]

Queued 3c3569a7a0d01d4956cb13b0c8985f54c24ab633 with parent ba86c0460b0233319e01fd789a42a7276eade805, future comparison URL. There is currently 1 preceding artifact in the queue. It will probably take at least ~2.0 hours until the benchmark run finishes.

rust-timer avatar Dec 07 '25 02:12 rust-timer

Finished benchmarking commit (3c3569a7a0d01d4956cb13b0c8985f54c24ab633): 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.4%] 3
Regressions ❌
(secondary)
1.4% [0.2%, 2.9%] 16
Improvements ✅
(primary)
-0.3% [-0.6%, -0.1%] 18
Improvements ✅
(secondary)
-0.3% [-1.2%, -0.1%] 27
All ❌✅ (primary) -0.2% [-0.6%, 0.4%] 21

Max RSS (memory usage)

Results (primary 1.6%, secondary 2.3%)

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

mean range count
Regressions ❌
(primary)
3.8% [3.8%, 3.8%] 1
Regressions ❌
(secondary)
2.3% [1.6%, 3.6%] 4
Improvements ✅
(primary)
-0.6% [-0.6%, -0.6%] 1
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 1.6% [-0.6%, 3.8%] 2

Cycles

Results (secondary 1.6%)

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

mean range count
Regressions ❌
(primary)
- - 0
Regressions ❌
(secondary)
5.8% [3.8%, 8.1%] 3
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
-2.7% [-3.2%, -2.3%] 3
All ❌✅ (primary) - - 0

Binary size

Results (primary 0.2%, secondary 0.1%)

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

mean range count
Regressions ❌
(primary)
0.2% [0.0%, 0.5%] 3
Regressions ❌
(secondary)
0.1% [0.0%, 0.3%] 7
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 0.2% [0.0%, 0.5%] 3

Bootstrap: 470.7s -> 471.689s (0.21%) Artifact size: 388.87 MiB -> 388.87 MiB (-0.00%)

rust-timer avatar Dec 07 '25 04:12 rust-timer

@bors try @rust-timer queue

saethlin avatar Dec 07 '25 23:12 saethlin

Awaiting bors try build completion.

@rustbot label: +S-waiting-on-perf

rust-timer avatar Dec 07 '25 23:12 rust-timer

:hourglass: Trying commit 377131ea4f5b2d6ec88b2d65e738fcceb11431ee with merge 9dfaa96c7c0cfbd82e36663fa4b5796df7628d89…

To cancel the try build, run the command @bors try cancel.

Workflow: https://github.com/rust-lang/rust/actions/runs/20012223331

rust-bors[bot] avatar Dec 07 '25 23:12 rust-bors[bot]