MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / drain_threads

Method drain_threads

cranelift/filetests/src/runner.rs:291–305  ·  view source on GitHub ↗

Drain the async jobs and shut down the threads.

(&mut self)

Source from the content-addressed store, hash-verified

289
290 /// Drain the async jobs and shut down the threads.
291 fn drain_threads(&mut self) {
292 if let Some(mut conc) = self.threads.take() {
293 conc.shutdown();
294 while self.reported_tests < self.tests.len() {
295 match conc.get() {
296 Some(reply) => self.handle_reply(reply),
297 None => break,
298 }
299 }
300 let pass_times = conc.join();
301 if self.report_times {
302 println!("{pass_times}");
303 }
304 }
305 }
306
307 /// Print out a report of slow tests.
308 fn report_slow_tests(&self) {

Callers 2

runMethod · 0.80
run_passesMethod · 0.80

Calls 6

handle_replyMethod · 0.80
takeMethod · 0.45
shutdownMethod · 0.45
lenMethod · 0.45
getMethod · 0.45
joinMethod · 0.45

Tested by

no test coverage detected