Skip to content

Migrate symbol-visibility run-make test to rmake#127060

Merged
bors merged 3 commits into
rust-lang:masterfrom
Oneirical:testificate
Aug 1, 2024
Merged

Migrate symbol-visibility run-make test to rmake#127060
bors merged 3 commits into
rust-lang:masterfrom
Oneirical:testificate

Conversation

@Oneirical

@Oneirical Oneirical commented Jun 27, 2024

Copy link
Copy Markdown
Contributor

Part of #121876 and the associated Google Summer of Code project.

Pretty scary!

  • The expected number of symbols on each check has been changed slightly to reflect the differences between llvm_readobj and nm, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols.
  • The original test ran the same exact checks on cdylib twice, for seemingly no reason. I have removed it.
  • This may be possible to optimize some more? llvm_readobj could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a run-make test.

Demands a Windows try-job.

try-job: x86_64-mingw

@rustbot

rustbot commented Jun 27, 2024

Copy link
Copy Markdown
Collaborator

r? @jieyouxu

rustbot has assigned @jieyouxu.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added A-run-make Area: port run-make Makefiles to rmake.rs A-testsuite Area: The testsuite used to check the correctness of rustc 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) labels Jun 27, 2024
@rustbot

rustbot commented Jun 27, 2024

Copy link
Copy Markdown
Collaborator

This PR modifies tests/run-make/. If this PR is trying to port a Makefile
run-make test to use rmake.rs, please update the
run-make port tracking issue
so we can track our progress. You can either modify the tracking issue
directly, or you can comment on the tracking issue and link this PR.

cc @jieyouxu

@Kobzol

Kobzol commented Jun 27, 2024

Copy link
Copy Markdown
Member

@bors try

bors added a commit to rust-lang-ci/rust that referenced this pull request Jun 27, 2024
Migrate `symbol-visibility` `run-make` test to rmake

Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Pretty scary!

- The expected number of symbols on each check has been changed slightly to reflect the differences between `llvm_readobj` and `nm`, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols.
- The original test ran the same exact checks on `cdylib` twice, for seemingly no reason. I have removed it.
- This may be possible to optimize some more? `llvm_readobj` could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a `run-make` test.

Demands a Windows try-job.

try-job: x86_64-msvc
@bors

bors commented Jun 27, 2024

Copy link
Copy Markdown
Collaborator

⌛ Trying commit e825910 with merge 7cd66cf...

@rust-log-analyzer

This comment has been minimized.

@bors

bors commented Jun 27, 2024

Copy link
Copy Markdown
Collaborator

💔 Test failed - checks-actions

@bors bors 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 Jun 27, 2024
@Oneirical

Copy link
Copy Markdown
Contributor Author

What was even the point of those .a extensions in the original test... I'd like a second try job: @rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jun 28, 2024
@Kobzol

Kobzol commented Jun 28, 2024

Copy link
Copy Markdown
Member

@bors try

@bors

bors commented Jun 28, 2024

Copy link
Copy Markdown
Collaborator

⌛ Trying commit d2ec57d with merge 49774b5...

bors added a commit to rust-lang-ci/rust that referenced this pull request Jun 28, 2024
Migrate `symbol-visibility` `run-make` test to rmake

Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Pretty scary!

- The expected number of symbols on each check has been changed slightly to reflect the differences between `llvm_readobj` and `nm`, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols.
- The original test ran the same exact checks on `cdylib` twice, for seemingly no reason. I have removed it.
- This may be possible to optimize some more? `llvm_readobj` could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a `run-make` test.

Demands a Windows try-job.

try-job: x86_64-msvc
@rust-log-analyzer

This comment has been minimized.

@bors

bors commented Jun 28, 2024

Copy link
Copy Markdown
Collaborator

💔 Test failed - checks-actions

@bors bors 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 Jun 28, 2024
@Oneirical

Oneirical commented Jun 28, 2024

Copy link
Copy Markdown
Contributor Author

What was even the point of those .a extensions in the original test...

Okay, I get it, now. This test is beyond broken on MSVC, so the ignore should be restored, but it might work on Windows-gnu.

Please run try on mingw next, I already changed the description.

@lqd

lqd commented Jun 28, 2024

Copy link
Copy Markdown
Member

@bors try

@bors

bors commented Jun 28, 2024

Copy link
Copy Markdown
Collaborator

⌛ Trying commit b75711a with merge 90c22c3...

@Oneirical

Oneirical commented Jul 30, 2024

Copy link
Copy Markdown
Contributor Author

@bors try

I am using llvm_nm now. I do notice the similarity with the test being ported in #128314, so when @lolbinarycat's custom pure Rust symbol reader is stable, it could be an interesting alternative for this series of "find this symbol in the object file" type of tests.

bors added a commit to rust-lang-ci/rust that referenced this pull request Jul 30, 2024
Migrate `symbol-visibility` `run-make` test to rmake

Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Pretty scary!

- The expected number of symbols on each check has been changed slightly to reflect the differences between `llvm_readobj` and `nm`, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols.
- The original test ran the same exact checks on `cdylib` twice, for seemingly no reason. I have removed it.
- This may be possible to optimize some more? `llvm_readobj` could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a `run-make` test.

