chore: 修正包命名空间为 htttt-star(匹配 mooncakes.io 账号)并发布
面向 MoonBit 编译产物的 Wasm 二进制体积分析工具。直接解析 .wasm 文件,统计 section、函数、符号、包维度的体积分布,支持终端表格、JSON、CSV、Markdown、treemap 和版本对比。
.wasm
moon test
需要 C 编译器(Windows: Visual Studio Build Tools + Windows SDK 或 tcc)。
moon build --target native moon run --target native cmd/main -- sections target.wasm
read_file
moonshrink target.wasm --top 30 --format json moonshrink sections target.wasm moonshrink symbols target.wasm moonshrink treemap target.wasm -o treemap.json moonshrink diff old.wasm new.wasm --top 30
testdata/wasm/ 包含 6 个 wasm 文件:
testdata/wasm/
版权所有:中国计算机学会技术支持:开源发展技术委员会 京ICP备13000930号-9 京公网安备 11010802047560号
moonshrink — MoonBit Wasm 体积分析工具
面向 MoonBit 编译产物的 Wasm 二进制体积分析工具。直接解析
.wasm文件,统计 section、函数、符号、包维度的体积分布,支持终端表格、JSON、CSV、Markdown、treemap 和版本对比。构建与运行
开发测试(无需 C toolchain)
Native 编译
需要 C 编译器(Windows: Visual Studio Build Tools + Windows SDK 或 tcc)。
目标兼容说明
moon test默认目标,沙箱无文件 I/O,read_file返回桩错误。CLI 使用
退出码
测试 fixtures
testdata/wasm/包含 6 个 wasm 文件:项目规模