Skip to content

Commit 03c5a06

Browse files
committed
Prompt 1.3: Replace imaginary --backend-shape-report with real -o output
The audit document referenced a --backend-shape-report CLI flag that does not exist. Replaced it with the actual cellc -o workflow that produces ELF + .meta.json, and documented the four evidence sources for backend shape auditing: 1. ELF header validation 2. .meta.json inspection (runtime features, obligations, fail-closed) 3. Source-level RISC-V emit path inspection 4. Negative confirmation of runtime-required vs over-lowered Added explicit decision note: do not add --backend-shape-report for 0.15; it is a valuable 0.16+ compiler evidence feature, not a 0.15 release blocker.
1 parent abe499c commit 03c5a06

1 file changed

Lines changed: 15 additions & 3 deletions

File tree

‎docs/CELLSCRIPT_0_15_PRE_RELEASE_AUDIT_AND_HARDENING.md‎

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,14 +78,24 @@ cargo test --locked -p cellscript docgen --lib
7878
### 1.3 后端形状稳定性
7979

8080
```bash
81-
# 生成后端形状报告
82-
mkdir -p target/cellscript-backend-shape
81+
# 生成后端审计产物(ELF + metadata)
82+
mkdir -p target/cellscript-audit
8383
cargo run --locked -p cellscript -- \
8484
examples/token.cell \
8585
--target riscv64-elf --target-profile ckb --primitive-strict 0.15 \
86-
--backend-shape-report target/cellscript-backend-shape/backend-shape-report-main.json
86+
-o target/cellscript-audit/token.elf
8787
```
8888

89+
**Expected artifacts**:
90+
- `target/cellscript-audit/token.elf`
91+
- `target/cellscript-audit/token.elf.meta.json`
92+
93+
**Backend shape evidence is collected from**:
94+
1. ELF header validation (`xxd -l 4` → `\x7fELF`).
95+
2. Generated `.meta.json` inspection (runtime features, verifier obligations, fail-closed list).
96+
3. Targeted source inspection of RISC-V emit paths (`emit_create_unique`, `emit_replace_unique`, `emit_destroy`).
97+
4. Negative confirmation that unsupported policies remain `runtime-required` rather than being over-lowered.
98+
8999
**Prompt**:
90100
> 作为后端审计员,验证:
91101
> - 生成的 RISC-V ELF 以 `\x7fELF` 开头。
@@ -95,6 +105,8 @@ cargo run --locked -p cellscript -- \
95105
> - `destroy_instance` 和 `burn_amount` 明确标记为 metadata-visible runtime-required,不发射 over-broad 的 TypeHash scan。
96106
> - 没有新增的未处理 IR pattern 导致 panic 或默认分支。
97107
108+
**Decision**:Do not add `--backend-shape-report` for 0.15. The audit document was ahead of the current CLI surface. A dedicated backend-shape report is a valuable 0.16+ compiler evidence feature, not a 0.15 release blocker.
109+
98110
---
99111

100112
## 审计阶段二:语法组合预飞行

0 commit comments

Comments
 (0)