Demands a Windows try-job.

try-job: x86_64-mingw
@bors

bors commented Jul 30, 2024

Copy link
Copy Markdown
Collaborator

⌛ Trying commit 83b80a6 with merge 8cc0310...

@bors

bors commented Jul 30, 2024

Copy link
Copy Markdown
Collaborator

☀️ Try build successful - checks-actions
Build commit: 8cc0310 (8cc0310a769f2764a20a3ed5dbfa0e569d9155bf)

@Oneirical

Copy link
Copy Markdown
Contributor Author

@rustbot review

@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jul 30, 2024

@jieyouxu jieyouxu left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks, this looks good to me, just a tiny nit about the #[no_mangle] attribute in comments becoming //[no_mangle]. r=me after that!


// Check the combined case, where we generate a cdylib and an rlib in the same
// compilation session:
// Check that a cdylib exports its public //[no_mangle] functions

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Nit: #[no_mangle], looks like search and replace mistake. Same with other instances of //[no_mangle]

@jieyouxu

Copy link
Copy Markdown
Member

r=me with the //[no_mangle] in comments fixed
@bors delegate+

@bors

bors commented Jul 30, 2024

Copy link
Copy Markdown
Collaborator

✌️ @Oneirical, you can now approve this pull request!

If @jieyouxu told you to "r=me" after making some further change, please make that change, then do @bors r=@jieyouxu

@jieyouxu

Copy link
Copy Markdown
Member

@bors rollup=iffy (highly platform specific symbol checking logic)

@Oneirical

Copy link
Copy Markdown
Contributor Author

@bors r=@jieyouxu

@bors

bors commented Jul 31, 2024

Copy link
Copy Markdown
Collaborator

📌 Commit ea04b0a has been approved by jieyouxu

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 Jul 31, 2024
tgross35 added a commit to tgross35/rust that referenced this pull request Jul 31, 2024
Migrate `symbol-visibility` `run-make` test to rmake

Part of rust-lang#121876 and the associated [Google Summer of Code project](https://blog.rust-lang.org/2024/05/01/gsoc-2024-selected-projects.html).

Pretty scary!

- The expected number of symbols on each check has been changed slightly to reflect the differences between `llvm_readobj` and `nm`, as I think the former will print hidden symbols once and visible symbols twice, while the latter will only print visible symbols.
- The original test ran the same exact checks on `cdylib` twice, for seemingly no reason. I have removed it.
- This may be possible to optimize some more? `llvm_readobj` could get called only once for each library type, and the regex could avoid being created repeatedly. I am not sure if these kinds of considerations are important for a `run-make` test.

Demands a Windows try-job.

try-job: x86_64-mingw
bors added a commit to rust-lang-ci/rust that referenced this pull request Jul 31, 2024
Rollup of 7 pull requests

Successful merges:

 - rust-lang#117468 (Stabilize Wasm relaxed SIMD)
 - rust-lang#123813 (Add `REDUNDANT_IMPORTS` lint for new redundant import detection)
 - rust-lang#127060 (Migrate `symbol-visibility` `run-make` test to rmake)
 - rust-lang#127159 (match lowering: Hide `Candidate` from outside the lowering algorithm)
 - rust-lang#128296 (Update target-spec metadata for loongarch64 targets)
 - rust-lang#128416 (android: Remove libstd hacks for unsupported Android APIs)
 - rust-lang#128431 (Add myself as VxWorks target maintainer for reference)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors

bors commented Aug 1, 2024

Copy link
Copy Markdown
Collaborator

⌛ Testing commit ea04b0a with merge 70591dc...

@bors

bors commented Aug 1, 2024

Copy link
Copy Markdown
Collaborator

☀️ Test successful - checks-actions
Approved by: jieyouxu
Pushing 70591dc to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Aug 1, 2024
@bors bors merged commit 70591dc into rust-lang:master Aug 1, 2024
@rustbot rustbot added this to the 1.82.0 milestone Aug 1, 2024
@rust-timer

Copy link
Copy Markdown
Collaborator

Finished benchmarking commit (70591dc): comparison URL.

Overall result: no relevant changes - no action needed

@rustbot label: -perf-regression

Instruction count

This benchmark run did not return any relevant results for this metric.

Max RSS (memory usage)

Results (primary 5.7%)

This is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.

mean range count
Regressions ❌
(primary)
5.7% [2.0%, 9.3%] 2
Regressions ❌
(secondary)
- - 0
Improvements ✅
(primary)
- - 0
Improvements ✅
(secondary)
- - 0
All ❌✅ (primary) 5.7% [2.0%, 9.3%] 2

Cycles

This benchmark run did not return any relevant results for this metric.

Binary size

This benchmark run did not return any relevant results for this metric.

Bootstrap: 759.166s -> 757.358s (-0.24%)
Artifact size: 336.88 MiB -> 336.90 MiB (0.01%)

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-testsuite Area: The testsuite used to check the correctness of rustc merged-by-bors This PR was explicitly merged by bors. 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)

Projects

No open projects
Status: Done

Development

Successfully merging this pull request may close these issues.

8 participants