Files
hakorune/docs/development/roadmap/phases/phase-11/README.md
Moe Charm fff9749f47 📚 Reorganize CLAUDE.md: slim down from 916 to 395 lines with proper doc links
- Keep essential information within 500 lines (now 395 lines)
- Maintain important syntax examples and development principles
- Move detailed information to appropriate docs files:
  - Development practices → docs/guides/development-practices.md
  - Testing guide → docs/guides/testing-guide.md
  - Claude issues → docs/tools/claude-issues.md
- Add proper links to all referenced documentation
- Balance between minimal entry point and practical usability
2025-08-31 06:22:48 +09:00

2.4 KiB
Raw Blame History

Phase 11: LLVM AOT Backend進行中

🎯 概要

Phase 11は、LLVM を使用した Ahead-of-TimeAOTコンパイル機能の研究・実装フェーズです。 Phase 10のCranelift JITで実用的な性能を達成した後、さらなる最適化をLLVM AOTで追求します。

📊 位置づけ

Phase 10: Cranelift JIT実用的な高速化← 完了
    ↓
Phase 11: LLVM AOT最高性能への挑戦← 進行中

📁 ドキュメント

🔬 研究・設計ドキュメント

  • phase10_aot_scaffolding.md - LLVM Direct AOT実装計画

    • MIR→LLVM IR直接変換
    • Everything is Box最適化エスケープ解析
    • LTO/PGO統合
    • 目標: 13,500倍高速化対インタープリタ
  • phase_10_x_llvm_backend_skeleton.md - LLVM Backend最小実装

    • 具体的な実装ステップ
    • ExternCall対応
    • オブジェクトファイル生成

タイムライン(短期スプリント)

  • Status: In Progress進行中
  • 前提条件: Phase 10Cranelift JITの完了、Core15統一VM/Verifierで運用
  • 想定期間: 4週間各フェーズ1週間目安
    • 11.1 基本変換: Const/Unary/Bin/Compare, Load/Store, Jump/Branch/Return/Phi
    • 11.2 Box統合: NewBox/BoxCall/ExternCall安全パスはランタイム呼び出し
    • 11.3 最適化: 注釈統合・型特化get/setField・Array get/set のInline化バリア
    • 11.4 高度化: 脱箱化・TBAA・PGO/ThinLTO

🎯 期待される成果

  1. 最高性能: インタープリタ比13,500倍の実行速度
  2. メモリ効率: Box割当80%削減
  3. 起動時間: 1ms以下
  4. 配布形式: スタンドアロン実行ファイル

⚠️ 注意事項(運用方針)

  • Core15 凍結(第三案): { Const, UnaryOp, BinOp, Compare, TypeOp, Load, Store, Jump, Branch, Return, Phi, Call, NewBox, BoxCall, ExternCall }
  • 統一ルール: ArrayGet/ArraySet, RefGet/RefSet, PluginInvoke はBoxCallに一本化Optimizerで正規化、Verifierで禁止
  • バリア方針: 初期はランタイム関数側で安全に処理、型特化Lowering段でIRへ内挿write barrier

🔗 関連フェーズ