Skip to content
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

PassWrapper: disable UseOdrIndicator for Asan Win32 #132773

Merged
merged 1 commit into from
Nov 14, 2024

Conversation

jakos-sec
Copy link

@jakos-sec jakos-sec commented Nov 8, 2024

As described in https://reviews.llvm.org/D137227 UseOdrIndicator should be disabled on Windows since link.exe does not support duplicate weak definitions.

Fixes #124390.

Credits also belong to @1c3t3a who worked with me on this.
We are currently testing this on a Windows machine.

@rustbot
Copy link
Collaborator

rustbot commented Nov 8, 2024

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @cuviper (or someone else) some time within the next two weeks.

Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (S-waiting-on-review and S-waiting-on-author) stays updated, invoking these commands when appropriate:

  • @rustbot author: the review is finished, PR author should check the comments and take action accordingly
  • @rustbot review: the author is ready for a review, this PR will be queued again in the reviewer's queue

@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. labels Nov 8, 2024
@rust-log-analyzer

This comment has been minimized.

@workingjubilee
Copy link
Member

Is there a test that this would affect?

@rcvalle
Copy link
Member

rcvalle commented Nov 9, 2024

Thank you very much for helping me out with pushing #123617 through the last mile, @1c3t3a and @jakos-sec! It has been much appreciated.

@1c3t3a
Copy link
Contributor

1c3t3a commented Nov 11, 2024

I just verified that this indeed fixes #124390.

@rcvalle
Copy link
Member

rcvalle commented Nov 12, 2024

Thank you for verifying it, @1c3t3a! Much appreciated. As @workingjubilee mentioned, would you mind also adding a build-pass ui regression test for it?

@workingjubilee
Copy link
Member

Yeah. It's not clear to me what this needs for testing, right now. If you need to do a somewhat baroque custom build of Rust code, we can walk you through setting that up. But this really should land with a regression test.

@rustbot rustbot added A-compiletest Area: The compiletest test runner A-testsuite Area: The testsuite used to check the correctness of rustc T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) labels Nov 13, 2024
@rustbot

This comment was marked as off-topic.

@jakos-sec
Copy link
Author

We just added the ui regression test and tested it on Windows. Let me know what you think.

(I forgot to rebase on the first force push, sorry if this triggered some cc's).

Copy link
Member

@jieyouxu jieyouxu left a comment

Choose a reason for hiding this comment

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

Thanks, this LGTM with one minor nit.

tests/ui/asan-odr-win/asan_odr_windows.rs Outdated Show resolved Hide resolved
@jieyouxu jieyouxu removed A-testsuite Area: The testsuite used to check the correctness of rustc T-bootstrap Relevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap) A-compiletest Area: The compiletest test runner labels Nov 13, 2024
@jieyouxu
Copy link
Member

Thanks

r? jieyouxu
@bors r+ rollup=iffy (not really checked in PR CI AFAIK)

@bors
Copy link
Contributor

bors commented Nov 13, 2024

📌 Commit e40481e has been approved by jieyouxu

It is now in the queue for this repository.

@rustbot rustbot assigned jieyouxu and unassigned cuviper Nov 13, 2024
@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 Nov 13, 2024
@bors
Copy link
Contributor

bors commented Nov 13, 2024

⌛ Testing commit e40481e with merge ae6b322...

bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 13, 2024
PassWrapper: disable UseOdrIndicator for Asan Win32

As described in https://reviews.llvm.org/D137227 UseOdrIndicator should be disabled on Windows since link.exe does not support duplicate weak definitions.

Fixes rust-lang#124390.

Credits also belong to `@1c3t3a`  who worked with me on this.
We are currently testing this on a Windows machine.
@rust-log-analyzer

This comment has been minimized.

@bors
Copy link
Contributor

bors commented Nov 13, 2024

💔 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 Nov 13, 2024
As described here UseOdrIndicator should be disabled on Windows
since link.exe does not support duplicate weak definitions
(https://reviews.llvm.org/D137227).

Co-Authored-By: Bastian Kersting <bkersting@google.com>
@jieyouxu
Copy link
Member

Apparently our test infra has a bug with //@ aux-crate so I reverted the test change.

@bors r+ (only test changes got reverted)

@bors
Copy link
Contributor

bors commented Nov 13, 2024

📌 Commit 61013f0 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 Nov 13, 2024
bors added a commit to rust-lang-ci/rust that referenced this pull request Nov 14, 2024
…llaumeGomez

Rollup of 5 pull requests

Successful merges:

 - rust-lang#132010 (ci: Enable full `debuginfo-level=2` in `DEPLOY_ALT`)
 - rust-lang#132310 (compiletest: add `max-llvm-major-version` directive)
 - rust-lang#132773 (PassWrapper: disable UseOdrIndicator for Asan Win32)
 - rust-lang#133013 (compiletest: known-bug / crashes: allow for an "auxiliary" directory to contain files that do not have a "known-bug" directive)
 - rust-lang#133027 (Fix a copy-paste issue in the NuttX raw type definition)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit e3c76c5 into rust-lang:master Nov 14, 2024
6 checks passed
@rustbot rustbot added this to the 1.84.0 milestone Nov 14, 2024
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request Nov 14, 2024
Rollup merge of rust-lang#132773 - jakos-sec:fix-asan-win32, r=jieyouxu

PassWrapper: disable UseOdrIndicator for Asan Win32

As described in https://reviews.llvm.org/D137227 UseOdrIndicator should be disabled on Windows since link.exe does not support duplicate weak definitions.

Fixes rust-lang#124390.

Credits also belong to `@1c3t3a`  who worked with me on this.
We are currently testing this on a Windows machine.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to link use of hyper_util with -Zsanitizer=address on msvc
10 participants