-
Notifications
You must be signed in to change notification settings - Fork 180
Move memo dropping off to another thread #874
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
base: master
Are you sure you want to change the base?
Conversation
✅ Deploy Preview for salsa-rs canceled.
|
8237471
to
ce1baa4
Compare
CodSpeed Performance ReportMerging #874 will degrade performances by 10.07%Comparing Summary
Benchmarks breakdown
|
ce1baa4
to
c715adb
Compare
Regressions are kind of expected given we no longer keep the boxcar allocation from before. |
7be2574
to
bcca0a3
Compare
false, | ||
if tracing::enabled!(Level::DEBUG) { | ||
Some(Box::new(|event| { | ||
tracing::debug!("salsa_event({:?})", event) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you're touching this:
tracing::debug!("salsa_event({:?})", event) | |
tracing::debug!(?event, "salsa_event") |
@@ -1,9 +1,18 @@ | |||
use std::mem; | |||
|
|||
use crossbeam_utils::sync::{Parker, Unparker}; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
might be too much of a lift, but is there any chance you can replace these with shuttle's park
/unpark
primitives? I assume you'll need to replicate crossbeam_utils
in the sync
module, unfortunately.
|
||
/// An untyped memo that can only be dropped. | ||
#[derive(Debug)] | ||
pub struct MemoDrop(NonNull<DummyMemo>, unsafe fn(NonNull<DummyMemo>)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Three things:
- I didn't know it was legal to write
unsafe fn(NonNull<DummyMemo>)
. I'm guessing that if you pass it a safe closure, this will fail to compile? - Can you make these named fields instead of tuple structs?
- I really think this should be tested with Shuttle. if you're okay with me pushing to your branch, i can do that?
01799e6
to
66c99be
Compare
Design considerations to be solved:
Still needs a test