a9e10d2a6a
feat(selfhost): Phase 81 Strict + Fail-Fast mode support
...
Phase 81: selfhost_build.sh に JoinIR Core/Strict モードサポート追加
## 変更内容
### 新オプション
- `--core`: JoinIR Core ON モード有効化 (Phase 80)
- `--strict`: Strict モード有効化(失敗時フォールバック禁止)
### 環境変数伝播
- `NYASH_JOINIR_CORE`: apply_selfhost_env() 経由で伝播
- `NYASH_JOINIR_STRICT`: apply_selfhost_env() 経由で伝播
### ドキュメント
- Usage コメントに全オプションと環境変数を記載
## 使用例
```bash
# Core ON + Strict mode
tools/selfhost/selfhost_build.sh --in test.hako --core --strict --run
# 環境変数経由
NYASH_JOINIR_CORE=1 NYASH_JOINIR_STRICT=1 tools/selfhost/selfhost_build.sh --in test.hako --run
```
🤖 Generated with [Claude Code](https://claude.com/claude-code )
Co-Authored-By: Claude <noreply@anthropic.com >
2025-12-02 13:46:51 +09:00
804ccff23f
feat(phase73): Selfhost Stage-B I/O 簡素化 - HAKO_SRC 環境変数統一化
...
Unified selfhost Stage-B I/O path from argv to environment variables:
- Remove --source "$SRC_CONTENT" from compiler.hako invocation (argv limit)
- Export HAKO_SRC="$SRC_CONTENT" instead (env-based I/O)
- Update compiler_stageb.hako to check HAKO_SRC fallback
Changes:
1. lang/src/compiler/entry/compiler_stageb.hako:
- Added HAKO_SRC env check in StageBArgsBox.resolve_src()
- Fallback order: --source arg → HAKO_SOURCE_FILE_CONTENT → HAKO_SRC → default
2. tools/selfhost/selfhost_build.sh:
- Removed --source "$SRC_CONTENT" from compiler.hako invocation
- Export HAKO_SRC="$SRC_CONTENT" before Stage-B execution
- Unified with wrapper pathway (HAKO_USE_BUILDBOX=1)
Benefits:
- Eliminates "Argument list too long" (os error 7) for large .hako files
- Single unified I/O pattern (env variables) for all Stage-B paths
- Consistent with hako_check.sh and wrapper pattern
- Ready for future HAKO_SRC_FILE optimization
Verification:
✅ NYASH_FEATURES=stage3 NYASH_USE_NY_COMPILER=1 \
./tools/selfhost/selfhost_build.sh --in apps/tests/stage1_run_min.hako --run
Output: abc (correct)
🤖 Generated with Claude Code
Co-Authored-By: Claude <noreply@anthropic.com >
2025-12-02 13:09:10 +09:00
8633224061
JoinIR/SSA/Stage-3: sync CURRENT_TASK and dev env
2025-12-01 11:10:46 +09:00
a3d5bacc55
Phase 30.1 & 73: Stage-3 features env and JoinIR flag cleanup
2025-11-30 14:30:28 +09:00
cf3908d438
deprecations: warn-once for nyash.toml (already wired) + child_env audit (spawns use helper); docs sweep to prefer and hako.toml in README.*; smokes: add Core‑Direct negative rc canaries (array oob set, map bad key) and verified quick/core core_direct suite green
2025-11-02 19:02:23 +09:00
9c67343420
Selfhost: EXE path switched to Program(JSON v0) → MIR(JSON) → ny-llvmc; BuildBox opts (structured via env/array) and Bridge v1 positive canary
...
- selfhost_build.sh: EXE now converts Stage‑B Program(JSON v0) to MIR(JSON) via --json-file + --program-json-to-mir, then feeds ny-llvmc
- BuildBox: accept minimal opts via env or simple array parsing (alias_table, require_mods)
- Add positive v1 bridge canary: canonicalize_method_size_on_array_vm.sh (quick)
2025-11-02 18:54:16 +09:00
cd67911dae
BuildBox: env alias/require minimal bundling; selfhost tool: add --mir and docs
...
- BuildBox.emit_program_json_v0: use BundleResolver via env (HAKO_BUNDLE_ALIAS_TABLE, HAKO_REQUIRE_MODS)
- selfhost_build.sh: add --mir to emit MIR(JSON); document HAKO_USE_BUILDBOX for emit-only path
2025-11-02 18:48:34 +09:00
0eeae54434
Selfhost: prefer BuildBox for emit-only (opt-in) and fix selfhost smokes root detection
...
- selfhost_build.sh: HAKO_USE_BUILDBOX=1 uses BuildBox.emit_program_json_v0 for emit-only paths
- Fix ROOT detection in selfhost and bridge negative smokes
- All selfhost smokes pass (opt-in)
2025-11-02 18:22:15 +09:00
2dcf5006c6
Selfhost build: add EXE path via ny-llvmc (tools) + smoke
...
- tools/selfhost/selfhost_build.sh: support --exe <out>, using LLVM harness (ny-llvmc)
- Add selfhost EXE canary (opt-in): selfhost_build_exe_return.sh
- Keep Stage‑B JSON emit for verification; EXE path currently parses original Hako source (80/20)
2025-11-02 18:16:11 +09:00
075257a948
Hybrid selfhost build (tools) + opt-in smokes
...
- Add tools/selfhost/selfhost_build.sh: Stage‑B emit(JSON v0) + optional Core‑Direct (in-proc) run
- Add tools/selfhost/README.md
- Add opt-in smokes: selfhost_build_return_vm, selfhost_build_binop_vm (SMOKES_ENABLE_SELFHOST=1)
This establishes the mixed selfhost route (Hakorune Stage‑B front), ready to expand toward full build.
2025-11-02 18:07:33 +09:00