ARCH14.md (767B)
1 # ARCH14: Stack Spill Kind Tracking (Stage 2) 2 3 ## Goal 4 5 Preserve pointer vs scalar kind information across spills and reloads by 6 tracking kind for stack slots. 7 8 ## Scope 9 10 - Extend taint state with `tsStackKind :: IntMap RegKind`. 11 - Update stack store/load logic to propagate kind. 12 13 ## Kind Propagation Rules (Stage 2) 14 15 - Store to `[sp, #imm]`: record source register kind in stack kind map. 16 - Load from `[sp, #imm]`: restore kind from stack map; default Unknown. 17 - Any SP adjustment clears stack kind map (same as taint/provenance). 18 19 ## Address Checks 20 21 - Base/index checks remain pointer-aware using `RegKind` for registers. 22 23 ## Risks 24 25 - Stack offset tracking is approximate; incorrect SP adjustments can 26 lead to stale kinds. The existing SP-clear heuristic helps.