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

tests: restore disabled tests and benches for BiLock #2715

Merged
merged 1 commit into from
Mar 10, 2023

Conversation

LizardWizzard
Copy link
Contributor

Hi! I was curious about BiLock internals (came there from its usage in split) so the easiest way to play with something is to poke into corresponding tests. Found out that tests and benchmarks for BiLock are disabled so I went ahead with reviving them to be up to date with current landscape.

Thank you your great work on the library!

@LizardWizzard
Copy link
Contributor Author

Miri complains:

error: unsupported operation: integer-to-pointer casts and `ptr::from_exposed_addr` are not supported with `-Zmiri-strict-provenance`
   --> /home/runner/work/futures-rs/futures-rs/futures-util/src/lock/bilock.rs:178:31
    |
178 |                 Box::from_raw(n as *mut Waker).wake();
    |                               ^^^^^^^^^^^^^^^ integer-to-pointer casts and `ptr::from_exposed_addr` are not supported with `-Zmiri-strict-provenance`
    |
    = help: use Strict Provenance APIs (https://doc.rust-lang.org/nightly/std/ptr/index.html#strict-provenance, https://crates.io/crates/sptr) instead

Will it be desirable to go ahead with https://crates.io/crates/sptr as suggested in the error message?

@LizardWizzard LizardWizzard force-pushed the revive-bilock-tests branch 3 times, most recently from df79882 to 0a38a75 Compare March 10, 2023 14:31
@LizardWizzard
Copy link
Contributor Author

Thanks @taiki-e! I've rebased it on top of current master.

CI / cargo +beta build (pull_request) failed once with:

warning: spurious network error (10 tries remaining): [35] SSL connect error (error:1408F119:SSL routines:ssl3_get_record:decryption failed or bad record mac)
...
error: failed to verify the checksum of `byteorder v1.4.3`

Copy link
Member

@taiki-e taiki-e left a comment

Choose a reason for hiding this comment

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

Thanks!

futures-util/benches/bilock.rs Outdated Show resolved Hide resolved
futures/tests/bilock.rs Outdated Show resolved Hide resolved
@LizardWizzard
Copy link
Contributor Author

Thanks for review! Fixed the comments, please take another look

@LizardWizzard LizardWizzard requested a review from taiki-e March 10, 2023 17:58
@taiki-e taiki-e merged commit 44e9f31 into rust-lang:master Mar 10, 2023
@LizardWizzard LizardWizzard deleted the revive-bilock-tests branch March 10, 2023 18:19
@taiki-e taiki-e mentioned this pull request Jul 19, 2023
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants