Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] Annotation of /sml/branches/primop-branch/src/compiler/MAP
ViewVC logotype

Annotation of /sml/branches/primop-branch/src/compiler/MAP

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1775 - (view) (download)

1 : macqueen 1344 Front End
2 :     ---------
3 :    
4 :     1. Lexing and Parsing
5 : macqueen 1475 ----------------------
6 : macqueen 1344
7 : macqueen 1475 * syntax trees (AST) produced by parser
8 :     * lexical analysis (via ML-Lex spec)
9 :     * parsing (via ML-Yacc spec)
10 :    
11 : macqueen 1344 Parse/
12 :     lexing and parsing, producing ast (concrete syntax trees)
13 :    
14 : macqueen 1475 Parse/ast/
15 :     "syntax trees" (really concrete, in contrast to absyn, which is
16 :     the true abstract syntax)
17 :     ast.sig/sml
18 :     the syntax tree types
19 :     defs: AST, Ast: AST
20 :     astutil.sig/sml
21 :     some utility functions
22 :     defs: ASTUTIL, AstUtil: ASTUTIL
23 : macqueen 1344
24 : macqueen 1475 Parse/lex/
25 :     lexical analysis (via ML-Lex)
26 :     ml.lex
27 :     the lexer spec (ML-Lex source)
28 :     tokentable.sml
29 :     hash table for token recognition
30 :     defs: TokenTable
31 : macqueen 1344
32 : macqueen 1475 Parse/parse/
33 :     parsing (via ML-Yacc)
34 :     ml.grm
35 :     grammar spec (ML-Yacc source)
36 : macqueen 1344
37 : macqueen 1475 Parse/main/
38 :     control flags and parser driver functions.
39 :     lexer/parser combination translates input stream into ast trees
40 :     parser.sig/sml
41 :     parser modules initialization, driver function
42 :     defs: MLPARSER, MLParser: MLPARSER
43 :     parsercontrol.sml
44 :     flags controlling various syntax features
45 :     defs: PARSER_CONTROL, ParserControl
46 :     smlfile.sml
47 :     top level parsing functions
48 :     defs: SMLFILE, SmlFile
49 : macqueen 1344
50 :    
51 :     2. Elaboration
52 : macqueen 1475 --------------
53 : macqueen 1344
54 : macqueen 1475 * abstract syntax (absyn)
55 :     * static environments
56 :     * translation from ast to abstract syntax and static environment (elaboration)
57 :     * core type checking and inference, overloading resolution
58 :     * modules and signatures, signature matching, functor application
59 :     * code found in directories Semant, ElabData, Elaborator
60 : macqueen 1471
61 : macqueen 1475 Basics/
62 : macqueen 1471
63 : macqueen 1475 Basics/mlcomp/
64 :     some basic types involved in absyn and statenv and elaboration process
65 :     symbol.sig/sml
66 :     symbols (should be in ElabData)
67 :     defs: SYMBOL, Symbol
68 :     fastsymbol.sig/sml
69 :     fast symbols (should be in ElabData)
70 :     defs: FASTSYMBOL, FastSymbol
71 :     fixity.sml
72 :     fixity properties (should be in ElabData)
73 :     defs: FIXITY, Fixity
74 :     persstamps.sig/sml
75 :     persistant stamps, or globally unique identifiers (16 byte vectors),
76 :     aka "pids"
77 :     defs: PERSSTAMPS, PersStamps : PERSSTAMPS
78 :     persmap.sml
79 :     finite maps over pids (persistent stamps)
80 :     defs: PersMap
81 :     pidenv.sig/sml
82 :     environments using pids (persistant stamps) as keys
83 :     defs: PIDENV, PidEnvFn
84 :     compileexn.sml
85 :     Compile exception (where used?)
86 :     defs: CompileExn
87 : macqueen 1471
88 : macqueen 1475 Basics/miscutil/ (why not in MiscUtil?)
89 :     intstrmap.sig/sml
90 :     int/string maps for use in environments;
91 :     appears redundant with IntStrMapV defined in
92 :     Env (ElabData/basics/env.sml)
93 :     used in Tuples, ElabCore, Parse/lex/tokentable.sml.
94 :     see: ElabData/basics/env.sml
95 :     defs: INTSTRMAP, IntStrMap
96 : macqueen 1471
97 : macqueen 1475 Basics/errormsg/
98 :     errormsg.sig/sml
99 :     error messages
100 :     defs: ERRORMSG, ErrorMsg
101 : macqueen 1471
102 : macqueen 1475 Basics/source/
103 :     managing ML source files or streams
104 :     pathnames.sig/sml
105 :     file path names
106 :     defs: PATHNAMES, Pathnames
107 :     source.sig/sml
108 :     input source datastructure
109 :     defs: SOURCE, Source
110 :     sourcemap.sig/sml
111 :     map character positions in source to line no/column supporting #line "declaration"
112 :     defs: SOURCE_MAP, SourcMap
113 : macqueen 1471
114 : macqueen 1475 Basics/print/
115 :     utilities for prettyprinting
116 :     [pp-wrapper.sml -- obsolete for mcz, where new pp is used directly]
117 :     implements old PP interface using new SML/NJ Lib PP
118 :     pp-init.sml
119 :     extend standard prettyprinter interface to match old one
120 :     defs: PRETTYPRINT, PrettyPrint
121 :     printutil.sig/sml
122 :     some print utilities (uses Symbol)
123 :     defs: PRINTUTIL, PrintUtil
124 :     printcontrol.sml
125 :     print control flags, out, say
126 :     defs: PRINTCONTROL, Control_Print
127 : macqueen 1471
128 : macqueen 1475 Basics/stats/
129 :     stats.sml
130 :     facilities for defining timed phases
131 :     defs: STATS, Stats
132 : macqueen 1471
133 : macqueen 1475 Basics/main/
134 :     basiccontrol.sml
135 :     printWarning control flag, topregistry
136 :     uses: ControlRegistry, Controls
137 :     defs: BASIC_CONTROL, BasicControl
138 : macqueen 1471
139 : macqueen 1475 Semant/
140 :     Modules related to elaboration and pickling (external representation
141 :     of static environments)
142 : macqueen 1344
143 : macqueen 1475 Semant/basics/
144 :     inlinfo.sig/sml
145 :     inlining info [FLINT]
146 :     defs: INL_INFO, InlInfo: INL_INFO
147 : macqueen 1344
148 : macqueen 1475 Semant/elaborate/
149 :     apply functors defined in corresponding Elaborate/elaborate modules
150 :     [these could be in Elaborator]
151 :     elabmod.sml
152 :     module level elaboration (why not in Elaborator)
153 :     see: Elaborator/elaborate/elabmod.sml
154 :     defs: ElabMod
155 :     elabtop.sml
156 :     top-level elaboration
157 :     defs: ElabTop
158 : macqueen 1344
159 : macqueen 1475 Semant/modules/
160 :     support for module elaboration
161 :     evalent.sml
162 :     entity expression evaluation;
163 :     applies functor EvalEntityFn from Elaborator/modules/evalent.sml
164 :     see: Elaborator/modules/evalent.sml
165 :     defs: EvalEntity
166 :     instantiate.sml
167 :     apply InstantitateFn defined in Elaborator/modules/instantiate.sml
168 :     see: Elaborator/modules/instantiate.sml
169 :     defs: Instantiate
170 :     instantiate-param.sml
171 :     defines parameter passed to InstantiateFn in ./instantiate.sml
172 :     see: Semant/modules/instantiate.sml (previous file)
173 :     defs: InstantiateParam
174 :     module-plists.sml [FLINT]
175 :     defines PropList properties for attaching FLINT Lambda types to
176 :     various semantic entities
177 :     see: smlnj-lib/Util/plist{-sig}.sml
178 :     defs: ModulePropLists
179 :     sigmatch.sml
180 :     apply SigmatchFn defined in Elaborator/modules/sigmatch.sml
181 :     see: Elaborator/modules/sigmatch.sml
182 :     defs: SigMatch
183 : macqueen 1344
184 : macqueen 1475 Semant/pickle/
185 :     pickling static environments
186 :     pickle-sym-pid.sml
187 :     unpickle-sym-pid.sml
188 :     pickmod-new.sml
189 :     unpickmod-new-sml
190 :     rehash.sml
191 : macqueen 1344
192 : macqueen 1475 Semant/statenv/
193 :     prim.sml
194 :     define static env primEnv, containing primitive types (PrimTypes),
195 :     primops (InLine), and unrolled lists (UnrolledList)
196 :     defs: PRIM_ENV, PrimEnv: PRIM_ENV
197 : macqueen 1344
198 : macqueen 1475 Semant/types/
199 :     some types-related stuff
200 :     cproto.sml
201 :     relating ML types and C types (CTypes.c_proto from MLRISC) for C call mechanism
202 :     defs: CProto
203 :     tp-var-info.sml [FLINT]
204 :     packaging some FLINT info as an exception
205 :     defs: TVI
206 :     types-reformat.sml [FLINT]
207 :     FLINT-related "reformatting" of types, used to be in typesutil.sml
208 :     defs: TypesReformat
209 :     typecheck.sml [FLINT]
210 :     apply TypecheckFn defined in Elaborator/types/typecheck.sml (should eliminate)
211 :     see: Elaborator/types/typecheck.sml
212 : macqueen 1775 defs: Typecheck
213 : macqueen 1344
214 :    
215 : macqueen 1475 ElabData/
216 :     Basic datastructures used in elaboration (including type checking)
217 : macqueen 1344
218 : macqueen 1475 ElabData/basics/
219 :     basic representation types used in elaboration, plus coresym
220 :     lambdavar.sig/sml
221 :     lambda variables, the abstract representation of variables, used
222 :     as roots of dynamic access chains
223 :     defs: LAMBDA_VAR, LambdaVar
224 :     access.sig/sml
225 :     dynamic access paths
226 :     defs: ACCESS, Access : ACCESS
227 :     env.sig/sml
228 :     generic environments, mapping symbols to unspecified binding type
229 :     defs: ENV, Env: ENV, INTSTRMAPV
230 :     stamps.sig/sml
231 :     static identifiers, used for nominal type equivalence
232 :     defs: STAMPS, Stamps:> STAMPS
233 :     stampmap.sml
234 :     generic finite mappings over stamps
235 :     defs: StampMap
236 :     sympaths.sig/sml
237 :     SymPath and InvPath: direct and inverse symbolic paths (selecting
238 :     module components)
239 :     defs: SYMPATH, INVPATH, CONVERTPATHS, SymPath, InvPath, ConvertPaths
240 :     ii.sml [FLINT]
241 :     FLINT related information for inlining (why is this in elaborator?)
242 :     defs: II
243 :     core-ptnum.sml
244 :     core prim-type numbers (essentially the same as Elaborator/basics/ptnum.sml
245 :     except only language-standard types are included)
246 :     see: Elaborator/basics/ptnum.sml
247 :     defs: CORE_PRIM_TYC_NUM, CorePrimTycNum
248 :     coresym.sml
249 :     defines the special structure symbol "_Core" used to access certain
250 :     special bindings (e.g Match and Bind exceptions)
251 :     defs: CoreSym
252 : macqueen 1344
253 : macqueen 1475 ElabData/syntax/
254 :     (typed) abstract syntax
255 :     absyn.sig/sml
256 :     the abstract syntax types
257 :     defs: ABSYN, Absyn: ABSYN
258 :     varcon.sig/sml
259 :     variable and data constructor representations
260 :     defs: VARCON, VarCon: VARCON
261 :     absynutil.sml
262 :     utility functions for building tuple patterns and expressions
263 :     defs: AbsynUtil
264 : macqueen 1344
265 : macqueen 1475 ElabData/types/
266 :     representing, constructing and manipulating types
267 :     types.sig/sml
268 :     the representation of SML types
269 :     defs: TYPES, Types: TYPES
270 :     typesutil.sig/sml
271 :     large collection of utility functions for working with types
272 :     defs: TYPESUTIL, TypesUtil: TYPESUTIL
273 :     tuples.sml
274 :     fns for constructing tuple and record types
275 :     defs: TUPLES, Tuples: TUPLES
276 :     core-basictypes.sml
277 :     building the primitive types and associated values (containing only
278 :     implementation independent, language-standard basic types?)
279 :     see: Elaborator/types/basictypes.sml
280 :     defs: CoreBasicTypes
281 : macqueen 1344
282 : macqueen 1475 ElabData/statenv/
283 :     static environments
284 :     bindings.sig/sml
285 :     the basic binding forms (values, types, signatures, etc.)
286 :     defs: BINDINGS, Bindings: BINDINGS
287 :     statenv.sig/sml
288 :     instantiate generic environments with ML bindings
289 :     defs: STATICENV, StaticEnv: STATICENV
290 :     lookup.sig/sml
291 :     accessing symbols in environments
292 :     defs: LOOKUP, Lookup : LOOKUP
293 :     genmap.sml
294 :     rapid modmap generation based on modtrees
295 :     defs: GenModIdMap
296 :     coreacc.sml
297 :     access components of the _Core structure
298 :     defs: CoreAccess
299 :     browse.sml
300 :     "browsing" the static environment (not used???)
301 :     defs: BrowseStatEnv
302 : macqueen 1344
303 : macqueen 1475 ElabData/modules/
304 :     representation of modules
305 :     modules.sig/sml
306 :     representation of modules and signatures
307 :     defs: MODULES, Modules: MODULES
308 :     moduleutil.sig/sml
309 :     lots of utility functions for modules
310 :     defs: MODULEUTIL, ModuleUtil: MODULEUTIL
311 :     moduleid.sml
312 :     module identities used in Modmaps ???
313 :     defs: MODULE_ID, ModuleId: MODULE_ID
314 :     entpath.sml
315 :     access paths for navigating entities
316 :     defs: ENT_PATH, EntPath:> ENT_PATH
317 :     entityenv.sig/sml
318 :     enity environments mapping entity variables
319 :     defs: ENTITY_ENV, EntityEnv : ENTITY_ENV
320 :     epcontext.sml
321 :     hairy context info used during module elaboration,
322 :     related to nesting of modules (ep stands for
323 :     "entity path"?)
324 :     defs: ENT_PATH_CONTEXT, EntPathContext :> ENT_PATH_CONTEXT
325 : macqueen 1344
326 : macqueen 1475 ElabData/main/
327 :     compinfo.sml
328 :     elaboration context parameter
329 :     defs: CompInfo
330 :     edcontrol.sig/sml
331 :     control flags for ElabData
332 :     defs: ELABDATA_CONTROL, ElabDataControl : ELABDATA_CONTROL
333 : macqueen 1344
334 :    
335 : macqueen 1475 Elaborator/
336 :     The main elaborator code, plus some representation stuff in basics/,
337 :     plus printing modules in print/.
338 : macqueen 1344
339 : macqueen 1475 Elaborator/basics/
340 :     some control flags, some representation types, some FLINT stuff
341 :     elabcontrol.sml
342 :     Elaborator control flags
343 :     defs: ElabControl
344 :     conrep.sml
345 :     inferring conreps for data constructors
346 :     defs: CONREP, ConRep: CONREP
347 :     debindex.sig/sml [FLINT]
348 :     FLINT book-keeping (move back to FLINT)
349 :     defs: DEB_INDEX, DebIndex : DEB_INDEX
350 :     ptnum.sml
351 :     prim type numbers, augmenting ElabData/basics/core-ptnum.sml with
352 :     implementation dependent types
353 :     see: ElabData/basics/core-ptnum.sml
354 :     defs: PRIM_TYC_NUM, PrimTycNum: PRIM_TYC_NUM
355 : macqueen 1344
356 : macqueen 1475 Elaborator/print/ [should be in ElabData?]
357 :     print utilities and print modules for elaboration data structures
358 :     pputil.sig/sml
359 :     prettyprint utilities (generic) [**MOVE**]
360 :     pptype.sml
361 :     prettyprint types
362 :     ppval.sml
363 :     prettyprint variables and dcons
364 :     ppmod.sml
365 :     prettyprint modules and signatures
366 :     ppabsyn.sml
367 :     prettyprint absyn (uses PPUtil(pputil.s??),
368 :     PPVal(ppval.sml), PPType(pptype.sml))
369 : macqueen 1344
370 : macqueen 1475 Elaborator/types/
371 :     building basic types + typechecking modules
372 :     basictypes.sig/sml
373 :     define basic (built-in) types; most are just defined in terms of
374 :     types from CoreBasicTypes [MOVE to ElabData?]
375 :     see: ElabData/types/core-basictypes.sml
376 :     defs: BasicTypes
377 :     eqtypes.sml
378 :     equivalence of types
379 :     defs: EQTYPES, EqTypes: EQTYPES
380 :     unify.sml
381 :     type unification
382 :     defs: UNIFY, Unify: UNIFY
383 :     overloadlit.sml
384 :     overloaded numeric literals
385 :     defs: OVERLOADLIT, OverloadLit: OVERLOADLIT
386 :     overload.sml
387 :     overloading resolution
388 :     defs: OVERLOAD, Overload
389 :     typecheck.sml [FLINT]
390 :     defines typechecking _functor_ TypecheckFn, taking some FLINT-related
391 :     inlining info as parameters [should make into a structure]
392 :     defs: TYPECHECK, TypecheckFn: _ => TYPECHECK
393 : macqueen 1344
394 : macqueen 1475 Elaborator/modules/
395 :     support modules for elaborating modules
396 :     evalent.sml
397 :     evaluate "entities" (module and type realizations). Defines EvalEntityFn
398 :     which is called to define EvalEntity structure in Semant/modules/evalent.sml
399 :     see: Semant/modules/evalent.sml
400 :     defs: EVALENTITY, EvalEntityFn : INSTANTIATE => EVALENTITY
401 :     expandtycon.sml
402 :     interpret PATHtycs in entity environments
403 :     defs: EXPAND_TYCON, ExpandTycon : EXPAND_TYCON
404 :     instantiate.sml
405 :     free instantiation of signatures. defines InstantiateFn which is applied
406 :     to define structure Instantiate in Semant/modules/instantiate.sml
407 :     see: Semant/modules/instantiate.sml
408 :     defs: INSTANTIATE_PARAM, INSTANTIATE,
409 :     InstantiateFn: INSTANTIATE_PARAM => INSTANTIATE
410 :     sigmatch.sml
411 :     signature matching. defines SigMatchFn, which is applied to define
412 :     SigMatch structure in Semant/modules/sigmatch.sml
413 :     see: Semant/modules/sigmatch.sml
414 :     defs: SIGMATCH, SigMatchFn: EVALENTITY => SIGMATCH
415 : macqueen 1344
416 : macqueen 1475 Elaborator/elaborate/
417 :     main elaboration modules, plus some supporting modules
418 :     tyvarset.sml
419 :     type var sets for keeping track of implicit scopes of user type vars
420 :     defs: TYVARSET, TyvarSet :> TYVARSET
421 :     specialsyms.sml
422 :     definition of special symbols for internal use
423 :     defs: SpecialSymbols
424 :     elabutil.sig/sml
425 :     general utilities for elaboration
426 :     defs: ELABUTIL, ElabUtil : ELABUTIL
427 :     elabdebug.sml
428 :     debugging facilities for elaboration
429 :     defs: ELABDEBUG, ElabDebug : ELABDEBUG
430 :     precedence.sml
431 :     precedence parser for core expressions, dealing with infix operators
432 :     defs: PRECEDENCE, Precedence : PRECEDENCE
433 :     elabtype.sig/sml
434 :     elaboration of type expressions and declarations
435 :     defs: ELABTYPE, ElabType : ELABTYPE
436 :     elabcore.sml
437 :     elaborating core ML (expressions, declarations)
438 :     defs: ELABCORE, ElabCore: ELABCORE
439 :     elabmod.sml
440 :     main module elaboration. defines ElabModFn, which is called to
441 :     define ElabMod structure in Semant/elaborate/elabmod.sml
442 :     see: Semant/elaborate/elabmod.sml
443 :     defs: ELABMOD, ElabModFn: SIGMATCH # TYPECHECK => ELABMOD
444 :     include.sml
445 :     elaborate include specs in signatures (supports elabsig)
446 :     defs: INCLUDE, Include: INCLUDE
447 :     elabsig.sml
448 :     elaborate signatures
449 :     defs: ELABSIG, ElabSig : ELABSIG
450 :     elabtop.sml
451 :     top-level elaboration driver. defines ElabTopFn, which is called
452 :     to define ElabTop structure in Semant/elaborate/elabtop.sml
453 :     see: Semant/elaborate/elabtop.sml
454 :     defs: ELABTOP, ElabTopFn : ELABMOD => ELABTOP
455 : macqueen 1344
456 :    
457 :     3. Miscellaneous utilities
458 :    
459 :     MiscUtil/
460 :     Contains various kinds of utility programs
461 :    
462 :     bignums/
463 : macqueen 1475 supporting real constants (using bignums?)
464 :     ieeereal.sml
465 :     Support for IEEE floating-point constants. calls RealConst functor
466 :     see: MiscUtil/bignums/realconst.sml
467 :     defs: IEEERealConst
468 :     realconst.sml
469 :     generate ML real (i.e. ieee floating point?) constants
470 :     defs: PRIMREAL, REALCONST, RealConst: PRIMREAL => REALCONST
471 : macqueen 1344
472 :     library/
473 : macqueen 1475 Utility modules that are candidates for eventual
474 :     promotion to general libraries (crc and pickling)
475 :     crc.sml
476 :     crc codes
477 :     defs: CRC, CRC :> CRC
478 :     pickle-lib.cm
479 :     CM description for basic pickling/unpickling library
480 :     pickle-util.sml
481 :     supporting pickling
482 :     defs: PICKLE_UTIL, PickleUtil :> PICKLE_UTIL
483 :     unpickle-util.sml
484 :     supporting unpickling
485 :     defs: UNPICKLE_UTIL, UnpickleUtil :> UNPICKLE_UTIL
486 : macqueen 1344
487 :     print/
488 : macqueen 1475 Pretty printing for absyn declarations, values
489 :     ppdec.sml
490 :     printing results of top-level declarations, including values and types
491 :     defs: PPDEC, PPDec : PPDEC
492 :     ppobj.sml
493 :     print top-level values
494 :     defs: PPOBJ, PPObj : PPOBJ
495 :     pptable.sml
496 :     register for user-defined prettyprinters for datatypes
497 :     defs: PPTABLE, PPTable : PPTABLE
498 : macqueen 1344
499 :     util/
500 : macqueen 1475 A couple of miscellaneous leftovers.
501 :     feedback.sml
502 :     Compute minimum feedback vertex set of a given directed graph.
503 :     should be part of a graph library (move to ../library?)
504 :     defs: Feedback
505 :     literal-to-num.sml
506 :     Conversions from integer/word literals (which are represented as
507 :     arbitrary precision ints) to fixed size. a hack that should be
508 :     replaced by a parameterized numeric types.
509 :     size numbers
510 :     defs: LITERAL_TO_NUM, LiteralToNum : LITERAL_TO_NUM
511 : macqueen 1344
512 :    
513 : macqueen 1475 3. Middle End
514 :     -------------
515 : macqueen 1344
516 : macqueen 1475 FLINT/
517 :     intermediate representation (a form of typed lambda calculus)
518 : macqueen 1344
519 : macqueen 1475 [see FLINT/MAP]
520 : macqueen 1563 kernel/
521 :     primop.sig/sml
522 :     define datatypes representing primitive operations. some are true
523 :     primities, some are "inline", meaning that they expand into lambda
524 :     code sequences.
525 :     uses: Int
526 :     defs: PRIM_OP, PrimOp: PRIM_OP
527 : macqueen 1344
528 :    
529 : macqueen 1475 4. Back End
530 :     -----------
531 : macqueen 1344
532 : macqueen 1475 MLRISC/
533 :     MLRISC based code generators
534 : macqueen 1344
535 :    
536 : macqueen 1475 5. Execution Model
537 :     -----------------
538 : macqueen 1344
539 : macqueen 1475 Execution/
540 : macqueen 1344
541 : macqueen 1475 dynenv/
542 :     dynenv.sig,sml
543 :     dynamic environments, and instance of PidEnvFn
544 :     see: Basics/mlcomp/pidenv.sml
545 :     defs: DYNAMICENV, DynamicEnv : DYNAMICENV
546 :     codeobj/
547 :     code-obj.sig,sml
548 :     an interface for manipulating code objects
549 :     defs: CODE_OBJ, CodeObj :> CODE_OBJ
550 :     binfile/
551 :     binfile.sig,sml
552 :     file format for bin files (machine-independent)
553 :     defs: BINFILE, Binfile :> BINFILE
554 :     main/
555 :     importtree.sml
556 :     defs: ImportTree
557 :     isolate.sml
558 :     isolate the continuation context to the top-level (a prompt?)
559 :     defs: Isolate
560 :     execute.sml
561 :     execution of top-level executables in a dynamic environment
562 :     defs: Execute
563 : macqueen 1344
564 :    
565 : macqueen 1475 6. Interactive Top Level
566 :     ------------------------
567 : macqueen 1344
568 : macqueen 1475 TopLevel/
569 :    
570 :     environ/
571 :     combined static and dynamic environments
572 :     environ.sig,sml
573 :     defs: ENVIRONMENT, Environment: ENVIRONMENT
574 :     symenv.sig,sml
575 :     defines SYMENV as a specialization of PIDENV, and SymbolicEnv as
576 :     an instance of PidEnvFn.
577 :     see: Basics/mlcomp/pidenv.sig, Basics/mlcomp/pidenv.sml
578 :     defs: SYMENV, SymbolicEnv: SYMENV
579 :    
580 :     backend/
581 :     backend.sig
582 :     defs: BACKEND
583 :     backend-fn.sml
584 :     defs: BackendFn : CODEGENERATOR # {val cproto_conv : string} => BACKEND
585 :     alpha32.sml
586 :     defs: Alpha32Backend
587 :     hppa.sml
588 :     defs: HppaBackend
589 :     ppc.sml
590 :     defs: PPCBackend
591 :     sparc.sml
592 :     defs: SparcBackend
593 :     x86-ccall.sml
594 :     defs: X86CCallBackend
595 :     x86-stdcall.sml
596 :     defs: X86StdCallBackend
597 :    
598 :     interact/
599 :     envref.sml
600 :     supports top-level environment management
601 :     defs: ENVREF, EnvRef : ENVREF
602 :     evalloop.sig,sml
603 :     top-level read-eval-print loop
604 :     defs: EVALLOOP, EvalLoopF: TOP_COMPILE => EVALLOOP
605 :     interact.sig,sml
606 :     creating top-level loops
607 :     defs: INTERACT, Interact: EVALLOOP => INTERACT
608 :    
609 :     main/
610 :     control.sig
611 :     defs: MCCONTROL, FLINTCONTROL, CGCONTROL, CONTROL
612 :     control.sml
613 :     defs: Control_MC, Control_CG, Control
614 :     version.sml
615 :     defs: CompilerVersion
616 :     printhooks.sml
617 :     defs: PrintHooks
618 :     pptable.sml
619 :     defs: CompilerPPTable
620 :     code-generator.sig
621 :     defs: CODEGENERATOR
622 :     compile.sig
623 :     defs: COMPILE0, COMPILE0, TOP_COMPILE
624 :     compile.sml
625 :     defs: CompileF: CODEGENERATOR # CCONFIG # {cproto_conv : string} => COMPILE0
626 :    
627 :    
628 : macqueen 1563 7. System Build
629 :    
630 :     system/
631 : macqueen 1475
632 : macqueen 1563 system/init
633 :     built-in.sml
634 :     reassign more precise types to primops in structure Inline, producing a new
635 :     structure InLineT; most of these reassignments are redundant since PrimEnv
636 :     (Semant/statenv/prim.sml) now assigns exact types to most primops, but there
637 :     are a few primops (e.g. length) that have multiple types that are instances
638 :     of a more polymorphic type assigned in InLine.
639 :     defs: InlineT
640 :    
641 : macqueen 1475 ============================================================================
642 :    
643 :     Catalog of basic structures (Front End)
644 :     ---------------------------------------
645 :    
646 : macqueen 1344 symbols
647 : macqueen 1475 Symbol (Basics/mlcomp/symbol.sig,sml)
648 :     FastSymbol (Basics/mlcomp/fastsymbol.sig,sml)
649 : macqueen 1344
650 : macqueen 1475 symbolic paths
651 :     SymPath (ElabData/basics/sympaths.sml)
652 :     InvPath (ElabData/basics/sympaths.sml)
653 :     ConvertPaths (ElabData/basics/sympaths.sml)
654 : macqueen 1344
655 :     ast (syntax trees)
656 : macqueen 1475 Ast (Parse/ast/ast.sig,sml)
657 :     AstUtil (Parse/ast/astutil.sig,sml)
658 : macqueen 1344
659 :     absyn (abstract syntax)
660 : macqueen 1475 Absyn (ElabData/syntax/absyn.sig,sml)
661 :     abstract syntax datatypes for expressions, declarations, etc.
662 :     VarCon (ElabData/syntax/varcon.sig,sml)
663 :     variables and constructors
664 :     AbsynUtil (ElabData/syntax/absynutil.sml)
665 :     utility module for working with absyn
666 :     PPAbsyn (Elaborator/print/ppabsyn.sml)
667 :     prettyprinting absyn
668 : macqueen 1344
669 : macqueen 1475 types (internal representation of types)
670 :     representations
671 :     Types (ElabData/types/types.sig,sml)
672 :     ConRep (Elaborator/basics/conrep.sml)
673 : macqueen 1344
674 : macqueen 1475 utilities, manipulating and comparing types
675 :     TypesUtil (ElabData/types/typesutil.sig,sml)
676 :     Tuples (ElabData/types/tuples.sml)
677 :     EqTypes (Elaborator/types/eqtypes.sml)
678 :     Unify (Elaborator/types/unify.sml)
679 : macqueen 1344
680 : macqueen 1475 primitive types
681 :     CorePrimTycNum (ElabData/basics/core-ptnum.sml)
682 :     PrimTycNum (Elaborator/basics/ptnum.sml)
683 :     CoreBasicTypes (ElabData/types/core-basictypes.sml)
684 :     BasicTypes (Elaborator/types/basictypes.sig,sml)
685 :     PrimEnv (Semant/statenv/prim.sml)
686 :    
687 :     printing types
688 :     PPType (Elaborator/print/pptype.sml)
689 :    
690 :     dynamic access info
691 :     LambdaVar (ElabData/basics/lambdavar.sig,sml)
692 :     lambda variables (dynamic access roots for variables)
693 :     Access (ElabData/basics/access.sml)
694 :     dynamic access modes
695 :    
696 : macqueen 1344 environment (generic environment: 'b env)
697 : macqueen 1475 Env (ElabData/basics/env.sml)
698 : macqueen 1344
699 :     static environment
700 : macqueen 1475 Bindings (ElabData/statenv/bindings.sig,sml)
701 :     StaticEnv (ElabData/statenv/statenv.sml)
702 :     Lookup (ElabData/statenv/lookup.sml)
703 :     BrowseStatEnv (ElabData/statenv/browse.sml)
704 : macqueen 1344
705 :     modules (signatures, structures, functors)
706 : macqueen 1475 Modules (ElabData/modules/modules.sig,sml)
707 :     ModuleUtil (ElabData/modules/moduleutil.sig,sml)
708 :     ModuleId (ElabData/modules/moduleid.sml)
709 :     EntPath (ElabData/modules/entpath.sml)
710 :     EntityEnv (ElabData/modules/entityenv.sml)
711 :     ModulePropLists (Semant/modules/module-plists.sml) [FLINT]
712 : macqueen 1344
713 : macqueen 1475 primop
714 :     PrimOp (FLINT/kernel/primop.sml)
715 :     PrimEnv (Semant/statenv/prim.sml)
716 : macqueen 1344
717 :     control
718 : macqueen 1475 BasicControl (Basics/main/basiccontrol.sml)
719 :     ParserControl (Parse/main/parsercontrol.sml)
720 :     ElabDataControl (ElabData/main/edcontrol.sml)
721 :     ElabControl (Elaborator/basics/elabcontrol.sml)
722 :     Control_Print (Basics/print/printcontrol.sml)
723 :    
724 :     Control (TopLevel/main/control.sml)
725 :     Control_CG (TopLevel/main/control.sml)
726 :     Control_MC (TopLevel/main/control.sml)
727 :    
728 :    
729 :     ==========================================================================
730 :    
731 :     Notes
732 :     =====
733 :    
734 :     1. CoreBasicTypes/BasicTypes and CorePrimTycNum/PrimTycNum splits are
735 :     part of an attempt to have a subset of the front end modules that
736 :     can be used as a generic, implementation dependent SML front-end. That
737 :     is, CoreBasicTypes defines only those types that must be provided in
738 :     any SML implementation. BasicTypes adds those types that are specific
739 :     to SML/NJ.
740 :    
741 :    
742 :     2. What is the distinction between Basics and Semant? Should these be
743 :     merged? How about ElabData? Some of these files (Semant/types) might
744 :     also fit there.
745 :    
746 :     We have Basics/*, Semant/basics, ElabData/basics, and Elaborator/basics.
747 :     What is the rationale telling us what goes in each of these places?
748 :    
749 :     This complex organization seems to be partially motivated by the goal
750 :     of separating out any features that are SML/NJ-specific from the generic
751 :     SML stuff.

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0