Intrepid/Prometeu/Runtime/pipeline/head This commit looks good
Reviewed-on: #13 Co-authored-by: bQUARKz <bquarkz@gmail.com> Co-committed-by: bQUARKz <bquarkz@gmail.com>
69 lines
2.2 KiB
Rust
69 lines
2.2 KiB
Rust
use crate::syscalls::{Syscall, SyscallRegistryEntry, caps};
|
|
|
|
pub(crate) const ENTRIES: &[SyscallRegistryEntry] = &[
|
|
SyscallRegistryEntry::builder(Syscall::FsOpen, "fs", "open")
|
|
.args(1)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::FsRead, "fs", "read")
|
|
.args(1)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::FsWrite, "fs", "write")
|
|
.args(2)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::FsClose, "fs", "close").args(1).caps(caps::FS).cost(5),
|
|
SyscallRegistryEntry::builder(Syscall::FsListDir, "fs", "list_dir")
|
|
.args(1)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::FsExists, "fs", "exists").args(1).rets(1).caps(caps::FS),
|
|
SyscallRegistryEntry::builder(Syscall::FsDelete, "fs", "delete")
|
|
.args(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotCount, "mem", "slot_count")
|
|
.rets(2)
|
|
.caps(caps::FS),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotStat, "mem", "slot_stat")
|
|
.args(1)
|
|
.rets(5)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(5),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotRead, "mem", "slot_read")
|
|
.args(3)
|
|
.rets(3)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotWrite, "mem", "slot_write")
|
|
.args(3)
|
|
.rets(2)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotCommit, "mem", "slot_commit")
|
|
.args(1)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
SyscallRegistryEntry::builder(Syscall::MemSlotClear, "mem", "slot_clear")
|
|
.args(1)
|
|
.rets(1)
|
|
.caps(caps::FS)
|
|
.non_deterministic()
|
|
.cost(20),
|
|
];
|