Skip to content

Rollup of 7 pull requests #142962

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 18 commits into from
Jun 24, 2025
Merged

Rollup of 7 pull requests #142962

merged 18 commits into from
Jun 24, 2025

Conversation

GuillaumeGomez
Copy link
Member

@GuillaumeGomez GuillaumeGomez commented Jun 24, 2025

Successful merges:

Failed merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

bjoernager and others added 18 commits February 20, 2025 17:51
…ent 'PartialEq<{CStr, &CStr, Cow<CStr>}>' for 'CString'; Implement 'PartialEq<{CStr, &CStr, CString}>' for 'Cow<CStr>';
Taking inspiration from `-Zmacro-stats`:
- Use "{prefix}" consistently.
- Use names for column widths.
- Write output in a single `eprint!` call, in an attempt to minimize
  interleaving of output from different rustc processes.
- Use `repeat` for the long `---` banners.
Currently they have the largest items at the end. I believe the
rationale is that it saves you scrolling up through terminal output
because the important stuff is at the bottom. But it's also surprising
and a bit confusing, and I think the obvious order (big things at the
top) is better.
To make it match `-Zmacro-stats`, and work better if you have enabled it
for multiple crates.
- Print each crate's name.
- Print a `===` banner at the start and end for separation.
`concat_idents!` is in the process of being removed, but a few things it
is used to test will still be relevant. Migrate these tests to something
other than `concat_idents`.
These tests were updated in the previous commit; while they are being
cleaned up, move them to a non-issue directory.
In [137653], the lang and libs-API teams did a joint FCP to deprecate
and eventually remove the long-unstable `concat_idents!` macro. The
deprecation is landing in 1.88, so do the removal here (target version
1.90).

This macro has been superseded by the more recent `${concat(...)}`
metavariable expression language feature, which avoids some of the
limitations of `concat_idents!`. The metavar expression is unstably
available under the [`macro_metavar_expr_concat`] feature.

