Selfhosting
Definition
For this project, true selfhosting means the compiler is capable of compiling its own Semantic source into the next compiler executable.
The intended proof is:
Stage 1 compiler
↓ compiles
msplc-selfhost.se
↓
Stage 2 compiler
↓ compiles the same source
msplc-selfhost.se
↓
Stage 3 compiler
A strong bootstrap check compares Stage 2 and Stage 3 behavior/artifacts under a deterministic build contract.
What does not count
The following may be useful during bootstrap engineering, but they are not the final selfhosting proof:
- embedding a previously compiled EXE into
.secomments or data; - extracting/replaying a seed executable;
- invoking Go/C/C++ as the hidden implementation of the Semantic compiler;
- replacing unsupported semantics with silent stubs.
Bootstrap stages
Why object-first debugging helps
The compiler is too large to treat every failure as a monolithic “EXE build failed”. COFF staging gives a finer-grained milestone:
- parse/index Semantic compiler modules;
- lower individual compiler units;
- emit valid object artifacts;
- resolve cross-unit symbols;
- link the compiler executable;
- use that executable for the next bootstrap stage.
Current status
The project has moved beyond a seed-only demonstration: real compiler .se units are being lowered into native objects. Full Stage 2 → Stage 3 selfhosting is still a work in progress and should not be claimed until the same Semantic compiler source can produce the next compiler end-to-end.