Skip to content

Add behavior tests for Arc and Rc - #164851

Open
EFanZh wants to merge 2 commits into
rust-lang:mainfrom
EFanZh:add-rc-behavior-tests
Open

EFanZh wants to merge 2 commits into
rust-lang:mainfrom
EFanZh:add-rc-behavior-tests

Conversation

@EFanZh

@EFanZh EFanZh commented Oct 24, 2026 •

Copy link
Copy Markdown
Contributor

@rustbot rustbot added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels Oct 24, 2026
@rustbot

rustbot commented Oct 24, 2026

Copy link
Copy Markdown
Collaborator

tgross35 is currently at their maximum review capacity.
They may take a while to respond.

@EFanZh EFanZh changed the title Add behavior tests for Arc and `Rc Add behavior tests for Arc and Rc Oct 24, 2026
@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch from d4cc2de to 48c24e4 Compare October 24, 2026 12:12
@EFanZh EFanZh mentioned this pull request Oct 24, 2026
18 tasks
@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch 2 times, most recently from bd89710 to 71516d2 Compare October 24, 2026 14:00
@EFanZh
EFanZh marked this pull request as ready for review October 24, 2026 16:03
@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 Oct 24, 2026

@tgross35 tgross35 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.

Few things that I think make this more robust, then LGTM

View changes since this review

Comment thread tests/assembly-llvm/x86_64-rc-arc.rs
Comment thread tests/assembly-llvm/x86_64-rc-arc.rs
Comment thread tests/assembly-llvm/x86_64-rc-arc.rs
@tgross35

Copy link
Copy Markdown
Member

@rustbot author

Just for the CHECK-DAG, assuming it works

@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 26, 2026
@rustbot

rustbot commented Oct 26, 2026

Copy link
Copy Markdown
Collaborator

Reminder, once the PR becomes ready for a review, use @rustbot ready.

@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch from 71516d2 to 0c567bf Compare October 27, 2026 00:55
Comment thread tests/assembly-llvm/x86_64-rc-arc.rs Outdated
Comment on lines +4 to +6
//@ needs-llvm-components: x86
//@ compile-flags: --crate-type=lib -Z merge-functions=disabled -C opt-level=3 --target=x86_64-unknown-linux-gnu -C llvm-args=-x86-asm-syntax=intel
//@ assembly-output: emit-asm

@tgross35 tgross35 Oct 27, 2026 •

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.

I think these should probably be reverted to how they were earlier, since needs-llvm-components: x86 does get hit even when std might not be built for x86_64-unknown-linux-gnu. (Might see this failure in CI)

View changes since the review

@rust-log-analyzer

This comment has been minimized.

@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch from 0c567bf to 808a955 Compare October 27, 2026 02:34

@tgross35 tgross35 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.

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

📌 Commit 808a955 has been tentatively approved by tgross35

It will be put into the queue for this repository once PR CI succeeds.

@rust-bors rust-bors Bot 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 27, 2026
tgross35 added a commit to tgross35/rust that referenced this pull request Oct 27, 2026
rust-bors Bot pushed a commit that referenced this pull request Oct 27, 2026
Rollup of 8 pull requests

Successful merges:

 - #164168 (Add tests for unsoundness involving alias liveness)
 - #164608 (core: Constify `resumable_breakpoint` and re-export it in `std`)
 - #164787 (cg_llvm: Use an invariant lifetime brand for LLVM contexts )
 - #164851 (Add behavior tests for `Arc` and `Rc`)
 - #164966 (x86-64-linux-gnu seems to have working f128 now)
 - #153893 (Lex lifetimes as identifiers, recover from emoji and emit appropriate error)
 - #164895 (Disable recovery when attribute parser shouldn't emit)
 - #165004 (docs: Nitpick change in `HashMap`'s `.insert_entry()` doc example)
@tgross35

Copy link
Copy Markdown
Member

@bors r- #165018 (comment)

Probably should just set //@ min-llvm-version: 23 to avoid this

@rust-bors rust-bors Bot added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Oct 27, 2026
@rust-bors rust-bors Bot removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Oct 27, 2026
@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

This pull request was unapproved.

This PR was contained in a rollup (#165018), which was unapproved.

View changes since this unapproval

@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch from 808a955 to b56bec4 Compare October 27, 2026 06:54
@tgross35

Copy link
Copy Markdown
Member

@bors r+

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

📌 Commit b56bec4 has been tentatively approved by tgross35

It will be put into the queue for this repository once PR CI succeeds.

@rust-bors rust-bors Bot 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-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Oct 27, 2026
@EFanZh

EFanZh commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor Author

@bors r- #165018 (comment)

Probably should just set //@ min-llvm-version: 23 to avoid this

@tgross35: Why use 23? I only see llvm-22 in the current PR CI jobs.

@tgross35

Copy link
Copy Markdown
Member

23 is the default, just not specified. It failed with LLVM22 in the job I linked at #164851 (comment).

@EFanZh

EFanZh commented Oct 27, 2026 •

Copy link
Copy Markdown
Contributor Author

@tgross35: I suspect the failure is caused by randomize-layout, not LLVM version. The failure happens before calling handle_alloc_error, which takes a Layout argument, the registers are inverted in the failure case.

@tgross35

tgross35 commented Oct 27, 2026 •

Copy link
Copy Markdown
Member

@bors r-

Good catch. In that case, I guess that could be disabled and LLVM22 re-enabled

@rust-bors rust-bors Bot added the S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. label Oct 27, 2026
@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

This pull request was unapproved.

View changes since this unapproval

@rust-bors rust-bors Bot removed the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Oct 27, 2026
@EFanZh
EFanZh force-pushed the add-rc-behavior-tests branch from b56bec4 to 74c3cca Compare October 27, 2026 12:48
@tgross35

Copy link
Copy Markdown
Member

@bors try jobs=test-x86_64-gnu-llvm-22-*

rust-bors Bot pushed a commit that referenced this pull request Oct 27, 2026
Add behavior tests for `Arc` and `Rc`


try-job: test-x86_64-gnu-llvm-22-*
@rust-bors

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

💔 Test for 54f9347 failed: CI. Failed jobs:

@EFanZh

EFanZh commented Oct 27, 2026

Copy link
Copy Markdown
Contributor Author

Not only randomize-layout, I also see debug assertions being enabled.

@EFanZh

EFanZh commented Oct 27, 2026

Copy link
Copy Markdown
Contributor Author

@bors try jobs=test-x86_64-gnu-llvm-22-*

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

@EFanZh: 🔑 Insufficient privileges: not in try users

@tgross35

Copy link
Copy Markdown
Member

@bors delegate=tru

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

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

If @tgross35 told you to "r=me" after making some further change, then please make that change and post @bors r=tgross35.

View changes since this delegation.

@tgross35

Copy link
Copy Markdown
Member

@bors delegate-
@bors delegate=try

@rust-bors

rust-bors Bot commented Oct 27, 2026

Copy link
Copy Markdown
Contributor

✌️ @EFanZh, you can now perform try builds on this pull request!

Warning

You used the legacy format of the delegate command.
The new format is @bors delegate[=<username>] [<try|review>].

You can now post @bors try to start a try build.

This branch has not been deployed

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

Labels

S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. 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.

4 participants