🔧 Add sealed SSA mode for PHI debugging (ChatGPT5)

Added NYASH_LLVM_PHI_SEALED env var to toggle PHI wiring modes:
- NYASH_LLVM_PHI_SEALED=0 (default): immediate PHI wiring
- NYASH_LLVM_PHI_SEALED=1: sealed SSA style (wire after block completion)
- Added seal_block() function for deferred PHI incoming setup
- Enhanced PHI tracing with NYASH_LLVM_TRACE_PHI=1

This helps debug 'phi incoming value missing' errors by
comparing immediate vs sealed wiring approaches.
This commit is contained in:
Selfhosting Dev
2025-09-12 12:30:42 +09:00
parent 4fe1212d36
commit a28fcac368
3 changed files with 86 additions and 2 deletions

View File

@ -1,5 +1,5 @@
mod blocks;
mod flow;
pub mod flow;
mod externcall;
mod newbox;
mod boxcall;