usage message

Stephen Weeks MLton@sourcelight.com
Wed, 3 Jan 2001 11:37:41 -0800 (PST)


Here is what the new usage message will look like.  I decided to go ahead with
the -keep g, since it doesn't seem too useful to be able to decide independently
to keep the generated c or S.  I also changed -stop to use g as well.

usage: mlton [option ...] file.{cm|sml} [library ...]
    -contify {both|call|cont|none}  ?specify contify strategy
    -detect-overflow {true|false}   overflow checking on Int.{+,*,-}
    -Ddefine                        define symbolic constant
    -g                              produce executable with debug info
    -h heapSize[{k|m}]              specify fixed heap size used by executable
    -iinclude                       include a .h file in the C code
    -indentation n                  specify indentation level in ILs
    -inline n                       specify inlining threshold
    -Idir                           specify a dir to search for include files
    -keep {cps|g|il|o|sml}          save intermediate files
    -llibrary                       link with a library
    -Ldir                           specify a dir to search for libraries
    -native {true|false}            use native x86 code generation
    -native-commented n             ?level of comments
    -native-copy-prop {true|false}  ?enable/disable copy propagation
    -native-ieee-fp {true|false}    ?enable/disable strict IEEE floating-point
    -native-move-hoist {true|false} ?enable/disable move hoisting
    -native-optimize n              ?level of optimizations
    -native-split n                 ?split assembly files at ~n lines
    -no-polyvariance                don't use polyvariance
    -o file                         specify name of output file
    -p                              produce executable with profiling info
    -safe {true|false}              bounds checking on arrays and other checks
    -show-types                     print types in ILs
    -static                         produce a statically linked executable
    -stop {f|g|sml|o}               specify where to stop
    -use-basis-library {true|false} prefix the basis library onto the program
    -v                              be verbose about compiler passes

A couple of remaining unresolved questions.

1. Should we expose the C backend at all?

2. It is at present not possible with the native backend to resume with the
   results of a call to mlton -stop g.  The problem is that you need to feed a
   collection of .c and .S files to mlton.  Does this need to be fixed?  What
   is the right command line syntax (and usage message).