You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
愿景
预期使用约一个月时间,将 Comix 重构为一个 build-time composable kernel。
核心目标:
当前版本重点不是完整生态系统,
而是验证:
核心能力
1. 可组合内核
内核由:
组成。
通过声明式配置组合 subsystem:
构建:
输出:
2. 明确的模块边界
模块之间仅允许通过 subsystem interface 通信。
仅在 subsystem boundary 使用 trait:
Core 内部保持 concrete implementation,
避免过度抽象化。
当前阶段暂不处理:
3. 可替换 subsystem
当前重点验证 scheduler replacement。
计划实现:
通过修改:
或:
构建不同行为的 kernel。
实施计划
0期计划:架构清理
目标:
为 subsystem 解耦与组件化建立基础。
重点:
任务:
例如:
当前阶段不引入新架构,
优先完成结构整理。
1期计划:组件化重构
1. 模块解耦
限制 subsystem 间直接依赖。
建立明确 subsystem boundary。
避免:
2. trait interface
仅在 subsystem boundary 使用 trait 定义接口。
例如:
避免全系统 trait 化。
3. crate split
将 subsystem 拆分为独立 crate:
为 build-time component selection 做准备。
2期计划:声明式构建系统
1. kernel.toml
定义 subsystem configuration format。
例如:
2. 构建解析器
由配置自动:
3. profile system(可选)
支持 profile-based kernel build。
例如:
不同 profile 组合不同 subsystem。
3期计划(可选)
当前版本重点是:
以下问题暂不解决:
未来可能研究:
当前设计原则
Minimal Core
Core 仅提供最小运行时机制。
Build-time Composition
所有 subsystem 在构建期静态组合。
Explicit Boundary
模块之间只能通过 interface interaction。
Replaceable Subsystem
Subsystem 必须能够独立实现与替换。
最终目标
最终需要验证:
如果这一点成立,
则说明:
Beta Was this translation helpful? Give feedback.
All reactions