mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-26 11:59:49 +00:00
Add proof-of-concept QoS implementation
This commit is contained in:
parent
bb78059be4
commit
ca6461c143
14 changed files with 254 additions and 23 deletions
|
@ -21,7 +21,7 @@ use walkdir::WalkDir;
|
|||
pub struct NotifyHandle {
|
||||
// Relative order of fields below is significant.
|
||||
sender: Sender<Message>,
|
||||
_thread: jod_thread::JoinHandle,
|
||||
_thread: stdx::thread::JoinHandle,
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
|
@ -34,7 +34,7 @@ impl loader::Handle for NotifyHandle {
|
|||
fn spawn(sender: loader::Sender) -> NotifyHandle {
|
||||
let actor = NotifyActor::new(sender);
|
||||
let (sender, receiver) = unbounded::<Message>();
|
||||
let thread = jod_thread::Builder::new()
|
||||
let thread = stdx::thread::Builder::new(stdx::thread::QoSClass::Utility)
|
||||
.name("VfsLoader".to_owned())
|
||||
.spawn(move || actor.run(receiver))
|
||||
.expect("failed to spawn thread");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue