MCPcopy Create free account
hub / github.com/bendudson/EuraliOS / thread_yield

Function thread_yield

euralios_std/src/syscalls.rs:227–234  ·  view source on GitHub ↗

Gives up the processor for another thread to run. Usually called when a thread has nothing useful to do and can wait for an undetermined amount of time.

()

Source from the content-addressed store, hash-verified

225/// Usually called when a thread has nothing useful to do
226/// and can wait for an undetermined amount of time.
227pub fn thread_yield() {
228 unsafe{
229 asm!("syscall",
230 in("rax") SYSCALL_YIELD,
231 out("rcx") _,
232 out("r11") _);
233 }
234}
235
236/// Wait for a message to be received
237pub fn receive(handle: &CommHandle) -> Result<Message, SyscallError> {

Callers 13

mainFunction · 0.85
dispatch_loopFunction · 0.85
rcallFunction · 0.85
mainFunction · 0.85
writer_handlerFunction · 0.85
mainFunction · 0.85
resetMethod · 0.85
send_packetMethod · 0.85
mainFunction · 0.85
open_socketFunction · 0.85
configureFunction · 0.85
resolveFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected