Files
hakorune/docs/private/roadmap/phases/phase-15.76/TODO.md

28 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Phase 15.76 — TODOextern_c / SelfHost Bootstrap
短期Week 1 — extern_c MVPVMのみ
- [ ] Parser: `extern_c "name" (args)` 構文を AST に追加
- [ ] MIR Builder: `extern_call``interface="ffi.dynamic"` を発行
- [ ] VM: `call_dynamic_ffi()` 実装0/1/2 引数・i64 返り)+ ホワイトリスト
- [ ] スモーク3本: getpid()/strlen()/system() の最小動作
短期Week 2 — ネイティブライブラリ
- [ ] `libs/llvm_backend/` 雛形+ C API`llvm_compile_mir_to_object`
- [ ] Python llvmlite ハーネス呼び出し連携
- [ ] スモーク: MIR JSON → .o戻り 0
短期Week 3 — LLVM AOT
- [ ] llvmlite ビルダーの `ffi.dynamic` 対応declare/call
- [ ] `.hako -> mir.json -> .o -> exe` を 1 ケース通す
- [ ] パリティVM/AOT
短期Week 4 — SelfHost 最小統合
- [ ] apps/selfhost/compiler.hako最小: 1ファイル .o 化→clang link 実行
- [ ] スモーク: selfhost mini パイプラインoptin
参照
- 戦略(全体像): ../phase-15.75/stage-4-chatgpt/EXTERN_C_SELFHOST_STRATEGY.md
- CABI最小: ../phase-15.75/stage-4-chatgpt/C_ABI_MIN_SPEC.md
- 統合方針Claude: ../phase-15.75/stage-4-chatgpt/INTEGRATION_STRATEGY_CLAUDE.md
- Stage4CABIハーネス: ../phase-15.75/stage-4-chatgpt/INDEX.md