Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/chyyuu/os_kernel_lab
/ functions
Functions
600 in github.com/chyyuu/os_kernel_lab
⨍
Functions
600
◇
Types & classes
104
↓ 51 callers
Method
exclusive_access
Panic if the data has been borrowed.
os/src/sync/up.rs:109
↓ 50 callers
Method
len
(&self)
os/src/mm/page_table.rs:206
↓ 49 callers
Method
inner_exclusive_access
(&self)
os/src/task/task.rs:19
↓ 48 callers
Function
clone
(_: *const ())
user/src/bin/stackless_coroutine.rs:101
↓ 47 callers
Method
push
Add a new MapArea into this MemorySet. Assuming that there are no conflicts in the virtual address space.
os/src/mm/memory_set.rs:77
↓ 39 callers
Method
lock
(&self)
os/src/sync/mutex.rs:25
↓ 34 callers
Function
exit
(exit_code: i32)
user/src/task.rs:3
↓ 32 callers
Function
drop
(_: *const ())
user/src/bin/stackless_coroutine.rs:106
↓ 31 callers
Function
syscall
(id: usize, args: [usize; 3])
user/src/syscall.rs:33
↓ 28 callers
Method
push
(&mut self, closure: C)
user/src/bin/stackless_coroutine.rs:66
↓ 27 callers
Function
close
(fd: usize)
user/src/file.rs:19
↓ 22 callers
Function
get_block_cache
( block_id: usize, block_device: Arc<dyn BlockDevice>, )
easy-fs/src/block_cache.rs:128
↓ 22 callers
Function
get_time
()
user/src/task.rs:9
↓ 21 callers
Function
current_process
()
os/src/task/processor.rs:67
↓ 21 callers
Method
map
(&mut self, page_table: &mut PageTable)
os/src/mm/memory_set.rs:307
↓ 19 callers
Function
waittid
(tid: usize)
user/src/task.rs:73
↓ 18 callers
Method
find
(&self, name: &str)
easy-fs/src/vfs.rs:62
↓ 18 callers
Function
thread_create
(entry: usize, arg: usize)
user/src/task.rs:67
↓ 16 callers
Method
modify
(&mut self, offset: usize, f: impl FnOnce(&mut T) -> V)
easy-fs/src/block_cache.rs:59
↓ 15 callers
Method
into_iter
(self)
user/src/bin/gui_snake.rs:35
↓ 14 callers
Function
current_task
()
os/src/task/processor.rs:63
↓ 14 callers
Function
fork
()
user/src/task.rs:15
↓ 14 callers
Method
is_empty
(&self)
os/src/drivers/input/mod.rs:49
↓ 14 callers
Function
read
(fd: usize, buf: &mut [u8])
user/src/file.rs:25
↓ 13 callers
Method
clear
(&self)
easy-fs/src/vfs.rs:174
↓ 13 callers
Function
sleep
(sleep_ms: usize)
user/src/task.rs:63
↓ 11 callers
Method
contains
(&self, this: Point)
user/src/bin/gui_snake.rs:69
↓ 11 callers
Method
exclusive_session
(&self, f: F)
os/src/sync/up.rs:114
↓ 11 callers
Function
yield_
()
user/src/task.rs:6
↓ 9 callers
Method
as_bytes
(&self)
easy-fs/src/layout.rs:396
↓ 9 callers
Method
inner_exclusive_access
(&self)
os/src/task/process.rs:70
↓ 9 callers
Function
open
(path: &str, flags: OpenFlags)
user/src/file.rs:16
↓ 9 callers
Function
wait
(exit_code: &mut i32)
user/src/task.rs:21
↓ 9 callers
Function
write
(fd: usize, buf: &[u8])
user/src/file.rs:28
↓ 8 callers
Method
draw
(&mut self, target: &mut D)
user/src/bin/gui_snake.rs:213
↓ 8 callers
Method
floor
(&self)
os/src/mm/address.rs:100
↓ 8 callers
Method
getpid
(&self)
os/src/task/process.rs:255
↓ 8 callers
Method
next
(&mut self)
os/src/mm/address.rs:252
↓ 8 callers
Method
ppn
(&self)
os/src/mm/page_table.rs:35
↓ 8 callers
Method
read
(&self, offset: usize, f: impl FnOnce(&T) -> V)
easy-fs/src/block_cache.rs:55
↓ 8 callers
Method
token
(&self)
os/src/mm/memory_set.rs:48
↓ 7 callers
Method
get_top
(&self)
os/src/task/id.rs:106
↓ 7 callers
Function
mutex_lock
(mutex_id: usize)
user/src/sync.rs:9
↓ 7 callers
Function
mutex_unlock
(mutex_id: usize)
user/src/sync.rs:12
↓ 7 callers
Method
page_offset
(&self)
os/src/mm/address.rs:106
↓ 7 callers
Function
schedule
(switched_task_cx_ptr: *mut TaskContext)
os/src/task/processor.rs:97
↓ 6 callers
Method
create
( block_device: Arc<dyn BlockDevice>, total_blocks: u32, inode_bitmap_blocks: u32,
easy-fs/src/efs.rs:20
↓ 6 callers
Function
current_user_token
()
os/src/task/processor.rs:71
↓ 6 callers
Function
frame_alloc
()
os/src/mm/frame_allocator.rs:100
↓ 6 callers
Method
get_bytes_array
(&self)
os/src/mm/address.rs:175
↓ 6 callers
Function
get_time_u
()
user/src/bin/phil_din_mutex.rs:19
↓ 6 callers
Method
get_trap_cx
(&self)
os/src/task/task.rs:39
↓ 6 callers
Method
set_direction
(&mut self, direction: Direction)
user/src/bin/gui_snake.rs:66
↓ 6 callers
Function
translated_refmut
(token: usize, ptr: *mut T)
os/src/mm/page_table.rs:189
↓ 6 callers
Method
write
(&mut self, ch: u8)
os/src/drivers/chardev/ns16550a.rs:111
↓ 5 callers
Function
add_task
(task: Arc<TaskControlBlock>)
os/src/task/manager.rs:33
↓ 5 callers
Function
exec
(path: &str, args: &[*const u8])
user/src/task.rs:18
↓ 5 callers
Method
flags
(&self)
os/src/mm/page_table.rs:38
↓ 5 callers
Method
get_disk_inode_pos
(&self, inode_id: u32)
easy-fs/src/efs.rs:111
↓ 5 callers
Method
into_iter
(self)
os/src/mm/address.rs:228
↓ 5 callers
Function
semaphore_down
(sem_id: usize)
user/src/sync.rs:21
↓ 5 callers
Function
semaphore_up
(sem_id: usize)
user/src/sync.rs:18
↓ 5 callers
Function
suspend_current_and_run_next
()
os/src/task/mod.rs:29
↓ 5 callers
Method
write_at
(&self, offset: usize, buf: &[u8])
easy-fs/src/vfs.rs:164
↓ 4 callers
Method
alloc_fd
(&mut self)
os/src/task/process.rs:43
↓ 4 callers
Function
block_cache_sync_all
()
easy-fs/src/block_cache.rs:137
↓ 4 callers
Function
block_current_and_run_next
()
os/src/task/mod.rs:55
↓ 4 callers
Method
handle_irq
(&self)
os/src/drivers/input/mod.rs:66
↓ 4 callers
Method
modify_disk_inode
(&self, f: impl FnOnce(&mut DiskInode) -> V)
easy-fs/src/vfs.rs:39
↓ 4 callers
Function
pipe
(pipe_fd: &mut [usize])
user/src/file.rs:22
↓ 4 callers
Method
read_at
(&self, offset: usize, buf: &mut [u8])
easy-fs/src/vfs.rs:159
↓ 4 callers
Method
signal
(&self)
os/src/sync/condvar.rs:27
↓ 4 callers
Method
spawn
While `yield` is the logically interesting function I think this the technically most interesting. When we spawn a new task we first check if there a
user/src/bin/stackful_coroutine.rs:181
↓ 4 callers
Method
step
(&mut self)
os/src/mm/address.rs:189
↓ 4 callers
Method
translate
(&self, vpn: VirtPageNum)
os/src/mm/memory_set.rs:241
↓ 4 callers
Method
translate_va
(&self, va: VirtAddr)
os/src/mm/page_table.rs:127
↓ 4 callers
Function
trap_cx_bottom_from_tid
(tid: usize)
os/src/task/id.rs:118
↓ 4 callers
Method
wait_no_sched
(&self)
os/src/sync/condvar.rs:43
↓ 4 callers
Function
wakeup_task
(task: Arc<TaskControlBlock>)
os/src/task/manager.rs:37
↓ 4 callers
Function
yield_task
We know that Runtime is alive the length of the program and that we only access from one core (so no datarace). We yield execution of the current task
user/src/bin/stackful_coroutine.rs:220
↓ 3 callers
Method
add
(&mut self, task: Arc<TaskControlBlock>)
os/src/task/manager.rs:18
↓ 3 callers
Method
alloc
(&mut self)
os/src/task/id.rs:23
↓ 3 callers
Function
condvar_signal
(condvar_id: usize)
user/src/sync.rs:27
↓ 3 callers
Method
data_blocks
Return block number correspond to size.
easy-fs/src/layout.rs:96
↓ 3 callers
Function
f
()
user/src/bin/adder.rs:25
↓ 3 callers
Method
find_pte
(&self, vpn: VirtPageNum)
os/src/mm/page_table.rs:95
↓ 3 callers
Function
framebuffer_flush
()
user/src/io.rs:15
↓ 3 callers
Method
get_mut
(&self)
os/src/sync/up.rs:48
↓ 3 callers
Method
get_start
(&self)
os/src/mm/address.rs:215
↓ 3 callers
Function
get_time_ms
()
os/src/timer.rs:19
↓ 3 callers
Function
getchar
()
user/src/console.rs:35
↓ 3 callers
Method
init
(&mut self, l: PhysPageNum, r: PhysPageNum)
os/src/mm/frame_allocator.rs:48
↓ 3 callers
Method
initialize
( &mut self, total_blocks: u32, inode_bitmap_blocks: u32, inode_area_blocks: u
easy-fs/src/layout.rs:39
↓ 3 callers
Method
insert_framed_area
Assume that no conflicts.
os/src/mm/memory_set.rs:52
↓ 3 callers
Function
kernel_stack_position
Return (bottom, top) of a kernel stack in kernel space.
os/src/task/id.rs:64
↓ 3 callers
Method
ls
(&self)
easy-fs/src/vfs.rs:142
↓ 3 callers
Method
make_step
(&mut self)
user/src/bin/gui_snake.rs:82
↓ 3 callers
Method
map_trampoline
Mention that trampoline is not collected by areas.
os/src/mm/memory_set.rs:85
↓ 3 callers
Method
read
(&mut self)
os/src/drivers/chardev/ns16550a.rs:101
↓ 3 callers
Method
read_disk_inode
(&self, f: impl FnOnce(&DiskInode) -> V)
easy-fs/src/vfs.rs:33
next →
1–100 of 600, ranked by callers