History is mildly interesting here: `concat_idents!` goes back to 2011
when it was introduced with 513276e ("Add #concat_idents[] and
about the same:

    let asdf_fdsa = "<.<";
    assert(#concat_idents[asd,f_f,dsa] == "<.<");

    assert(#ident_to_str[use_mention_distinction]
           == "use_mention_distinction");

(That test existed from introduction until its removal here.)

Closes: https://www.github.com/rust-lang/rust/issues/29599

[137653]: https://www.github.com/rust-lang/rust/pull/137653
[`macro_metavar_expr_concat`]: https://www.github.com/rust-lang/rust/issues/124225
…anieu

Allow comparisons between `CStr`, `CString`, and `Cow<CStr>`.

Closes: rust-lang#137265

This PR adds the trait implementations proposed in the [ACP](rust-lang/libs-team#517) under the `c_string_eq_c_str` feature gate:

```rust
// core::ffi

impl PartialEq<&Self> for CStr;

impl PartialEq<CString> for CStr;

impl PartialEq<Cow<'_, Self>> for CStr;

// alloc::ffi

impl PartialEq<CStr> for CString;

impl PartialEq<&CStr> for CString;

impl PartialEq<Cow<'_, CStr>> for CString;

// alloc::borrow

impl PartialEq<CStr> for Cow<'_, CStr>;

impl PartialEq<&CStr> for Cow<'_, CStr>;

impl PartialEq<CString> for Cow<'_, CStr>;
```

As I understand it, stable traits cannot be unstably implemented for stable types, and we would thereby be forced to skip the FCP and directly stabilise these implementations (as is done in this PR).

(`@joshtriplett` mentioned that Crater may have to be run).
…ee1-dead

Remove the deprecated unstable `concat_idents!` macro

In [rust-lang#137653], the lang and libs-API teams did a joint FCP to deprecate
and eventually remove the long-unstable `concat_idents!` macro. The
deprecation is landing in 1.88, so do the removal here (target version
1.90).

This macro has been superseded by the more recent `${concat(...)}`
metavariable expression language feature, which avoids some of the
limitations of `concat_idents!`. The metavar expression is unstably
available under the [`macro_metavar_expr_concat`] feature.

History is mildly interesting here: `concat_idents!` goes back to 2011
when it was introduced with 513276e ("Add #concat_idents[] and
#ident_to_str[]"). The syntax looks a bit different but it still works
about the same:

    let asdf_fdsa = "<.<";
    assert(#concat_idents[asd,f_f,dsa] == "<.<");

    assert(#ident_to_str[use_mention_distinction]
           == "use_mention_distinction");

(That test existed from introduction until its removal here.)

Closes: rust-lang#29599

[rust-lang#137653]: rust-lang#137653
[`macro_metavar_expr_concat`]: rust-lang#124225
[win][aarch64] Fix linking statics on Arm64EC, take 2

Arm64EC builds recently started to fail due to the linker not finding a symbol:
```
symbols.o : error LNK2001: unresolved external symbol #_ZN3std9panicking11EMPTY_PANIC17hc8d2b903527827f1E (EC Symbol)
          C:\Code\hello-world\target\arm64ec-pc-windows-msvc\debug\deps\hello_world.exe : fatal error LNK1120: 1 unresolved externals
```

It turns out that `EMPTY_PANIC` is a new static variable that was being exported then imported from the standard library, but when exporting LLVM didn't prepend the name with `#` (as only functions are prefixed with this character), whereas Rust was prefixing with `#` when attempting to import it.

The fix is to have Rust not prefix statics with `#` when importing.

Adding tests discovered another issue: we need to correctly mark static exported from dylibs with `DATA`, otherwise MSVC's linker assumes they are functions and complains that there is no exit thunk for them.

Fixes rust-lang#138541

Resurrects rust-lang#140176 now that rust-lang#141061 is merged, which removes the incompatibility with `__rust_no_alloc_shim_is_unstable`.

r? ``@wesleywiser``

CC ``@bjorn3``
…=jieyouxu

Enable reproducible-build-2 for Windows MSVC

Works with MSVC if instructing the linker to avoid timestamps and deleting the PDB between compilations.

Addresses item in rust-lang#128602

---

try-job: x86_64-mingw-*
try-job: x86_64-msvc-*
try-job: i686-msvc-*
…ptimizer, r=GuillaumeGomez

rustdoc-json: Add test for `#[optimize(..)]`

Follow up to rust-lang#138291

CC `@jdonszelmann`

r? `@GuillaumeGomez`
…ou, r=GuillaumeGomez

rustdoc-json: Add test for `#[cold]`

Follow-up to rust-lang#142491

r? `@GuillaumeGomez`

CC `@jdonszelmann`
Stats output tweaks

Some improvements to `-Zinput-stats` and `-Zmeta-stat` inspired by the new `-Zmacro-stats`.

r? `@lqd`
@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-rustdoc-json Area: Rustdoc JSON backend A-rustdoc-search Area: Rustdoc's search feature A-tidy Area: The tidy tool S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output. rollup A PR which is a rollup labels Jun 24, 2025
@GuillaumeGomez
Copy link
Member Author

@bors r+ p=5 rollup=never

@bors
Copy link
Collaborator

bors commented Jun 24, 2025

📌 Commit e8dd3c3 has been approved by GuillaumeGomez

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 Jun 24, 2025
@bors
Copy link
Collaborator

bors commented Jun 24, 2025

⌛ Testing commit e8dd3c3 with merge 3129d37...

@bors
Copy link
Collaborator

bors commented Jun 24, 2025

☀️ Test successful - checks-actions
Approved by: GuillaumeGomez
Pushing 3129d37 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jun 24, 2025
@bors bors merged commit 3129d37 into rust-lang:master Jun 24, 2025
11 checks passed
@rustbot rustbot added this to the 1.90.0 milestone Jun 24, 2025
@rust-timer
Copy link
Collaborator

📌 Perf builds for each rolled up PR:

PR# Message Perf Build Sha
#137268 Allow comparisons between CStr, CString, and `Cow… 298cfb242742a0ff243846a8c575641d21c95155 (link)
#142704 Remove the deprecated unstable concat_idents! macro 09c710b70b970963e54d9631d9115fd0cb0387ec (link)
#142742 [win][aarch64] Fix linking statics on Arm64EC, take 2 1765b1f00b201dd22fb01221f86ea54f74b651e2 (link)
#142843 Enable reproducible-build-2 for Windows MSVC 8c9c43006a25c2d68e099dd11dffa091386566f9 (link)
#142916 rustdoc-json: Add test for #[optimize(..)] 03725e4679f93ebd0526efc1b7e738c35bd1458b (link)
#142919 rustdoc-json: Add test for #[cold] 96fa09daf2140c4d2a1aed2571fe9a637c9efd73 (link)
#142944 Stats output tweaks ece3c1348ec0384ee068a65c7196c6155d2e482d (link)

previous master: 36b21637e9

In the case of a perf regression, run the following command for each PR you suspect might be the cause: @rust-timer build $SHA

Copy link
Contributor

What is this? This is an experimental post-merge analysis report that shows differences in test outcomes between the merged PR and its parent PR.

Comparing 36b2163 (parent) -> 3129d37 (this PR)

Test differences

Show 155 test diffs

Stage 1

  • errors::verify_builtin_macros_asm_attribute_not_supported_64: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_attribute_not_supported_67: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_duplicate_arg_65: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_explicit_register_name_59: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_explicit_register_name_62: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_mayunwind_72: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_modifier_invalid_63: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_modifier_invalid_66: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_mutually_exclusive_60: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_mutually_exclusive_63: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_no_matched_argument_name_68: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_no_matched_argument_name_71: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_noreturn_67: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_noreturn_70: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_opt_already_provided_70: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_pos_after_66: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_pos_after_69: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_pure_combine_61: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_pure_combine_64: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_pure_no_output_62: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_pure_no_output_65: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_unsupported_clobber_abi_72: [missing] -> pass (J0)
  • errors::verify_builtin_macros_asm_unsupported_clobber_abi_75: pass -> [missing] (J0)
  • errors::verify_builtin_macros_asm_unsupported_option_74: pass -> [missing] (J0)
  • errors::verify_builtin_macros_bad_derive_target_42: pass -> [missing] (J0)
  • errors::verify_builtin_macros_cannot_derive_union_47: [missing] -> pass (J0)
  • errors::verify_builtin_macros_cannot_derive_union_50: pass -> [missing] (J0)
  • errors::verify_builtin_macros_concat_idents_ident_args_41: pass -> [missing] (J0)
  • errors::verify_builtin_macros_concat_idents_missing_args_39: pass -> [missing] (J0)
  • errors::verify_builtin_macros_concat_idents_missing_comma_40: pass -> [missing] (J0)
  • errors::verify_builtin_macros_default_arg_48: pass -> [missing] (J0)
  • errors::verify_builtin_macros_derive_macro_call_49: pass -> [missing] (J0)
  • errors::verify_builtin_macros_derive_path_args_list_41: [missing] -> pass (J0)
  • errors::verify_builtin_macros_derive_path_args_list_44: pass -> [missing] (J0)
  • errors::verify_builtin_macros_derive_path_args_value_42: [missing] -> pass (J0)
  • errors::verify_builtin_macros_derive_path_args_value_45: pass -> [missing] (J0)
  • errors::verify_builtin_macros_env_not_defined_49: [missing] -> pass (J0)
  • errors::verify_builtin_macros_env_not_defined_50: [missing] -> pass (J0)
  • errors::verify_builtin_macros_env_not_defined_52: pass -> [missing] (J0)
  • errors::verify_builtin_macros_env_not_unicode_51: [missing] -> pass (J0)
  • errors::verify_builtin_macros_env_not_unicode_54: pass -> [missing] (J0)
  • errors::verify_builtin_macros_env_takes_args_48: [missing] -> pass (J0)
  • errors::verify_builtin_macros_env_takes_args_51: pass -> [missing] (J0)
  • errors::verify_builtin_macros_expected_comma_in_list_78: pass -> [missing] (J0)
  • errors::verify_builtin_macros_expected_other_83: [missing] -> pass (J0)
  • errors::verify_builtin_macros_expected_other_86: pass -> [missing] (J0)
  • errors::verify_builtin_macros_format_duplicate_arg_53: [missing] -> pass (J0)
  • errors::verify_builtin_macros_format_duplicate_arg_56: pass -> [missing] (J0)
  • errors::verify_builtin_macros_format_no_arg_named_55: [missing] -> pass (J0)
  • errors::verify_builtin_macros_format_no_arg_named_58: pass -> [missing] (J0)
  • errors::verify_builtin_macros_format_positional_after_named_54: [missing] -> pass (J0)
  • errors::verify_builtin_macros_format_positional_after_named_57: pass -> [missing] (J0)
  • errors::verify_builtin_macros_format_requires_string_52: [missing] -> pass (J0)
  • errors::verify_builtin_macros_format_requires_string_55: pass -> [missing] (J0)
  • errors::verify_builtin_macros_format_unused_arg_56: [missing] -> pass (J0)
  • errors::verify_builtin_macros_format_unused_arg_59: pass -> [missing] (J0)
  • errors::verify_builtin_macros_naked_functions_testing_attribute_81: [missing] -> pass (J0)
  • errors::verify_builtin_macros_naked_functions_testing_attribute_84: pass -> [missing] (J0)
  • errors::verify_builtin_macros_non_exhaustive_default_44: [missing] -> pass (J0)
  • errors::verify_builtin_macros_non_exhaustive_default_47: pass -> [missing] (J0)
  • errors::verify_builtin_macros_non_generic_pointee_82: [missing] -> pass (J0)
  • errors::verify_builtin_macros_non_generic_pointee_85: pass -> [missing] (J0)
  • errors::verify_builtin_macros_non_unit_default_43: [missing] -> pass (J0)
  • errors::verify_builtin_macros_non_unit_default_46: pass -> [missing] (J0)
  • errors::verify_builtin_macros_only_one_argument_76: [missing] -> pass (J0)
  • errors::verify_builtin_macros_only_one_argument_79: pass -> [missing] (J0)
  • errors::verify_builtin_macros_proc_macro_attribute_only_be_used_on_bare_functions_81: pass -> [missing] (J0)
  • errors::verify_builtin_macros_proc_macro_attribute_only_usable_with_crate_type_79: [missing] -> pass (J0)
  • errors::verify_builtin_macros_proc_macro_attribute_only_usable_with_crate_type_82: pass -> [missing] (J0)
  • errors::verify_builtin_macros_source_uitls_expected_item_80: [missing] -> pass (J0)
  • errors::verify_builtin_macros_source_uitls_expected_item_83: pass -> [missing] (J0)
  • errors::verify_builtin_macros_takes_no_arguments_77: [missing] -> pass (J0)
  • errors::verify_builtin_macros_takes_no_arguments_80: pass -> [missing] (J0)
  • errors::verify_builtin_macros_test_bad_fn_58: [missing] -> pass (J0)
  • errors::verify_builtin_macros_test_bad_fn_61: pass -> [missing] (J0)
  • errors::verify_builtin_macros_test_case_non_item_57: [missing] -> pass (J0)
  • errors::verify_builtin_macros_test_case_non_item_60: pass -> [missing] (J0)
  • errors::verify_builtin_macros_test_runner_invalid_73: [missing] -> pass (J0)
  • errors::verify_builtin_macros_test_runner_invalid_76: pass -> [missing] (J0)
  • errors::verify_builtin_macros_test_runner_nargs_77: pass -> [missing] (J0)
  • errors::verify_builtin_macros_tests_not_support_40: [missing] -> pass (J0)
  • errors::verify_builtin_macros_tests_not_support_43: pass -> [missing] (J0)
  • [rustdoc-json] tests/rustdoc-json/attrs/cold.rs: [missing] -> pass (J4)
  • [rustdoc-json] tests/rustdoc-json/attrs/optimize.rs: [missing] -> pass (J4)
  • [ui] tests/ui/derives/nonsense-input-to-debug.rs: [missing] -> pass (J4)
  • [ui] tests/ui/feature-gates/feature-gate-concat_idents3.rs: pass -> [missing] (J4)
  • [ui] tests/ui/issues/issue-50403.rs: pass -> [missing] (J4)
  • [ui] tests/ui/macros/macro-metavar-expr-concat/empty-input.rs: [missing] -> pass (J4)
  • [ui] tests/ui/syntax-extension-minor.rs: pass -> [missing] (J4)

Stage 2

  • [run-make] tests/run-make/arm64ec-import-export-static: [missing] -> ignore (only executed when the operating system is windows) (J1)
  • [run-make] tests/run-make/reproducible-build-2: ignore (ignored when the operating system is windows) -> ignore (ignored when the operating system and target environment are windows-gnu) (J2)
  • [ui] tests/ui/derives/nonsense-input-to-debug.rs: [missing] -> pass (J3)
  • [ui] tests/ui/feature-gates/feature-gate-concat_idents2.rs: pass -> [missing] (J3)
  • [ui] tests/ui/issues/issue-32950.rs: pass -> [missing] (J3)
  • [ui] tests/ui/macros/macro-metavar-expr-concat/empty-input.rs: [missing] -> pass (J3)
  • [ui] tests/ui/syntax-extension-minor.rs: pass -> [missing] (J3)
  • [run-make] tests/run-make/arm64ec-import-export-static: [missing] -> pass (J5)
  • [run-make] tests/run-make/reproducible-build-2: ignore (ignored when the operating system is windows) -> pass (J6)
  • [rustdoc-json] tests/rustdoc-json/attrs/cold.rs: [missing] -> pass (J7)
  • [rustdoc-json] tests/rustdoc-json/attrs/optimize.rs: [missing] -> pass (J7)

(and 18 additional test diffs)

Additionally, 37 doctest diffs were found. These are ignored, as they are noisy.

Job group index

Test dashboard

Run

cargo run --manifest-path src/ci/citool/Cargo.toml -- \
    test-dashboard 3129d37ef7075ee3cbaa3d6cbe1b5794f67192b0 --output-dir test-dashboard

And then open test-dashboard/index.html in your browser to see an overview of all executed tests.

Job duration changes

  1. dist-x86_64-apple: 7612.0s -> 10732.3s (41.0%)
  2. dist-apple-various: 9249.0s -> 5774.5s (-37.6%)
  3. dist-aarch64-apple: 9039.5s -> 6004.3s (-33.6%)
  4. mingw-check-1: 1584.2s -> 1815.0s (14.6%)
  5. aarch64-gnu-debug: 3797.8s -> 4285.5s (12.8%)
  6. dist-s390x-linux: 5149.3s -> 4678.9s (-9.1%)
  7. dist-aarch64-windows-gnullvm: 4842.6s -> 4424.2s (-8.6%)
  8. i686-msvc-1: 8531.7s -> 9266.1s (8.6%)
  9. dist-ohos-aarch64: 4525.8s -> 4146.9s (-8.4%)
  10. x86_64-mingw-1: 8703.2s -> 9383.9s (7.8%)
How to interpret the job duration changes?

Job durations can vary a lot, based on the actual runner instance
that executed the job, system noise, invalidated caches, etc. The table above is provided
mostly for t-infra members, for simpler debugging of potential CI slow-downs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-run-make Area: port run-make Makefiles to rmake.rs A-rustdoc-json Area: Rustdoc JSON backend A-rustdoc-search Area: Rustdoc's search feature A-tidy Area: The tidy tool merged-by-bors This PR was explicitly merged by bors. rollup A PR which is a rollup S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) 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. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. T-rustdoc-frontend Relevant to the rustdoc-frontend team, which will review and decide on the web UI/UX output.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants