How dlang/dmd works
DMD is the reference compiler for the D language. The supplied tree contains compiler interface headers and a small selection of druntime support files, not the compiler’s implementation or executable entry point. The graph therefore focuses on the compiler’s language-model layers and the visible support components; it cannot establish a complete user-to-compiled-output flow. Edges reflect documented imports or explicit README statements, not inferred runtime calls.
Main entry points: dsymbol.h Symbols and scopes · expression.h Expressions · mtype.h Types · ast_node.h AST base
Components 20
Language model
- Tokens
compiler/include/dmd/tokens.h - Expressions
compiler/include/dmd/expression.h - Types
compiler/include/dmd/mtype.h - Statements
compiler/include/dmd/statement.h - Declarations
compiler/include/dmd/declaration.h - Aggregates
compiler/include/dmd/aggregate.h - Templates
compiler/include/dmd/template.h
Frontend structure
- DMD compiler
compiler/include/dmd - Symbols and scopes
compiler/include/dmd/dsymbol.h - AST base
compiler/include/dmd/ast_node.h - AST visitor
compiler/include/dmd/visitor.h
Compiler support
- Compiler configuration
compiler/include/dmd/globals.h - AST collections
compiler/include/dmd/arraytypes.h - Portability layer
compiler/include/dmd/root/port.h - Root arrays
compiler/include/dmd/root/array.h - Output buffer
compiler/include/dmd/common/outbuffer.h
Runtime support
- Valgrind requests
druntime/src/etc/valgrind/valgrind.h - Valgrind checks
druntime/src/etc/valgrind/memcheck.h - Valgrind C support
druntime/src/etc/valgrind/valgrind.c
Other components
- D developer
Connections 24
- D developer → DMD compiler: uses compiler
- DMD compiler → Tokens: defines tokens
compiler/include/dmd/expression.h - Expressions → AST base: derives from
compiler/include/dmd/expression.h - Expressions → Tokens: uses tokens
compiler/include/dmd/expression.h - Expressions → Types: references types
compiler/include/dmd/expression.h - Types → Expressions: references expressions
compiler/include/dmd/mtype.h - Types → AST base: uses AST base
compiler/include/dmd/mtype.h - Statements → AST base: uses AST base
compiler/include/dmd/statement.h - Statements → Symbols and scopes: references symbols
compiler/include/dmd/statement.h - Declarations → Symbols and scopes: uses symbols
compiler/include/dmd/declaration.h - Declarations → Types: references types
compiler/include/dmd/declaration.h - Symbols and scopes → AST base: uses AST base
compiler/include/dmd/dsymbol.h - Symbols and scopes → Compiler configuration: uses configuration
compiler/include/dmd/dsymbol.h - Symbols and scopes → AST collections: uses collections
compiler/include/dmd/dsymbol.h - Symbols and scopes → AST visitor: dispatches visitor
compiler/include/dmd/dsymbol.h - Aggregates → Symbols and scopes: uses symbols
compiler/include/dmd/aggregate.h - Templates → Symbols and scopes: uses symbols
compiler/include/dmd/template.h - Templates → Expressions: references expressions
compiler/include/dmd/template.h - AST collections → Root arrays: uses arrays
compiler/include/dmd/arraytypes.h - Compiler configuration → Output buffer: uses buffer
compiler/include/dmd/globals.h - Compiler configuration → Portability layer: uses portability
compiler/include/dmd/globals.h - Valgrind checks → Valgrind requests: includes requests
druntime/src/etc/valgrind/memcheck.h - Valgrind C support → Valgrind requests: uses requests
druntime/src/etc/valgrind/valgrind.c - Valgrind C support → Valgrind checks: uses checks
druntime/src/etc/valgrind/valgrind.c