| Lex + parse | ANTLR-generated SpiceLexer/SpiceParser (from src/Spice.g4) | Source → token stream → CST. See spice-language-feature skill. |
| CST → AST | src/ast/ — ASTBuilder | Builds the AST from the parser's CST |
| AST nodes / visitors | src/ast/ASTNodes.h, AbstractASTVisitor.h, ParallelizableASTVisitor.h, ASTVisitor.h | Node defs + visitor interfaces |
| Imports | src/importcollector/ — ImportCollector | Resolve & recursively load dependencies |
| Symbols | src/symboltablebuilder/ — SymbolTableBuilder, Scope, SymbolTable | Build scopes & symbol tables |
| Types | src/typechecker/ — TypeChecker (TC_MODE_PRE then TC_MODE_POST), QualType, Type | Type inference/checking, generic instantiation, overload resolution |
| IR gen | src/irgenerator/ — IRGenerator (a ParallelizableASTVisitor) | AST → LLVM IR |
| IR opt | src/iroptimizer/ — IROptimizer | LLVM pass pipeline (incl. LTO) |
| Emit | src/objectemitter/ — ObjectEmitter | LLVM module → object/asm |
| Link | src/linker/ — ExternalLinkerInterface | Object files → executable/library |
| CLI | src/driver/Driver.* — Driver, CliOptions | Subcommands & flags (see spice-run/spice-dump) |
| Errors | src/exception/, src/util/CompilerWarning.* | Diagnostics (see spice-diagnostics skill) |
| Visualizers | src/visualizer/ | CST/AST/dependency-graph dumps (the --dump-* flags) |
| Models | src/model/ | Cross-stage data (functions, structs, generics, …) |