ArceOS 框架设计
ArceOS的整体架构如下所示:
ArceOS 是一个开源的、组件化的Unikernel。以组合组件库的方式构建系统。使用Rust开发。
具有一下特点和功能:
- CPU架构: x86_64, riscv64, aarch64
- 运行平台: QEMU pc-q35 (x86_64), virt (riscv64/aarch64)
- 支持多线程: Multi-thread
- 调度算法: FIFO/RR/CFS scheduler
- 虚拟IO: VirtIO net/blk/gpu drivers
- 网络协议: TCP/UDP net stack using smoltcp
- 同步/互斥: Synchronization/Mutex
- SMP调度: SMP scheduling with single run queue
- 文件系统: File system
ArceOS 由apps、crates、modules组成
- apps: 应用程序。它的运行需要依赖于modules组件库。
- modules: ArceOS的组件库。
- crates: 通用的基础库。为modules实现提供支持。
当前ArceOS项目的apps列表如下:
Applications (Rust)
App | Extra modules | Enabled features | Description |
---|---|---|---|
helloworld | A minimal app that just prints a string | ||
exception | paging | Exception handling test | |
memtest | axalloc | alloc, paging | Dynamic memory allocation test |
display | axalloc, axdisplay | alloc, paging, display | Graphic/GUI test |
yield | axalloc, axtask | alloc, paging, multitask, sched_fifo | Multi-threaded yielding test |
parallel | axalloc, axtask | alloc, paging, multitask, sched_fifo, irq | Parallel computing test (to test synchronization & mutex) |
sleep | axalloc, axtask | alloc, paging, multitask, sched_fifo, irq | Thread sleeping test |
priority | axalloc, axtask | alloc, paging, multitask, sched_cfs | Thread priority test |
shell | axalloc, axdriver, axfs | alloc, paging, fs | A simple shell that responds to filesystem operations |
httpclient | axalloc, axdriver, axnet | alloc, paging, net | A simple client that sends an HTTP request and then prints the response |
echoserver | axalloc, axdriver, axnet, axtask | alloc, paging, net, multitask | A multi-threaded TCP server that reverses messages sent by the client |
httpserver | axalloc, axdriver, axnet, axtask | alloc, paging, net, multitask | A multi-threaded HTTP server that serves a static web page |
udpserver | axalloc, axdriver, axnet | alloc, paging, net | A simple echo server using UDP protocol |
Applications (C)
App | Extra modules | Enabled features | Description |
---|---|---|---|
helloworld | A minimal C app that just prints a string | ||
memtest | axalloc | alloc, paging | Dynamic memory allocation test in C |
sqlite3 | axalloc, axdriver, axfs | alloc, paging, fp_simd, fs | Porting of SQLite3 |