A Sound Static Analysis Approach to I/O API Migration
summary
Sprout automatically migrates C programs between I/O APIs and guarantees behavioral equivalence by synthesizing replacement code from API specs and program analysis. It uses flow-sensitive pointer analysis plus typestate inference to tag ~202 semantic variables per benchmark, builds API state machines, removes minimal code fragments, propagates removed file-descriptor effects, and fills sketches to compile. Evaluation on programs averaging ~10k LOC shows average migration time 154s and 38% average speedup; the technique also adapts to databases.
AI-written summary · about
chapters (11)
- 0:00I/O API migration research
- 1:02Legacy I/O APIs need updating
- 2:27API migration challenges
- 3:12Semantic types and behavioral equivalence
- 4:35State machines for correctness
- 5:38Complex control flows
- 6:21Program state interference analysis
- 7:25Intermediate state inference
- 9:13Synthesizing migrated program
- 10:39Evaluation and performance
- 11:48Q&A
related talks
01h 02mProgram Manipulation of C Code
07h 15mInternational Workshop on the State Of the Art in Program Analysis (SOAP)
55mIdentifying Common Code Smells (In C++)
15mAPIfix: Output-Oriented Program Synthesis for Combating Breaking Changes in Libraries
18mPlatform-Oriented Legacy Modernization
27mInfiltrating a Code Base: Moving Toward a Better C
02mAtomic Migration Patterns
01h 17mRefactoring the ROI of Software
