+ desc=G.NoArg (fn () => Flag.set Flags.color),
+ help="pretty print the allocated regs"},
+ {short = "", long=["safe"],
+ desc=G.NoArg (fn () => Flag.set Flags.safe),
+ help="enable memory-safety"},
+ {short = "", long=["unsafe"],
+ desc=G.NoArg (fn () => Flag.unset Flags.safe),
+ help="disable memory-safety"},
+ {short = "", long = ["disable-all"],
+ desc=G.NoArg (fn () => enabledopts := nil),
+ help="disable all optimizations"}
+ ] @
+ map
+ (fn (opt : Optimizer.optimization) =>
+ { short = "", long=["disable-" ^ (#shortname opt)],
+ desc = G.NoArg (* This is nasty. *)
+ (fn () => enabledopts := List.filter (fn x => (#shortname x) <> (#shortname opt)) (!enabledopts)),
+ help = "disable optimization: " ^ (#description opt) })
+ uniqopts