Fix Trac #4841: behave right with TypeSynonymInstances and NoFlexibleInstances
[ghc-hetmet.git] / docs / users_guide / flags.xml
1 <?xml version="1.0" encoding="iso-8859-1"?>
2   <sect1 id="flag-reference">
3     <title>Flag reference</title>
4
5     <para>This section is a quick-reference for GHC's command-line
6     flags.  For each flag, we also list its static/dynamic status (see
7     <xref linkend="static-dynamic-flags"/>), and the flag's opposite
8     (if available).</para>
9
10     <sect2>
11       <title>Help and verbosity options</title>
12
13       <para><xref linkend="options-help"/></para>
14
15       <informaltable>
16         <tgroup cols="4" align="left" colsep="1" rowsep="1">
17           <thead>
18             <row>
19               <entry>Flag</entry>
20               <entry>Description</entry>
21               <entry>Static/Dynamic</entry>
22               <entry>Reverse</entry>
23             </row>
24           </thead>
25           <tbody>
26             <row>
27               <entry><option>-?</option></entry>
28               <entry>help</entry>
29               <entry>mode</entry>
30               <entry>-</entry>
31             </row>
32             <row>
33               <entry><option>-help</option></entry>
34               <entry>help</entry>
35               <entry>mode</entry>
36               <entry>-</entry>
37             </row>
38             <row>
39               <entry><option>-n</option></entry>
40               <entry>do a dry run</entry>
41               <entry>dynamic</entry>
42               <entry>-</entry>
43             </row>
44             <row>
45               <entry><option>-v</option></entry>
46               <entry>verbose mode (equivalent to <option>-v3</option>)</entry>
47               <entry>dynamic</entry>
48               <entry>-</entry>
49             </row>
50             <row>
51               <entry><option>-v</option><replaceable>n</replaceable></entry>
52               <entry>set verbosity level</entry>
53               <entry>dynamic</entry>
54               <entry>-</entry>
55             </row>
56             <row>
57               <entry><option>-V</option></entry>
58               <entry>display GHC version</entry>
59               <entry>mode</entry>
60               <entry>-</entry>
61             </row>
62             <row>
63               <entry><option>&ndash;&ndash;supported-extensions</option> or <option>&ndash;&ndash;supported-languages</option></entry>
64               <entry>display the supported languages and language extensions</entry>
65               <entry>mode</entry>
66               <entry>-</entry>
67             </row>
68             <row>
69               <entry><option>&ndash;&ndash;info</option></entry>
70               <entry>display information about the compiler</entry>
71               <entry>mode</entry>
72               <entry>-</entry>
73             </row>
74             <row>
75               <entry><option>&ndash;&ndash;version</option></entry>
76               <entry>display GHC version</entry>
77               <entry>mode</entry>
78               <entry>-</entry>
79             </row>
80             <row>
81               <entry><option>&ndash;&ndash;numeric-version</option></entry>
82               <entry>display GHC version (numeric only)</entry>
83               <entry>mode</entry>
84               <entry>-</entry>
85             </row>
86             <row>
87               <entry><option>&ndash;&ndash;print-libdir</option></entry>
88               <entry>display GHC library directory</entry>
89               <entry>mode</entry>
90               <entry>-</entry>
91             </row>
92             <row>
93               <entry><option>-ferror-spans</option></entry>
94               <entry>output full span in error messages</entry>
95               <entry>static</entry>
96               <entry>-</entry>
97             </row>
98             <row>
99               <entry><option>-H</option><replaceable>size</replaceable></entry>
100               <entry>Set the minimum heap size to <replaceable>size</replaceable></entry>
101               <entry>static</entry>
102               <entry>-</entry>
103             </row>
104             <row>
105               <entry><option>-Rghc-timing</option></entry>
106               <entry>Summarise timing stats for GHC (same as <literal>+RTS -tstderr</literal>)</entry>
107               <entry>static</entry>
108               <entry>-</entry>
109             </row>
110           </tbody>
111         </tgroup>
112       </informaltable>
113
114     </sect2>
115     <sect2>
116       <title>Which phases to run</title>
117       
118       <para><xref linkend="options-order"/></para>
119
120       <informaltable>
121         <tgroup cols="4" align="left" colsep="1" rowsep="1">
122           <thead>
123             <row>
124               <entry>Flag</entry>
125               <entry>Description</entry>
126               <entry>Static/Dynamic</entry>
127               <entry>Reverse</entry>
128             </row>
129           </thead>
130           <tbody>
131             <row>
132               <entry><option>-E</option></entry>
133               <entry>Stop after preprocessing (<literal>.hspp</literal> file)</entry>
134               <entry>mode</entry>
135               <entry>-</entry>
136             </row>
137             <row>
138               <entry><option>-C</option></entry>
139               <entry>Stop after generating C (<literal>.hc</literal> file)</entry>
140               <entry>mode</entry>
141               <entry>-</entry>
142             </row>
143             <row>
144               <entry><option>-S</option></entry>
145               <entry>Stop after generating assembly (<literal>.s</literal> file)</entry>
146               <entry>mode</entry>
147               <entry>-</entry>
148             </row>
149             <row>
150               <entry><option>-c</option></entry>
151               <entry>Do not link</entry>
152               <entry>dynamic</entry>
153               <entry>-</entry>
154             </row>
155             <row>
156               <entry><option>-x</option> <replaceable>suffix</replaceable></entry>
157               <entry>Override default behaviour for source files</entry>
158               <entry>static</entry>
159               <entry>-</entry>
160             </row>
161           </tbody>
162         </tgroup>
163       </informaltable>
164     </sect2>
165
166      <sect2>
167       <title>Alternative modes of operation</title>
168       
169       <para><xref linkend="modes"/></para>
170
171       <informaltable>
172         <tgroup cols="4" align="left" colsep="1" rowsep="1">
173           <thead>
174             <row>
175               <entry>Flag</entry>
176               <entry>Description</entry>
177               <entry>Static/Dynamic</entry>
178               <entry>Reverse</entry>
179             </row>
180           </thead>
181           <tbody>
182             <row>
183               <entry><option>--interactive</option></entry>
184               <entry>Interactive mode - normally used by just running <command>ghci</command>;
185               see <xref linkend="ghci"/> for details.</entry>
186               <entry>mode</entry>
187               <entry>-</entry>
188             </row>
189             <row>
190               <entry><option>--make</option></entry>
191               <entry>Build a multi-module Haskell program, automatically figuring out dependencies. Likely to be much easier, and faster, than using <command>make</command>;
192               see <xref linkend="make-mode"/> for details..</entry>
193               <entry>mode</entry>
194               <entry>-</entry>
195             </row>
196             <row>
197               <entry><option>-e <replaceable>expr</replaceable></option></entry>
198               <entry>Evaluate <replaceable>expr</replaceable>;
199               see <xref linkend="eval-mode"/> for details.</entry>
200               <entry>mode</entry>
201               <entry>-</entry>
202             </row>
203             <row>
204               <entry><option>-M</option></entry>
205               <entry>Generate dependency information suitable for use in a <filename>Makefile</filename>;
206               see <xref linkend="makefile-dependencies"/> for details.</entry>
207               <entry>mode</entry>
208               <entry>-</entry>
209             </row>
210           </tbody>
211         </tgroup>
212       </informaltable>
213     </sect2>
214
215     <sect2>
216       <title>Redirecting output</title>
217       
218       <para><xref linkend="options-output"/></para>
219
220       <informaltable>
221         <tgroup cols="4" align="left" colsep="1" rowsep="1">
222           <thead>
223             <row>
224               <entry>Flag</entry>
225               <entry>Description</entry>
226               <entry>Static/Dynamic</entry>
227               <entry>Reverse</entry>
228             </row>
229           </thead>
230           <tbody>
231             <row>
232               <entry><option>-hcsuf</option> <replaceable>suffix</replaceable></entry>
233               <entry>set the suffix to use for intermediate C files</entry>
234               <entry>dynamic</entry>
235               <entry>-</entry>
236             </row>
237             <row>
238               <entry><option>-hidir</option> <replaceable>dir</replaceable></entry>
239               <entry>set directory for interface files</entry>
240               <entry>dynamic</entry>
241               <entry>-</entry>
242             </row>
243             <row>
244               <entry><option>-hisuf</option> <replaceable>suffix</replaceable></entry>
245               <entry>set the suffix to use for interface files</entry>
246               <entry>dynamic</entry>
247               <entry>-</entry>
248             </row>
249             <row>
250               <entry><option>-o</option> <replaceable>filename</replaceable></entry>
251               <entry>set output filename</entry>
252               <entry>dynamic</entry>
253               <entry>-</entry>
254             </row>
255             <row>
256               <entry><option>-odir</option> <replaceable>dir</replaceable></entry>
257               <entry>set directory for object files</entry>
258               <entry>dynamic</entry>
259               <entry>-</entry>
260             </row>
261             <row>
262               <entry><option>-ohi</option> <replaceable>filename</replaceable></entry>
263               <entry>set the filename in which to put the interface</entry>
264               <entry>dynamic</entry>
265               <entry></entry>
266             </row>
267             <row>
268               <entry><option>-osuf</option> <replaceable>suffix</replaceable></entry>
269               <entry>set the output file suffix</entry>
270               <entry>dynamic</entry>
271               <entry>-</entry>
272             </row>
273             <row>
274               <entry><option>-stubdir</option> <replaceable>dir</replaceable></entry>
275               <entry>redirect FFi stub files</entry>
276               <entry>dynamic</entry>
277               <entry>-</entry>
278             </row>
279             <row>
280               <entry><option>-outputdir</option> <replaceable>dir</replaceable></entry>
281               <entry>set output directory</entry>
282               <entry>dynamic</entry>
283               <entry>-</entry>
284             </row>
285           </tbody>
286         </tgroup>
287       </informaltable>
288     </sect2>
289
290     <sect2>
291       <title>Keeping intermediate files</title>
292       
293       <para><xref linkend="keeping-intermediates"/></para>
294       
295       <informaltable>
296         <tgroup cols="4" align="left" colsep="1" rowsep="1">
297           <thead>
298             <row>
299               <entry>Flag</entry>
300               <entry>Description</entry>
301               <entry>Static/Dynamic</entry>
302               <entry>Reverse</entry>
303             </row>
304           </thead>
305           <tbody>
306             <row>
307               <entry><option>-keep-hc-file</option> or
308                  <option>-keep-hc-files</option></entry>
309               <entry>retain intermediate <literal>.hc</literal> files</entry>
310               <entry>dynamic</entry>
311               <entry>-</entry>
312             </row>
313             <row>
314               <entry><option>-keep-llvm-file</option> or
315                  <option>-keep-llvm-files</option></entry>
316               <entry>retain intermediate LLVM <literal>.ll</literal> files</entry>
317               <entry>dynamic</entry>
318               <entry>-</entry>
319             </row>
320             <row>
321               <entry><option>-keep-s-file</option> or
322                  <option>-keep-s-files</option></entry>
323               <entry>retain intermediate <literal>.s</literal> files</entry>
324               <entry>dynamic</entry>
325               <entry>-</entry>
326             </row>
327             <row>
328               <entry><option>-keep-raw-s-file</option> or
329                  <option>-keep-raw-s-files</option></entry>
330               <entry>retain intermediate <literal>.raw_s</literal> files</entry>
331               <entry>dynamic</entry>
332               <entry>-</entry>
333             </row>
334             <row>
335               <entry><option>-keep-tmp-files</option></entry>
336               <entry>retain all intermediate temporary files</entry>
337               <entry>dynamic</entry>
338               <entry>-</entry>
339             </row>
340           </tbody>
341         </tgroup>
342       </informaltable>
343     </sect2>
344
345     <sect2>
346       <title>Temporary files</title>
347       
348       <para><xref linkend="temp-files"/></para>
349
350       <informaltable>
351         <tgroup cols="4" align="left" colsep="1" rowsep="1">
352           <thead>
353             <row>
354               <entry>Flag</entry>
355               <entry>Description</entry>
356               <entry>Static/Dynamic</entry>
357               <entry>Reverse</entry>
358             </row>
359           </thead>
360           <tbody>
361             <row>
362               <entry><option>-tmpdir</option></entry>
363               <entry>set the directory for temporary files</entry>
364               <entry>dynamic</entry>
365               <entry>-</entry>
366             </row>
367           </tbody>
368         </tgroup>
369       </informaltable>
370     </sect2>
371
372     <sect2>
373       <title>Finding imports</title>
374
375       <para><xref linkend="search-path"/></para>
376
377       <informaltable>
378         <tgroup cols="4" align="left" colsep="1" rowsep="1">
379           <thead>
380             <row>
381               <entry>Flag</entry>
382
383               <entry>Description</entry>
384               <entry>Static/Dynamic</entry>
385               <entry>Reverse</entry>
386             </row>
387           </thead>
388           <tbody>
389             <row>
390               <entry><option>-i</option><replaceable>dir1</replaceable>:<replaceable>dir2</replaceable>:...</entry>
391               <entry>add <replaceable>dir</replaceable>,
392                   <replaceable>dir2</replaceable>, etc. to import path</entry>
393               <entry>static/<literal>:set</literal></entry>
394               <entry>-</entry>
395             </row>
396             <row>
397               <entry><option>-i</option></entry>
398               <entry>Empty the import directory list</entry>
399               <entry>static/<literal>:set</literal></entry>
400               <entry>-</entry>
401             </row>
402           </tbody>
403         </tgroup>
404       </informaltable>
405     </sect2>
406
407     <sect2>
408       <title>Interface file options</title>
409
410       <para><xref linkend="hi-options"/></para>
411
412       <informaltable>
413         <tgroup cols="4" align="left" colsep="1" rowsep="1">
414           <thead>
415             <row>
416               <entry>Flag</entry>
417
418               <entry>Description</entry>
419               <entry>Static/Dynamic</entry>
420               <entry>Reverse</entry>
421             </row>
422           </thead>
423           <tbody>
424             <row>
425               <entry><option>-ddump-hi</option></entry>
426               <entry>Dump the new interface to stdout</entry>
427               <entry>dynamic</entry>
428               <entry>-</entry>
429             </row>
430             <row>
431               <entry><option>-ddump-hi-diffs</option></entry>
432               <entry>Show the differences vs. the old interface</entry>
433               <entry>dynamic</entry>
434               <entry>-</entry>
435             </row>
436             <row>
437               <entry><option>-ddump-minimal-imports</option></entry>
438               <entry>Dump a minimal set of imports</entry>
439               <entry>dynamic</entry>
440               <entry>-</entry>
441             </row>
442             <row>
443               <entry><option>--show-iface</option> <replaceable>file</replaceable></entry>
444               <entry>See <xref linkend="modes"/>.</entry>
445             </row>
446           </tbody>
447         </tgroup>
448       </informaltable>
449     </sect2>
450     
451     <sect2>
452       <title>Recompilation checking</title>
453
454       <para><xref linkend="recomp"/></para>
455
456       <informaltable>
457         <tgroup cols="4" align="left" colsep="1" rowsep="1">
458           <thead>
459             <row>
460               <entry>Flag</entry>
461
462               <entry>Description</entry>
463               <entry>Static/Dynamic</entry>
464               <entry>Reverse</entry>
465             </row>
466           </thead>
467           <tbody>
468             <row>
469               <entry><option>-fforce-recomp</option></entry>
470               <entry>Turn off recompilation checking; implied by any
471               <option>-ddump-X</option> option</entry>
472               <entry>dynamic</entry>
473               <entry><option>-fno-force-recomp</option></entry>
474             </row>
475           </tbody>
476         </tgroup>
477       </informaltable>
478     </sect2>
479
480     <sect2 id="interactive-mode-options">
481       <title>Interactive-mode options</title>
482       
483       <para><xref linkend="ghci-dot-files"/></para>
484
485       <informaltable>
486         <tgroup cols="4" align="left" colsep="1" rowsep="1">
487           <thead>
488             <row>
489               <entry>Flag</entry>
490               <entry>Description</entry>
491               <entry>Static/Dynamic</entry>
492               <entry>Reverse</entry>
493             </row>
494           </thead>
495           <tbody>
496             <row>
497               <entry><option>-ignore-dot-ghci</option></entry>
498               <entry>Disable reading of <filename>.ghci</filename> files</entry>
499               <entry>static</entry>
500               <entry>-</entry>
501             </row>
502             <row>
503               <entry><option>-read-dot-ghci</option></entry>
504               <entry>Enable reading of <filename>.ghci</filename> files</entry>
505               <entry>static</entry>
506               <entry>-</entry>
507             </row>
508             <row>
509               <entry><option>-fbreak-on-exception</option></entry>
510               <entry><link linkend="ghci-debugger-exceptions">Break on any exception thrown</link></entry>
511               <entry>dynamic</entry>
512               <entry><option>-fno-break-on-exception</option></entry>
513             </row>
514             <row>
515               <entry><option>-fbreak-on-error</option></entry>
516               <entry><link linkend="ghci-debugger-exceptions">Break on uncaught exceptions and errors</link></entry>
517               <entry>dynamic</entry>
518               <entry><option>-fno-break-on-error</option></entry>
519             </row>
520             <row>
521               <entry><option>-fprint-evld-with-show</option></entry>
522               <entry><link linkend="breakpoints">Enable usage of Show instances in <literal>:print</literal></link></entry>
523               <entry>dynamic</entry>
524               <entry><option>-fno-print-evld-with-show</option></entry>
525             </row>          
526             <row>
527               <entry><option>-fprint-bind-result</option></entry>
528               <entry><link linkend="ghci-stmts">Turn on printing of binding results in GHCi</link></entry>
529               <entry>dynamic</entry>
530               <entry><option>-fno-print-bind-result</option></entry>
531             </row>
532             <row>
533               <entry><option>-fno-print-bind-contents</option></entry>
534               <entry><link linkend="breakpoints">Turn off printing of binding contents in GHCi</link></entry>
535               <entry>dynamic</entry>
536               <entry>-</entry>
537             </row>
538             <row>
539               <entry><option>-fno-implicit-import-qualified</option></entry>
540               <entry><link linkend="ghci-import-qualified">Turn off
541               implicit qualified import of everything in GHCi</link></entry>
542               <entry>dynamic</entry>
543               <entry>-</entry>
544             </row>
545
546           </tbody>
547         </tgroup>
548       </informaltable>
549     </sect2>
550
551     <sect2>
552       <title>Packages</title>
553
554       <para><xref linkend="packages"/></para>
555
556       <informaltable>
557         <tgroup cols="4" align="left" colsep="1" rowsep="1">
558           <thead>
559             <row>
560               <entry>Flag</entry>
561               <entry>Description</entry>
562               <entry>Static/Dynamic</entry>
563               <entry>Reverse</entry>
564             </row>
565           </thead>
566           <tbody>
567             <row>
568               <entry><option>-package-name</option> <replaceable>P</replaceable></entry>
569               <entry>Compile to be part of package <replaceable>P</replaceable></entry>
570               <entry>dynamic</entry>
571               <entry>-</entry>
572             </row>
573             <row>
574               <entry><option>-package</option> <replaceable>P</replaceable></entry>
575               <entry>Expose package <replaceable>P</replaceable></entry>
576               <entry>static/<literal>:set</literal></entry>
577               <entry>-</entry>
578             </row>
579             <row>
580               <entry><option>-hide-all-packages</option></entry>
581               <entry>Hide all packages by default</entry>
582               <entry>static</entry>
583               <entry>-</entry>
584             </row>
585             <row>
586               <entry><option>-hide-package</option> <replaceable>name</replaceable></entry>
587               <entry>Hide package <replaceable>P</replaceable></entry>
588               <entry>static/<literal>:set</literal></entry>
589               <entry>-</entry>
590             </row>
591             <row>
592               <entry><option>-ignore-package</option> <replaceable>name</replaceable></entry>
593               <entry>Ignore package <replaceable>P</replaceable></entry>
594               <entry>static/<literal>:set</literal></entry>
595               <entry>-</entry>
596             </row>
597             <row>
598               <entry><option>-package-conf</option> <replaceable>file</replaceable></entry>
599               <entry>Load more packages from <replaceable>file</replaceable></entry>
600               <entry>static</entry>
601               <entry>-</entry>
602             </row>
603             <row>
604               <entry><option>-no-user-package-conf</option></entry>
605               <entry>Don't load the user's package config file.</entry>
606               <entry>static</entry>
607               <entry>-</entry>
608             </row>
609             <row>
610               <entry><option>-no-auto-link-packages</option></entry>
611               <entry>Don't automatically link in the haskell98 package.</entry>
612               <entry>dynamic</entry>
613               <entry>-</entry>
614             </row>
615           </tbody>
616         </tgroup>
617       </informaltable>
618     </sect2>
619
620     <sect2>
621       <title>Language options</title>
622
623       <para>Language options can be enabled either by a command-line option 
624       <option>-Xblah</option>, or by a <literal>{-# LANGUAGE blah #-}</literal>
625       pragma in the file itself.  See <xref linkend="options-language"/></para>
626
627       <informaltable>
628         <tgroup cols="4" align="left" colsep="1" rowsep="1">
629           <thead>
630             <row>
631               <entry>Flag</entry>
632               <entry>Description</entry>
633               <entry>Static/Dynamic</entry>
634               <entry>Reverse</entry>
635             </row>
636           </thead>
637           <tbody>
638             <row>
639               <entry><option>-fglasgow-exts</option></entry>
640               <entry>Enable most language extensions</entry>
641               <entry>dynamic</entry>
642               <entry><option>-fno-glasgow-exts</option></entry>
643             </row>
644             <row>
645               <entry><option>-XOverlappingInstances</option></entry>
646               <entry>Enable <link linkend="instance-overlap">overlapping instances</link></entry>
647               <entry>dynamic</entry>
648               <entry><option>-XNoOverlappingInstances</option></entry>
649             </row>
650             <row>
651               <entry><option>-XIncoherentInstances</option></entry>
652               <entry>Enable <link linkend="instance-overlap">incoherent instances</link>.  
653               Implies <option>-XOverlappingInstances</option> </entry>
654               <entry>dynamic</entry>
655               <entry><option>-XNoIncoherentInstances</option></entry>
656             </row>
657             <row>
658               <entry><option>-XUndecidableInstances</option></entry>
659               <entry>Enable <link linkend="undecidable-instances">undecidable instances</link></entry>
660               <entry>dynamic</entry>
661               <entry><option>-XNoUndecidableInstances</option></entry>
662             </row>
663             <row>
664               <entry><option>-fcontext-stack=N</option><replaceable>n</replaceable></entry>
665               <entry>set the <link linkend="undecidable-instances">limit for context reduction</link>. Default is 20.</entry>
666               <entry>dynamic</entry>
667               <entry></entry>
668             </row>
669             <row>
670               <entry><option>-XArrows</option></entry>
671               <entry>Enable <link linkend="arrow-notation">arrow
672               notation</link> extension</entry>
673               <entry>dynamic</entry>
674               <entry><option>-XNoArrows</option></entry>
675             </row>
676             <row>
677               <entry><option>-XDisambiguateRecordFields</option></entry>
678               <entry>Enable <link linkend="disambiguate-fields">record 
679               field disambiguation</link></entry>
680               <entry>dynamic</entry>
681               <entry><option>-XNoDisambiguateRecordFields</option></entry>
682             </row>
683             <row>
684               <entry><option>-XForeignFunctionInterface</option></entry>
685               <entry>Enable <link linkend="ffi">foreign function interface</link> (implied by
686               <option>-fglasgow-exts</option>)</entry>
687               <entry>dynamic</entry>
688               <entry><option>-XNoForeignFunctionInterface</option></entry>
689             </row>
690             <row>
691               <entry><option>-XGenerics</option></entry>
692               <entry>Enable <link linkend="generic-classes">generic classes</link></entry>
693               <entry>dynamic</entry>
694               <entry><option>-XNoGenerics</option></entry>
695             </row>
696             <row>
697               <entry><option>-XImplicitParams</option></entry>
698               <entry>Enable <link linkend="implicit-parameters">Implicit Parameters</link>.
699               Implied by <option>-fglasgow-exts</option>.</entry>
700               <entry>dynamic</entry>
701               <entry><option>-XNoImplicitParams</option></entry>
702             </row>
703             <row>
704               <entry><option>-firrefutable-tuples</option></entry>
705               <entry>Make tuple pattern matching irrefutable</entry>
706               <entry>dynamic</entry>
707               <entry><option>-fno-irrefutable-tuples</option></entry>
708             </row>
709             <row>
710               <entry><option>-XNoImplicitPrelude</option></entry>
711               <entry>Don't implicitly <literal>import Prelude</literal></entry>
712               <entry>dynamic</entry>
713               <entry><option>-XImplicitPrelude</option></entry>
714             </row>
715             <row>
716               <entry><option>-XRebindableSyntax</option></entry>
717               <entry>Employ <link linkend="rebindable-syntax">rebindable syntax</link></entry>
718               <entry>dynamic</entry>
719               <entry><option>-XNoRebindableSyntax</option></entry>
720             </row>
721             <row>
722               <entry><option>-XNoMonomorphismRestriction</option></entry>
723               <entry>Disable the <link linkend="monomorphism">monomorphism restriction</link></entry>
724               <entry>dynamic</entry>
725               <entry><option>-XMonomorphismRrestriction</option></entry>
726             </row>
727             <row>
728               <entry><option>-XNoNPlusKPatterns</option></entry>
729               <entry>Disable support for <literal>n+k</literal> patterns</entry>
730               <entry>dynamic</entry>
731               <entry><option>-XNPlusKPatterns</option></entry>
732             </row>
733             <row>
734               <entry><option>-XNoMonoPatBinds</option></entry>
735               <entry>Make <link linkend="monomorphism">pattern bindings polymorphic</link></entry>
736               <entry>dynamic</entry>
737               <entry><option>-XMonoPatBinds</option></entry>
738             </row>
739             <row>
740               <entry><option>-XRelaxedPolyRec</option></entry>
741               <entry>Relaxed checking for <link linkend="typing-binds">mutually-recursive polymorphic functions</link></entry>
742               <entry>dynamic</entry>
743               <entry><option>-XNoRelaxedPolyRec</option></entry>
744             </row>
745             <row>
746               <entry><option>-XExtendedDefaultRules</option></entry>
747               <entry>Use GHCi's <link linkend="extended-default-rules">extended default rules</link> in a normal module</entry>
748               <entry>dynamic</entry>
749               <entry><option>-XNoExtendedDefaultRules</option></entry>
750             </row>
751             <row>
752               <entry><option>-XOverloadedStrings</option></entry>
753               <entry>Enable <link linkend="overloaded-strings">overloaded string literals</link>.
754               </entry>
755               <entry>dynamic</entry>
756               <entry><option>-XNoOverloadedStrings</option></entry>
757             </row>
758             <row>
759               <entry><option>-XGADTs</option></entry>
760               <entry>Enable <link linkend="gadt">generalised algebraic data types</link>.
761               </entry>
762               <entry>dynamic</entry>
763               <entry><option>-XNoGADTs</option></entry>
764             </row>
765             <row>
766               <entry><option>-XTypeFamilies</option></entry>
767               <entry>Enable <link linkend="type-families">type families</link>.</entry>
768               <entry>dynamic</entry>
769               <entry><option>-XNoTypeFamilies</option></entry>
770             </row>
771             <row>
772               <entry><option>-XScopedTypeVariables</option></entry>
773               <entry>Enable <link linkend="scoped-type-variables">lexically-scoped type variables</link>.
774               Implied by <option>-fglasgow-exts</option>.</entry>
775               <entry>dynamic</entry>
776               <entry><option>-XNoScopedTypeVariables</option></entry>
777             </row>
778             <row>
779               <entry><option>-XMonoLocalBinds</option></entry>
780               <entry>Enable <link linkend="mono-local-binds">do not generalise local bindings</link>.
781               </entry>
782               <entry>dynamic</entry>
783               <entry><option>-XNoMonoLocalBinds</option></entry>
784             </row>
785             <row>
786               <entry><option>-XTemplateHaskell</option></entry>
787               <entry>Enable <link linkend="template-haskell">Template Haskell</link>. 
788                 No longer implied by <option>-fglasgow-exts</option>.</entry>
789               <entry>dynamic</entry>
790               <entry><option>-XNoTemplateHaskell</option></entry>
791             </row>
792             <row>
793               <entry><option>-XQuasiQuotes</option></entry>
794               <entry>Enable <link linkend="th-quasiquotation">quasiquotation</link>.</entry>
795               <entry>dynamic</entry>
796               <entry><option>-XNoQuasiQuotes</option></entry>
797             </row>
798             <row>
799               <entry><option>-XBangPatterns</option></entry>
800               <entry>Enable <link linkend="bang-patterns">bang patterns</link>.</entry>
801               <entry>dynamic</entry>
802               <entry><option>-XNoBangPatterns</option></entry>
803             </row>
804             <row>
805               <entry><option>-XCPP</option></entry>
806               <entry>Enable the <link linkend="c-pre-processor">C preprocessor</link>.</entry>
807               <entry>dynamic</entry>
808               <entry><option>-XNoCPP</option></entry>
809             </row>
810             <row>
811               <entry><option>-XPatternGuards</option></entry>
812               <entry>Enable <link linkend="pattern-guards">pattern guards</link>.</entry>
813               <entry>dynamic</entry>
814               <entry><option>-XNoPatternGuards</option></entry>
815             </row>
816             <row>
817               <entry><option>-XViewPatterns</option></entry>
818               <entry>Enable <link linkend="view-patterns">view patterns</link>.</entry>
819               <entry>dynamic</entry>
820               <entry><option>-XNoViewPatterns</option></entry>
821             </row>
822             <row>
823               <entry><option>-XUnicodeSyntax</option></entry>
824               <entry>Enable <link linkend="unicode-syntax">unicode syntax</link>.</entry>
825               <entry>dynamic</entry>
826               <entry><option>-XNoUnicodeSyntax</option></entry>
827             </row>
828             <row>
829               <entry><option>-XMagicHash</option></entry>
830               <entry>Allow "#" as a <link linkend="magic-hash">postfix modifier on identifiers</link>.</entry>
831               <entry>dynamic</entry>
832               <entry><option>-XNoMagicHash</option></entry>
833             </row>
834             <row>
835               <entry><option>-XExplicitForALl</option></entry>
836               <entry>Enable <link linkend="explicit-foralls">explicit universal quantification</link>.
837               Implied by <option>-XScopedTypeVariables</option>,
838             <option>-XLiberalTypeSynonyms</option>,
839             <option>-XRank2Types</option>,
840             <option>-XRankNTypes</option>,
841             <option>-XPolymorphicComponents</option>,
842             <option>-XExistentialQuantification</option>
843               </entry>
844               <entry>dynamic</entry>
845               <entry><option>-XNoExplicitForAll</option></entry>
846             </row>
847             <row>
848               <entry><option>-XPolymorphicComponents</option></entry>
849               <entry>Enable <link linkend="universal-quantification">polymorphic components for data constructors</link>.</entry>
850               <entry>dynamic</entry>
851               <entry><option>-XNoPolymorphicComponents</option></entry>
852             </row>
853             <row>
854               <entry><option>-XRank2Types</option></entry>
855               <entry>Enable <link linkend="universal-quantification">rank-2 types</link>.</entry>
856               <entry>dynamic</entry>
857               <entry><option>-XNoRank2Types</option></entry>
858             </row>
859             <row>
860               <entry><option>-XRankNTypes</option></entry>
861               <entry>Enable <link linkend="universal-quantification">rank-N types</link>.</entry>
862               <entry>dynamic</entry>
863               <entry><option>-XNoRankNTypes</option></entry>
864             </row>
865             <row>
866               <entry><option>-XImpredicativeTypes</option></entry>
867               <entry>Enable <link linkend="impredicative-polymorphism">impredicative types</link>.</entry>
868               <entry>dynamic</entry>
869               <entry><option>-XNoImpredicativeTypes</option></entry>
870             </row>
871             <row>
872               <entry><option>-XExistentialQuantification</option></entry>
873               <entry>Enable <link linkend="existential-quantification">existential quantification</link>.</entry>
874               <entry>dynamic</entry>
875               <entry><option>-XNoExistentialQuantification</option></entry>
876             </row>
877             <row>
878               <entry><option>-XKindSignatures</option></entry>
879               <entry>Enable <link linkend="kinding">kind signatures</link>.</entry>
880               <entry>dynamic</entry>
881               <entry><option>-XNoKindSignatures</option></entry>
882             </row>
883             <row>
884               <entry><option>-XEmptyDataDecls</option></entry>
885               <entry>Enable empty data declarations.</entry>
886               <entry>dynamic</entry>
887               <entry><option>-XNoEmptyDataDecls</option></entry>
888             </row>
889             <row>
890               <entry><option>-XParallelListComp</option></entry>
891               <entry>Enable <link linkend="parallel-list-comprehensions">parallel list comprehensions</link>.</entry>
892               <entry>dynamic</entry>
893               <entry><option>-XNoParallelListComp</option></entry>
894             </row>
895             <row>
896               <entry><option>-XTransformListComp</option></entry>
897               <entry>Enable <link linkend="generalised-list-comprehensions">generalised list comprehensions</link>.</entry>
898               <entry>dynamic</entry>
899               <entry><option>-XNoTransformListComp</option></entry>
900             </row>
901             <row>
902               <entry><option>-XUnliftedFFITypes</option></entry>
903               <entry>Enable unlifted FFI types.</entry>
904               <entry>dynamic</entry>
905               <entry><option>-XNoUnliftedFFITypes</option></entry>
906             </row>
907             <row>
908               <entry><option>-XLiberalTypeSynonyms</option></entry>
909               <entry>Enable <link linkend="type-synonyms">liberalised type synonyms</link>.</entry>
910               <entry>dynamic</entry>
911               <entry><option>-XNoLiberalTypeSynonyms</option></entry>
912             </row>
913             <row>
914               <entry><option>-XTypeOperators</option></entry>
915               <entry>Enable type operators.</entry>
916               <entry>dynamic</entry>
917               <entry><option>-XNoTypeOperators</option></entry>
918             </row>
919             <row>
920               <entry><option>-XDoRec</option></entry>
921               <entry>Enable <link linkend="recursive-do-notation">recursive do notation</link>.</entry>
922               <entry>dynamic</entry>
923               <entry><option>-XNoDoRec</option></entry>
924             </row>
925             <row>
926               <entry><option>-XRecursiveDo</option></entry>
927               <entry>Enable <link linkend="mdo-notation">recursive do (mdo) notation</link>. This is deprecated; please use <link linkend="recursive-do-notation">recursive do notation</link> instead.</entry>
928               <entry>dynamic</entry>
929               <entry><option>-XNoRecursiveDo</option></entry>
930             </row>
931             <row>
932               <entry><option>-XPArr</option></entry>
933               <entry>Enable parallel arrays.</entry>
934               <entry>dynamic</entry>
935               <entry><option>-XNoPArr</option></entry>
936             </row>
937             <row>
938               <entry><option>-XRecordWildCards</option></entry>
939               <entry>Enable <link linkend="record-wildcards">record wildcards</link>.</entry>
940               <entry>dynamic</entry>
941               <entry><option>-XNoRecordWildCards</option></entry>
942             </row>
943             <row>
944               <entry><option>-XNamedFieldPuns</option></entry>
945               <entry>Enable <link linkend="record-puns">record puns</link>.</entry>
946               <entry>dynamic</entry>
947               <entry><option>-XNoNamedFieldPuns</option></entry>
948             </row>
949             <row>
950               <entry><option>-XDisambiguateRecordFields</option></entry>
951               <entry>Enable  <link linkend="disambiguate-fields">record field disambiguation</link>. </entry>
952               <entry>dynamic</entry>
953               <entry><option>-XNoDisambiguateRecordFields</option></entry>
954             </row>
955             <row>
956               <entry><option>-XUnboxedTuples</option></entry>
957               <entry>Enable <link linkend="unboxed-tuples">unboxed tuples</link>.</entry>
958               <entry>dynamic</entry>
959               <entry><option>-XNoUnboxedTuples</option></entry>
960             </row>
961             <row>
962               <entry><option>-XStandaloneDeriving</option></entry>
963               <entry>Enable <link linkend="stand-alone-deriving">standalone deriving</link>.</entry>
964               <entry>dynamic</entry>
965               <entry><option>-XNoStandaloneDeriving</option></entry>
966             </row>
967             <row>
968               <entry><option>-XDeriveDataTypeable</option></entry>
969               <entry>Enable <link linkend="deriving-typeable">deriving for the Data and Typeable classes</link>.</entry>
970               <entry>dynamic</entry>
971               <entry><option>-XNoDeriveDataTypeable</option></entry>
972             </row>
973             <row>
974               <entry><option>-XGeneralizedNewtypeDeriving</option></entry>
975               <entry>Enable <link linkend="newtype-deriving">newtype deriving</link>.</entry>
976               <entry>dynamic</entry>
977               <entry><option>-XNoGeneralizedNewtypeDeriving</option></entry>
978             </row>
979             <row>
980               <entry><option>-XTypeSynonymInstances</option></entry>
981               <entry>Enable <link linkend="flexible-instance-head">type synonyms in instance heads</link>.</entry>
982               <entry>dynamic</entry>
983               <entry><option>-XNoTypeSynonymInstances</option></entry>
984             </row>
985             <row>
986               <entry><option>-XFlexibleContexts</option></entry>
987               <entry>Enable <link linkend="flexible-contexts">flexible contexts</link>.</entry>
988               <entry>dynamic</entry>
989               <entry><option>-XNoFlexibleContexts</option></entry>
990             </row>
991             <row>
992               <entry><option>-XFlexibleInstances</option></entry>
993               <entry>Enable <link linkend="instance-rules">flexible instances</link>.
994               Implies <option>-XTypeSynonymInstances</option> </entry>
995               <entry>dynamic</entry>
996               <entry><option>-XNoFlexibleInstances</option></entry>
997             </row>
998             <row>
999               <entry><option>-XConstrainedClassMethods</option></entry>
1000               <entry>Enable <link linkend="class-method-types">constrained class methods</link>.</entry>
1001               <entry>dynamic</entry>
1002               <entry><option>-XNoConstrainedClassMethods</option></entry>
1003             </row>
1004             <row>
1005               <entry><option>-XMultiParamTypeClasses</option></entry>
1006               <entry>Enable <link linkend="multi-param-type-classes">multi parameter type classes</link>.</entry>
1007               <entry>dynamic</entry>
1008               <entry><option>-XNoMultiParamTypeClasses</option></entry>
1009             </row>
1010             <row>
1011               <entry><option>-XFunctionalDependencies</option></entry>
1012               <entry>Enable <link linkend="functional-dependencies">functional dependencies</link>.</entry>
1013               <entry>dynamic</entry>
1014               <entry><option>-XNoFunctionalDependencies</option></entry>
1015             </row>
1016             <row>
1017               <entry><option>-XPackageImports</option></entry>
1018               <entry>Enable <link linkend="package-imports">package-qualified imports</link>.</entry>
1019               <entry>dynamic</entry>
1020               <entry><option>-XNoPackageImports</option></entry>
1021             </row>
1022           </tbody>
1023         </tgroup>
1024       </informaltable>
1025     </sect2>
1026
1027     <sect2>
1028       <title>Warnings</title>
1029       
1030       <para><xref linkend="options-sanity"/></para>
1031
1032     <informaltable>
1033       <tgroup cols="4" align="left" colsep="1" rowsep="1">
1034         <thead>
1035           <row>
1036             <entry>Flag</entry>
1037             <entry>Description</entry>
1038             <entry>Static/Dynamic</entry>
1039             <entry>Reverse</entry>
1040           </row>
1041         </thead>
1042         <tbody>
1043           <row>
1044             <entry><option>-W</option></entry>
1045             <entry>enable normal warnings</entry>
1046             <entry>dynamic</entry>
1047             <entry><option>-w</option></entry>
1048           </row>
1049           <row>
1050             <entry><option>-w</option></entry>
1051             <entry>disable all warnings</entry>
1052             <entry>dynamic</entry>
1053             <entry>-</entry>
1054           </row>
1055           <row>
1056             <entry><option>-Wall</option></entry>
1057             <entry>enable almost all warnings (details in <xref linkend="options-sanity"/>)</entry>
1058             <entry>dynamic</entry>
1059             <entry><option>-w</option></entry>
1060           </row>
1061           <row>
1062             <entry><option>-Werror</option></entry>
1063             <entry>make warnings fatal</entry>
1064             <entry>dynamic</entry>
1065             <entry>-Wwarn</entry>
1066           </row>
1067           <row>
1068             <entry><option>-Wwarn</option></entry>
1069             <entry>make warnings non-fatal</entry>
1070             <entry>dynamic</entry>
1071             <entry>-Werror</entry>
1072           </row>
1073
1074           <row>
1075             <entry><option>-fwarn-unrecognised-pragmas</option></entry>
1076             <entry>warn about uses of pragmas that GHC doesn't recognise</entry>
1077             <entry>dynamic</entry>
1078             <entry><option>-fno-warn-unrecognised-pragmas</option></entry>
1079           </row>
1080
1081           <row>
1082             <entry><option>-fwarn-warnings-deprecations</option></entry>
1083             <entry>warn about uses of functions &amp; types that have warnings or deprecated pragmas</entry>
1084             <entry>dynamic</entry>
1085             <entry><option>-fno-warn-warnings-deprecations</option></entry>
1086           </row>
1087
1088           <row>
1089             <entry><option>-fwarn-deprecated-flags</option></entry>
1090             <entry>warn about uses of commandline flags that are deprecated</entry>
1091             <entry>dynamic</entry>
1092             <entry><option>-fno-warn-deprecated-flags</option></entry>
1093           </row>
1094
1095           <row>
1096             <entry><option>-fwarn-duplicate-exports</option></entry>
1097             <entry>warn when an entity is exported multiple times</entry>
1098             <entry>dynamic</entry>
1099             <entry><option>-fno-warn-duplicate-exports</option></entry>
1100           </row>
1101
1102           <row>
1103             <entry><option>-fwarn-hi-shadowing</option></entry>
1104             <entry>warn when a <literal>.hi</literal> file in the
1105             current directory shadows a library</entry>
1106             <entry>dynamic</entry>
1107             <entry><option>-fno-warn-hi-shadowing</option></entry>
1108           </row>
1109
1110           <row>
1111             <entry><option>-fwarn-identities</option></entry>
1112             <entry>warn about uses of Prelude numeric conversions that are probably
1113                    the identity (and hence could be omitted)</entry>
1114             <entry>dynamic</entry>
1115             <entry><option>-fno-warn-identities</option></entry>
1116           </row>
1117
1118           <row>
1119             <entry><option>-fwarn-implicit-prelude</option></entry>
1120             <entry>warn when the Prelude is implicitly imported</entry>
1121             <entry>dynamic</entry>
1122             <entry><option>-fno-warn-implicit-prelude</option></entry>
1123           </row>
1124
1125           <row>
1126             <entry><option>-fwarn-incomplete-patterns</option></entry>
1127             <entry>warn when a pattern match could fail</entry>
1128             <entry>dynamic</entry>
1129             <entry><option>-fno-warn-incomplete-patterns</option></entry>
1130           </row>
1131
1132           <row>
1133             <entry><option>-fwarn-incomplete-record-updates</option></entry>
1134             <entry>warn when a record update could fail</entry>
1135             <entry>dynamic</entry>
1136             <entry><option>-fno-warn-incomplete-record-updates</option></entry>
1137           </row>
1138
1139           <row>
1140             <entry><option>-fwarn-lazy-unlifted-bindings</option></entry>
1141             <entry>warn when a pattern binding looks lazy but must be strict</entry>
1142             <entry>dynamic</entry>
1143             <entry><option>-fno-warn-lazy-unlifted-bindings</option></entry>
1144           </row>
1145
1146           <row>
1147             <entry><option>-fwarn-missing-fields</option></entry>
1148             <entry>warn when fields of a record are uninitialised</entry>
1149             <entry>dynamic</entry>
1150             <entry><option>-fno-warn-missing-fields</option></entry>
1151           </row>
1152
1153           <row>
1154             <entry><option>-fwarn-missing-import-lists</option></entry>
1155             <entry>warn when an import declaration does not explicitly 
1156                    list all the names brought into scope</entry>
1157             <entry>dynamic</entry>
1158             <entry><option>-fnowarn-missing-import-lists</option></entry>
1159           </row>
1160
1161           <row>
1162             <entry><option>-fwarn-missing-methods</option></entry>
1163             <entry>warn when class methods are undefined</entry>
1164             <entry>dynamic</entry>
1165             <entry><option>-fno-warn-missing-methods</option></entry>
1166           </row>
1167
1168           <row>
1169             <entry><option>-fwarn-missing-signatures</option></entry>
1170             <entry>warn about top-level functions without signatures</entry>
1171             <entry>dynamic</entry>
1172             <entry><option>-fno-warn-missing-signatures</option></entry>
1173           </row>
1174
1175           <row>
1176             <entry><option>-fwarn-name-shadowing</option></entry>
1177             <entry>warn when names are shadowed</entry>
1178             <entry>dynamic</entry>
1179             <entry><option>-fno-warn-name-shadowing</option></entry>
1180           </row>
1181
1182           <row>
1183             <entry><option>-fwarn-orphans</option></entry>
1184             <entry>warn when the module contains <link linkend="orphan-modules">orphan instance declarations
1185             or rewrite rules</link></entry>
1186             <entry>dynamic</entry>
1187             <entry><option>-fno-warn-orphans</option></entry>
1188           </row>
1189
1190           <row>
1191             <entry><option>-fwarn-overlapping-patterns</option></entry>
1192             <entry>warn about overlapping patterns</entry>
1193             <entry>dynamic</entry>
1194             <entry><option>-fno-warn-overlapping-patterns</option></entry>
1195           </row>
1196
1197           <row>
1198             <entry><option>-fwarn-tabs</option></entry>
1199             <entry>warn if there are tabs in the source file</entry>
1200             <entry>dynamic</entry>
1201             <entry><option>-fno-warn-tabs</option></entry>
1202           </row>
1203
1204           <row>
1205             <entry><option>-fwarn-type-defaults</option></entry>
1206             <entry>warn when defaulting happens</entry>
1207             <entry>dynamic</entry>
1208             <entry><option>-fno-warn-type-defaults</option></entry>
1209           </row>
1210
1211           <row>
1212             <entry><option>-fwarn-monomorphism-restriction</option></entry>
1213             <entry>warn when the Monomorphism Restriction is applied</entry>
1214             <entry>dynamic</entry>
1215             <entry><option>-fno-warn-monomorphism-restriction</option></entry>
1216           </row>
1217
1218           <row>
1219             <entry><option>-fwarn-unused-binds</option></entry>
1220             <entry>warn about bindings that are unused</entry>
1221             <entry>dynamic</entry>
1222             <entry><option>-fno-warn-unused-binds</option></entry>
1223           </row>
1224
1225           <row>
1226             <entry><option>-fwarn-unused-imports</option></entry>
1227             <entry>warn about unnecessary imports</entry>
1228             <entry>dynamic</entry>
1229             <entry><option>-fno-warn-unused-imports</option></entry>
1230           </row>
1231
1232           <row>
1233             <entry><option>-fwarn-unused-matches</option></entry>
1234             <entry>warn about variables in patterns that aren't used</entry>
1235             <entry>dynamic</entry>
1236             <entry><option>-fno-warn-unused-matches</option></entry>
1237           </row>
1238
1239           <row>
1240             <entry><option>-fwarn-unused-do-bind</option></entry>
1241             <entry>warn about do bindings that appear to throw away values of types other than <literal>()</literal></entry>
1242             <entry>dynamic</entry>
1243             <entry><option>-fno-warn-unused-do-bind</option></entry>
1244           </row>
1245
1246           <row>
1247             <entry><option>-fwarn-wrong-do-bind</option></entry>
1248             <entry>warn about do bindings that appear to throw away monadic values that you should have bound instead</entry>
1249             <entry>dynamic</entry>
1250             <entry><option>-fno-warn-wrong-do-bind</option></entry>
1251           </row>
1252
1253           </tbody>
1254         </tgroup>
1255       </informaltable>
1256
1257     </sect2>
1258     <sect2>
1259       <title>Optimisation levels</title>
1260
1261       <para><xref linkend="options-optimise"/></para>
1262
1263       <informaltable>
1264         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1265           <thead>
1266             <row>
1267               <entry>Flag</entry>
1268               <entry>Description</entry>
1269               <entry>Static/Dynamic</entry>
1270               <entry>Reverse</entry>
1271             </row>
1272           </thead>
1273           <tbody>
1274             <row>
1275               <entry><option>-O</option></entry>
1276               <entry>Enable default optimisation (level 1)</entry>
1277               <entry>dynamic</entry>
1278               <entry><option>-O0</option></entry>
1279             </row>
1280             <row>
1281               <entry><option>-O</option><replaceable>n</replaceable></entry>
1282               <entry>Set optimisation level <replaceable>n</replaceable></entry>
1283               <entry>dynamic</entry>
1284               <entry><option>-O0</option></entry>
1285             </row>
1286           </tbody>
1287         </tgroup>
1288       </informaltable>
1289               
1290     </sect2>
1291     <sect2>
1292       <title>Individual optimisations</title>
1293
1294       <para><xref linkend="options-f"/></para>
1295
1296       <informaltable>
1297         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1298           <thead>
1299             <row>
1300               <entry>Flag</entry>
1301               <entry>Description</entry>
1302               <entry>Static/Dynamic</entry>
1303               <entry>Reverse</entry>
1304             </row>
1305           </thead>
1306           <tbody>
1307             <row>
1308               <entry><option>-fcase-merge</option></entry>
1309               <entry>Enable case-merging. Implied by <option>-O</option>.</entry>
1310               <entry>dynamic</entry>
1311               <entry><option>-fno-case-merge</option></entry>
1312             </row>
1313
1314             <row>
1315               <entry><option>-fdicts-strict</option></entry>
1316               <entry>Make dictionaries strict</entry>
1317               <entry>static</entry>
1318               <entry><option>-fno-dicts-strict</option></entry>
1319             </row>
1320
1321             <row>
1322               <entry><option>-fmethod-sharing</option></entry>
1323               <entry>Share specialisations of overloaded functions (default)</entry>
1324               <entry>dynamic</entry>
1325               <entry><option>-fno-method-sharing</option></entry>
1326             </row>
1327
1328             <row>
1329               <entry><option>-fdo-eta-reduction</option></entry>
1330               <entry>Enable eta-reduction. Implied by <option>-O</option>.</entry>
1331               <entry>dynamic</entry>
1332               <entry><option>-fno-do-eta-reduction</option></entry>
1333             </row>
1334
1335             <row>
1336               <entry><option>-fdo-lambda-eta-expansion</option></entry>
1337               <entry>Enable lambda eta-reduction</entry>
1338               <entry>dynamic</entry>
1339               <entry><option>-fno-do-lambda-eta-expansion</option></entry>
1340             </row>
1341
1342             <row>
1343               <entry><option>-fexcess-precision</option></entry>
1344               <entry>Enable excess intermediate precision</entry>
1345               <entry>dynamic</entry>
1346               <entry><option>-fno-excess-precision</option></entry>
1347             </row>
1348
1349             <row>
1350               <entry><option>-fignore-asserts</option></entry>
1351               <entry>Ignore assertions in the source</entry>
1352               <entry>dynamic</entry>
1353               <entry><option>-fno-ignore-asserts</option></entry>
1354             </row>
1355
1356             <row>
1357               <entry><option>-fignore-interface-pragmas</option></entry>
1358               <entry>Ignore pragmas in interface files</entry>
1359               <entry>dynamic</entry>
1360               <entry><option>-fno-ignore-interface-pragmas</option></entry>
1361             </row>
1362
1363             <row>
1364               <entry><option>-fomit-interface-pragmas</option></entry>
1365               <entry>Don't generate interface pragmas</entry>
1366               <entry>dynamic</entry>
1367               <entry><option>-fno-omit-interface-pragmas</option></entry>
1368             </row>
1369
1370             <row>
1371               <entry><option>-fmax-worker-args</option></entry>
1372               <entry>If a worker has that many arguments, none will be
1373                 unpacked anymore (default: 10)</entry>
1374               <entry>static</entry>
1375               <entry>-</entry>
1376             </row>
1377
1378             <row>
1379               <entry><option>-fsimplifier-phases</option></entry>
1380               <entry>Set the number of phases for the simplifier (default 2).
1381               Ignored with <option>-O0</option>.</entry>
1382               <entry>dynamic</entry>
1383               <entry>-</entry>
1384             </row>
1385
1386             <row>
1387               <entry><option>-fmax-simplifier-iterations</option></entry>
1388               <entry>Set the max iterations for the simplifier</entry>
1389               <entry>dynamic</entry>
1390               <entry>-</entry>
1391             </row>
1392
1393             <row>
1394               <entry><option>-fno-state-hack</option></entry>
1395               <entry>Turn off the "state hack" whereby any lambda with a real-world state token
1396               as argument is considered to be single-entry.  Hence OK to inline things inside it.</entry>
1397               <entry>static</entry>
1398               <entry>-</entry>
1399             </row>
1400
1401             <row>
1402               <entry><option>-fcse</option></entry>
1403               <entry>Turn on common sub-expression elimination. Implied by <option>-O</option>.</entry>
1404               <entry>dynamic</entry>
1405               <entry>-fno-cse</entry>
1406             </row>
1407
1408             <row>
1409               <entry><option>-fspecialise</option></entry>
1410               <entry>Turn on specialisation of overloaded functions. Implied by <option>-O</option>.</entry>
1411               <entry>dynamic</entry>
1412               <entry>-fno-specialise</entry>
1413             </row>
1414
1415             <row>
1416               <entry><option>-ffull-laziness</option></entry>
1417               <entry>Turn on full laziness (floating bindings outwards). Implied by <option>-O</option>.</entry>
1418               <entry>dynamic</entry>
1419               <entry>-fno-full-laziness</entry>
1420             </row>
1421
1422             <row>
1423               <entry><option>-ffloat-in</option></entry>
1424               <entry>Turn on the float-in transformation. Implied by <option>-O</option>.</entry>
1425               <entry>dynamic</entry>
1426               <entry>-fno-float-in</entry>
1427             </row>
1428
1429             <row>
1430               <entry><option>-fenable-rewrite-rules</option></entry>
1431               <entry>Switch on all rewrite rules (including rules
1432               generated by automatic specialisation of overloaded functions).
1433               Implied by <option>-O</option>. </entry>
1434               <entry>dynamic</entry>
1435               <entry><option>-fno-enable-rewrite-rules</option></entry>
1436             </row>
1437
1438             <row>
1439               <entry><option>-fstrictness</option></entry>
1440               <entry>Turn on strictness analysis. Implied by <option>-O</option>.</entry>
1441               <entry>dynamic</entry>
1442               <entry>-fno-strictness</entry>
1443             </row>
1444
1445             <row>
1446               <entry><option>-fstrictness=before</option>=<replaceable>n</replaceable></entry>
1447               <entry>Run an additional strictness analysis before simplifier
1448 phase <replaceable>n</replaceable></entry>
1449               <entry>dynamic</entry>
1450               <entry>-</entry>
1451             </row>
1452
1453             <row>
1454               <entry><option>-fspec-constr</option></entry>
1455               <entry>Turn on the SpecConstr transformation. Implied by <option>-O2</option>.</entry>
1456               <entry>dynamic</entry>
1457               <entry>-fno-spec-constr</entry>
1458             </row>
1459
1460             <row>
1461               <entry><option>-fspec-constr-threshold</option>=<replaceable>n</replaceable></entry>
1462               <entry>Set the size threshold for the SpecConstr transformation to <replaceable>n</replaceable> (default: 200)</entry>
1463               <entry>static</entry>
1464               <entry><option>-fno-spec-constr-threshold</option></entry>
1465             </row>
1466
1467             <row>
1468               <entry><option>-fspec-constr-count</option>=<replaceable>n</replaceable></entry>
1469               <entry>Set to <replaceable>n</replaceable> (default: 3) the maximum number of 
1470                 specialisations that will be created for any one function
1471                 by the SpecConstr transformation</entry>
1472               <entry>static</entry>
1473               <entry><option>-fno-spec-constr-count</option></entry>
1474             </row>
1475
1476             <row>
1477               <entry><option>-fliberate-case</option></entry>
1478               <entry>Turn on the liberate-case transformation. Implied by <option>-O2</option>.</entry>
1479               <entry>dynamic</entry>
1480               <entry>-fno-liberate-case</entry>
1481             </row>
1482
1483             <row>
1484               <entry><option>-fstatic-argument-transformation</option></entry>
1485               <entry>Turn on the static argument transformation. Implied by <option>-O2</option>.</entry>
1486               <entry>dynamic</entry>
1487               <entry>-fno-static-argument-transformation</entry>
1488             </row>
1489
1490             <row>
1491               <entry><option>-fliberate-case-threshold</option>=<replaceable>n</replaceable></entry>
1492               <entry>Set the size threshold for the liberate-case transformation to <replaceable>n</replaceable> (default: 200)</entry>
1493               <entry>static</entry>
1494               <entry><option>-fno-liberate-case-threshold</option></entry>
1495             </row>
1496
1497             <row>
1498               <entry><option>-funbox-strict-fields</option></entry>
1499               <entry>Flatten strict constructor fields</entry>
1500               <entry>dynamic</entry>
1501               <entry><option>-fno-unbox-strict-fields</option></entry>
1502             </row>
1503
1504             <row>
1505               <entry><option>-funfolding-creation-threshold</option></entry>
1506               <entry>Tweak unfolding settings</entry>
1507               <entry>static</entry>
1508               <entry><option>-fno-unfolding-creation-threshold</option></entry>
1509             </row>
1510
1511             <row>
1512               <entry><option>-funfolding-fun-discount</option></entry>
1513               <entry>Tweak unfolding settings</entry>
1514               <entry>static</entry>
1515               <entry><option>-fno-unfolding-fun-discount</option></entry>
1516             </row>
1517
1518             <row>
1519               <entry><option>-funfolding-keeness-factor</option></entry>
1520               <entry>Tweak unfolding settings</entry>
1521               <entry>static</entry>
1522               <entry><option>-fno-unfolding-keeness-factor</option></entry>
1523             </row>
1524
1525             <row>
1526               <entry><option>-funfolding-use-threshold</option></entry>
1527               <entry>Tweak unfolding settings</entry>
1528               <entry>static</entry>
1529               <entry><option>-fno-unfolding-use-threshold</option></entry>
1530             </row>
1531
1532             <row>
1533               <entry><option>-fno-pre-inlining</option></entry>
1534               <entry>Turn off pre-inlining</entry>
1535               <entry>static</entry>
1536               <entry>-</entry>
1537             </row>
1538
1539             <row>
1540               <entry><option>-feager-blackholing</option></entry>
1541               <entry>Turn on <link linkend="parallel-compile-options">eager blackholing</link></entry>
1542               <entry>dynamic</entry>
1543               <entry>-</entry>
1544             </row>
1545           </tbody>
1546         </tgroup>
1547       </informaltable>
1548     </sect2>
1549
1550     <sect2>
1551       <title>Profiling options</title>
1552       
1553       <para><xref linkend="profiling"/></para>
1554
1555       <informaltable>
1556         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1557           <thead>
1558             <row>
1559               <entry>Flag</entry>
1560               <entry>Description</entry>
1561               <entry>Static/Dynamic</entry>
1562               <entry>Reverse</entry>
1563             </row>
1564           </thead>
1565           <tbody>
1566             <row>
1567               <entry><option>-auto</option></entry>
1568               <entry>Auto-add <literal>_scc_</literal>s to all
1569               exported functions not marked INLINE</entry>
1570               <entry>dynamic</entry>
1571               <entry><option>-no-auto</option></entry>
1572             </row>
1573             <row>
1574               <entry><option>-auto-all</option></entry>
1575               <entry>Auto-add <literal>_scc_</literal>s to all
1576               top-level functions not marked INLINE</entry>
1577               <entry>dynamic</entry>
1578               <entry><option>-no-auto-all</option></entry>
1579             </row>
1580             <row>
1581               <entry><option>-caf-all</option></entry>
1582               <entry>Auto-add <literal>_scc_</literal>s to all CAFs</entry>
1583               <entry>dynamic</entry>
1584               <entry><option>-no-caf-all</option></entry>
1585             </row>
1586             <row>
1587               <entry><option>-prof</option></entry>
1588               <entry>Turn on profiling</entry>
1589               <entry>static</entry>
1590               <entry>-</entry>
1591             </row>
1592             <row>
1593               <entry><option>-ticky</option></entry>
1594               <entry><link linkend="ticky-ticky">Turn on ticky-ticky profiling</link></entry>
1595               <entry>static</entry>
1596               <entry>-</entry>
1597             </row>
1598           </tbody>
1599         </tgroup>
1600       </informaltable>
1601     </sect2>
1602
1603     <sect2>
1604       <title>Program coverage options</title>
1605       
1606       <para><xref linkend="hpc"/></para>
1607
1608       <informaltable>
1609         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1610           <thead>
1611             <row>
1612               <entry>Flag</entry>
1613               <entry>Description</entry>
1614               <entry>Static/Dynamic</entry>
1615               <entry>Reverse</entry>
1616             </row>
1617           </thead>
1618           <tbody>
1619             <row>
1620               <entry><option>-fhpc</option></entry>
1621               <entry>Turn on Haskell program coverage instrumentation</entry>
1622               <entry>static</entry>
1623               <entry><option>-</option></entry>
1624             </row>
1625             <row>
1626               <entry><option>-hpcdir dir</option></entry>
1627               <entry>Directory to deposit .mix files during compilation (default is .hpc)</entry>
1628               <entry>dynamic</entry>
1629               <entry><option>-</option></entry>
1630             </row>
1631           </tbody>
1632         </tgroup>
1633       </informaltable>
1634     </sect2>
1635
1636     <sect2>
1637       <title>Haskell pre-processor options</title>
1638
1639       <para><xref linkend="pre-processor"/></para>
1640
1641       <informaltable>
1642         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1643           <thead>
1644             <row>
1645               <entry>Flag</entry>
1646               <entry>Description</entry>
1647               <entry>Static/Dynamic</entry>
1648               <entry>Reverse</entry>
1649             </row>
1650           </thead>
1651           <tbody>
1652             <row>
1653               <entry><option>-F</option></entry>
1654               <entry>
1655                   Enable the use of a pre-processor
1656                   (set with <option>-pgmF</option>)
1657               </entry>
1658               <entry>dynamic</entry>
1659               <entry>-</entry>
1660             </row>
1661           </tbody>
1662         </tgroup>
1663       </informaltable>
1664     </sect2>
1665
1666     <sect2>
1667       <title>C pre-processor options</title>
1668
1669       <para><xref linkend="c-pre-processor"/></para>
1670
1671       <informaltable>
1672         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1673           <thead>
1674             <row>
1675               <entry>Flag</entry>
1676               <entry>Description</entry>
1677               <entry>Static/Dynamic</entry>
1678               <entry>Reverse</entry>
1679             </row>
1680           </thead>
1681           <tbody>
1682             <row>
1683               <entry><option>-cpp</option></entry>
1684               <entry>Run the C pre-processor on Haskell source files</entry>
1685               <entry>dynamic</entry>
1686               <entry>-</entry>
1687             </row>
1688             <row>
1689               <entry><option>-D</option><replaceable>symbol</replaceable><optional>=<replaceable>value</replaceable></optional></entry>
1690               <entry>Define a symbol in the C pre-processor</entry>
1691               <entry>dynamic</entry>
1692               <entry><option>-U</option><replaceable>symbol</replaceable></entry>
1693             </row>
1694             <row>
1695               <entry><option>-U</option><replaceable>symbol</replaceable></entry>
1696               <entry>Undefine a symbol in the C pre-processor</entry>
1697               <entry>dynamic</entry>
1698               <entry>-</entry>
1699             </row>
1700             <row>
1701               <entry><option>-I</option><replaceable>dir</replaceable></entry>
1702               <entry>Add <replaceable>dir</replaceable> to the
1703               directory search list for <literal>#include</literal> files</entry>
1704               <entry>dynamic</entry>
1705               <entry>-</entry>
1706             </row>
1707           </tbody>
1708         </tgroup>
1709       </informaltable>
1710     </sect2>
1711
1712     <sect2>
1713       <title>Code generation options</title>
1714
1715       <para><xref linkend="options-codegen"/></para>
1716
1717       <informaltable>
1718         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1719           <thead>
1720             <row>
1721               <entry>Flag</entry>
1722               <entry>Description</entry>
1723               <entry>Static/Dynamic</entry>
1724               <entry>Reverse</entry>
1725             </row>
1726           </thead>
1727           <tbody>
1728             <row>
1729               <entry><option>-fasm</option></entry>
1730               <entry>Use the native code generator</entry>
1731               <entry>dynamic</entry>
1732               <entry>-fvia-C</entry>
1733             </row>
1734             <row>
1735               <entry><option>-fvia-C</option></entry>
1736               <entry>Compile via C</entry>
1737               <entry>dynamic</entry>
1738               <entry>-fasm</entry>
1739             </row>
1740             <row>
1741               <entry><option>-fllvm</option></entry>
1742               <entry>Compile via LLVM</entry>
1743               <entry>dynamic</entry>
1744               <entry>-fasm</entry>
1745             </row>
1746             <row>
1747               <entry><option>-fno-code</option></entry>
1748               <entry>Omit code generation</entry>
1749               <entry>dynamic</entry>
1750               <entry>-</entry>
1751             </row>
1752             <row>
1753               <entry><option>-fbyte-code</option></entry>
1754               <entry>Generate byte-code</entry>
1755               <entry>dynamic</entry>
1756               <entry>-</entry>
1757             </row>
1758             <row>
1759               <entry><option>-fobject-code</option></entry>
1760               <entry>Generate object code</entry>
1761               <entry>dynamic</entry>
1762               <entry>-</entry>
1763             </row>
1764           </tbody>
1765         </tgroup>
1766       </informaltable>
1767     </sect2>
1768
1769     <sect2>
1770       <title>Linking options</title>
1771
1772       <para><xref linkend="options-linker"/></para>
1773
1774       <informaltable>
1775         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1776           <thead>
1777             <row>
1778               <entry>Flag</entry>
1779               <entry>Description</entry>
1780               <entry>Static/Dynamic</entry>
1781               <entry>Reverse</entry>
1782             </row>
1783           </thead>
1784           <tbody>
1785             <row>
1786               <entry><option>-shared</option></entry>
1787               <entry>Generate a shared library (as opposed to an executable)</entry>
1788               <entry>dynamic</entry>
1789               <entry>-</entry>
1790             </row>
1791             <row>
1792               <entry><option>-fPIC</option></entry>
1793               <entry>Generate position-independent code (where available)</entry>
1794               <entry>static</entry>
1795               <entry>-</entry>
1796             </row>
1797             <row>
1798               <entry><option>-dynamic</option></entry>
1799               <entry>Use dynamic Haskell libraries (if available)</entry>
1800               <entry>static</entry>
1801               <entry>-</entry>
1802             </row>
1803             <row>
1804               <entry><option>-dynload</option></entry>
1805               <entry>Selects one of a number of modes for finding shared
1806                 libraries at runtime.</entry>
1807               <entry>static</entry>
1808               <entry>-</entry>
1809             </row>
1810             <row>
1811               <entry><option>-framework</option> <replaceable>name</replaceable></entry>
1812               <entry>On Darwin/MacOS X only, link in the framework <replaceable>name</replaceable>.
1813                 This option corresponds to the <option>-framework</option> option for Apple's Linker.</entry>
1814               <entry>dynamic</entry>
1815               <entry>-</entry>
1816             </row>
1817             <row>
1818               <entry><option>-framework-path</option> <replaceable>name</replaceable></entry>
1819               <entry>On Darwin/MacOS X only, add <replaceable>dir</replaceable> to the list of
1820                 directories searched for frameworks.
1821                 This option corresponds to the <option>-F</option> option for Apple's Linker.</entry>
1822               <entry>dynamic</entry>
1823               <entry>-</entry>
1824             </row>
1825             <row>
1826               <entry><option>-l</option><replaceable>lib</replaceable></entry>
1827               <entry>Link in library <replaceable>lib</replaceable></entry>
1828               <entry>dynamic</entry>
1829               <entry>-</entry>
1830             </row>
1831             <row>
1832               <entry><option>-L</option><replaceable>dir</replaceable></entry>
1833               <entry>Add <replaceable>dir</replaceable> to the list of
1834               directories searched for libraries</entry>
1835               <entry>dynamic</entry>
1836               <entry>-</entry>
1837             </row>
1838             <row>
1839               <entry><option>-main-is</option></entry>
1840               <entry>Set main module and function</entry>
1841               <entry>dynamic</entry>
1842               <entry>-</entry>
1843             </row>
1844             <row>
1845               <entry><option>--mk-dll</option></entry>
1846               <entry>DLL-creation mode (Windows only)</entry>
1847               <entry>dynamic</entry>
1848               <entry>-</entry>
1849             </row>
1850             <row>
1851               <entry><option>-no-hs-main</option></entry>
1852               <entry>Don't assume this program contains <literal>main</literal></entry>
1853               <entry>dynamic</entry>
1854               <entry>-</entry>
1855             </row>
1856             <row>
1857               <entry><option>-rtsopts</option>, <option>-rtsopts={none,some,all}</option></entry>
1858               <entry>Control whether the RTS behaviour can be tweaked via command-line
1859           flags and the <literal>GHCRTS</literal> environment
1860           variable. Using <literal>none</literal> means no RTS flags can be given; <literal>some</literal> means only a minimum of safe options can be given (the default), and <literal>all</literal> (or no argument at all) means that all RTS flags are permitted.</entry>
1861               <entry>dynamic</entry>
1862               <entry>-</entry>
1863             </row>
1864             <row>
1865               <entry><option>-with-rtsopts=<replaceable>opts</replaceable></option></entry>
1866               <entry>Set the default RTS options to
1867           <replaceable>opts</replaceable>.</entry>
1868               <entry>dynamic</entry>
1869               <entry>-</entry>
1870             </row>
1871             <row>
1872               <entry><option>-no-link</option></entry>
1873               <entry>Omit linking</entry>
1874               <entry>dynamic</entry>
1875               <entry>-</entry>
1876             </row>
1877             <row>
1878               <entry><option>-split-objs</option></entry>
1879               <entry>Split objects (for libraries)</entry>
1880               <entry>dynamic</entry>
1881               <entry>-</entry>
1882             </row>
1883             <row>
1884               <entry><option>-static</option></entry>
1885               <entry>Use static Haskell libraries</entry>
1886               <entry>static</entry>
1887               <entry>-</entry>
1888             </row>
1889             <row>
1890               <entry><option>-threaded</option></entry>
1891               <entry>Use the threaded runtime</entry>
1892               <entry>static</entry>
1893               <entry>-</entry>
1894             </row>
1895             <row>
1896               <entry><option>-debug</option></entry>
1897               <entry>Use the debugging runtime</entry>
1898               <entry>static</entry>
1899               <entry>-</entry>
1900             </row>
1901             <row>
1902               <entry><option>-eventlog</option></entry>
1903               <entry>Enable runtime event tracing</entry>
1904               <entry>static</entry>
1905               <entry>-</entry>
1906             </row>
1907             <row>
1908               <entry><option>-fno-gen-manifest</option></entry>
1909               <entry>Do not generate a manifest file (Windows only)</entry>
1910               <entry>dynamic</entry>
1911               <entry>-</entry>
1912             </row>
1913             <row>
1914               <entry><option>-fno-embed-manifest</option></entry>
1915               <entry>Do not embed the manifest in the executable (Windows only)</entry>
1916               <entry>dynamic</entry>
1917               <entry>-</entry>
1918             </row>
1919             <row>
1920               <entry><option>-fno-shared-implib</option></entry>
1921               <entry>Don't generate an import library for a DLL (Windows only)</entry>
1922               <entry>dynamic</entry>
1923               <entry>-</entry>
1924             </row>
1925             <row>
1926               <entry><option>-dylib-install-name</option> <replaceable>path</replaceable></entry>
1927               <entry>Set the install name (via <literal>-install_name</literal> passed to Apple's
1928               linker), specifying the full install path of the library file. Any libraries
1929               or executables that link with it later will pick up that path as their
1930               runtime search location for it. (Darwin/MacOS X only)</entry>
1931               <entry>dynamic</entry>
1932               <entry>-</entry>
1933             </row>
1934           </tbody>
1935         </tgroup>
1936       </informaltable>
1937     </sect2>
1938
1939     <sect2>
1940       <title>Replacing phases</title>
1941
1942       <para><xref linkend="replacing-phases"/></para>
1943
1944       <informaltable>
1945         <tgroup cols="4" align="left" colsep="1" rowsep="1">
1946           <thead>
1947             <row>
1948               <entry>Flag</entry>
1949               <entry>Description</entry>
1950               <entry>Static/Dynamic</entry>
1951               <entry>Reverse</entry>
1952             </row>
1953           </thead>
1954           <tbody>
1955             <row>
1956               <entry><option>-pgmL</option> <replaceable>cmd</replaceable></entry>
1957               <entry>Use <replaceable>cmd</replaceable> as the literate pre-processor</entry>
1958               <entry>dynamic</entry>
1959               <entry>-</entry>
1960             </row>
1961             <row>
1962               <entry><option>-pgmP</option> <replaceable>cmd</replaceable></entry>
1963               <entry>Use <replaceable>cmd</replaceable> as the C
1964               pre-processor (with <option>-cpp</option> only)</entry>
1965               <entry>dynamic</entry>
1966               <entry>-</entry>
1967             </row>
1968             <row>
1969               <entry><option>-pgmc</option> <replaceable>cmd</replaceable></entry>
1970               <entry>Use <replaceable>cmd</replaceable> as the C compiler</entry>
1971               <entry>dynamic</entry>
1972               <entry>-</entry>
1973             <row>
1974               <entry><option>-pgmlo</option> <replaceable>cmd</replaceable></entry>
1975               <entry>Use <replaceable>cmd</replaceable> as the LLVM optimiser</entry>
1976               <entry>dynamic</entry>
1977               <entry>-</entry>
1978             </row>
1979             <row>
1980               <entry><option>-pgmlc</option> <replaceable>cmd</replaceable></entry>
1981               <entry>Use <replaceable>cmd</replaceable> as the LLVM compiler</entry>
1982               <entry>dynamic</entry>
1983               <entry>-</entry>
1984             </row>
1985             </row>
1986             <row>
1987               <entry><option>-pgmm</option> <replaceable>cmd</replaceable></entry>
1988               <entry>Use <replaceable>cmd</replaceable> as the mangler</entry>
1989               <entry>dynamic</entry>
1990               <entry>-</entry>
1991             </row>
1992             <row>
1993               <entry><option>-pgms</option> <replaceable>cmd</replaceable></entry>
1994               <entry>Use <replaceable>cmd</replaceable> as the splitter</entry>
1995               <entry>dynamic</entry>
1996               <entry>-</entry>
1997             </row>
1998             <row>
1999               <entry><option>-pgma</option> <replaceable>cmd</replaceable></entry>
2000               <entry>Use <replaceable>cmd</replaceable> as the assembler</entry>
2001               <entry>dynamic</entry>
2002               <entry>-</entry>
2003             </row>
2004             <row>
2005               <entry><option>-pgml</option> <replaceable>cmd</replaceable></entry>
2006               <entry>Use <replaceable>cmd</replaceable> as the linker</entry>
2007               <entry>dynamic</entry>
2008               <entry>-</entry>
2009             </row>
2010             <row>
2011               <entry><option>-pgmdll</option> <replaceable>cmd</replaceable></entry>
2012               <entry>Use <replaceable>cmd</replaceable> as the DLL generator</entry>
2013               <entry>dynamic</entry>
2014               <entry>-</entry>
2015             </row>
2016             <row>
2017               <entry><option>-pgmF</option> <replaceable>cmd</replaceable></entry>
2018               <entry>Use <replaceable>cmd</replaceable> as the pre-processor
2019               (with <option>-F</option> only)</entry>
2020               <entry>dynamic</entry>
2021               <entry>-</entry>
2022             </row>
2023             <row>
2024               <entry><option>-pgmwindres</option> <replaceable>cmd</replaceable></entry>
2025               <entry>Use <replaceable>cmd</replaceable> as the program for
2026                 embedding manifests on Windows.</entry>
2027               <entry>dynamic</entry>
2028               <entry>-</entry>
2029             </row>
2030           </tbody>
2031         </tgroup>
2032       </informaltable>
2033       <indexterm><primary><option>-pgmL</option></primary></indexterm>
2034       <indexterm><primary><option>-pgmP</option></primary></indexterm>
2035       <indexterm><primary><option>-pgmc</option></primary></indexterm>
2036       <indexterm><primary><option>-pgmlo</option></primary></indexterm>
2037       <indexterm><primary><option>-pgmlc</option></primary></indexterm>
2038       <indexterm><primary><option>-pgma</option></primary></indexterm>
2039       <indexterm><primary><option>-pgml</option></primary></indexterm>
2040       <indexterm><primary><option>-pgmdll</option></primary></indexterm>
2041       <indexterm><primary><option>-pgmF</option></primary></indexterm>
2042
2043     </sect2>
2044
2045     <sect2>
2046       <title>Forcing options to particular phases</title>
2047
2048       <para><xref linkend="forcing-options-through"/></para>
2049
2050       <informaltable>
2051         <tgroup cols="4" align="left" colsep="1" rowsep="1">
2052           <thead>
2053             <row>
2054               <entry>Flag</entry>
2055               <entry>Description</entry>
2056               <entry>Static/Dynamic</entry>
2057               <entry>Reverse</entry>
2058             </row>
2059           </thead>
2060           <tbody>
2061             <row>
2062               <entry><option>-optL</option> <replaceable>option</replaceable></entry>
2063               <entry>pass <replaceable>option</replaceable> to the literate pre-processor</entry>
2064               <entry>dynamic</entry>
2065               <entry>-</entry>
2066             </row>
2067             <row>
2068               <entry><option>-optP</option> <replaceable>option</replaceable></entry>
2069               <entry>pass <replaceable>option</replaceable> to cpp (with
2070               <option>-cpp</option> only)</entry>
2071               <entry>dynamic</entry>
2072               <entry>-</entry>
2073             </row>
2074             <row>
2075               <entry><option>-optF</option> <replaceable>option</replaceable></entry>
2076               <entry>pass <replaceable>option</replaceable> to the
2077               custom pre-processor</entry>
2078               <entry>dynamic</entry>
2079               <entry>-</entry>
2080             </row>
2081             <row>
2082               <entry><option>-optc</option> <replaceable>option</replaceable></entry>
2083               <entry>pass <replaceable>option</replaceable> to the C compiler</entry>
2084               <entry>dynamic</entry>
2085               <entry>-</entry>
2086             </row>
2087             <row>
2088               <entry><option>-optlo</option> <replaceable>option</replaceable></entry>
2089               <entry>pass <replaceable>option</replaceable> to the LLVM optimiser</entry>
2090               <entry>dynamic</entry>
2091               <entry>-</entry>
2092             </row>
2093             <row>
2094               <entry><option>-optlc</option> <replaceable>option</replaceable></entry>
2095               <entry>pass <replaceable>option</replaceable> to the LLVM compiler</entry>
2096               <entry>dynamic</entry>
2097               <entry>-</entry>
2098             </row>
2099             <row>
2100               <entry><option>-optm</option> <replaceable>option</replaceable></entry>
2101               <entry>pass <replaceable>option</replaceable> to the mangler</entry>
2102               <entry>dynamic</entry>
2103               <entry>-</entry>
2104             </row>
2105             <row>
2106               <entry><option>-opta</option> <replaceable>option</replaceable></entry>
2107               <entry>pass <replaceable>option</replaceable> to the assembler</entry>
2108               <entry>dynamic</entry>
2109               <entry>-</entry>
2110             </row>
2111             <row>
2112               <entry><option>-optl</option> <replaceable>option</replaceable></entry>
2113               <entry>pass <replaceable>option</replaceable> to the linker</entry>
2114               <entry>dynamic</entry>
2115               <entry>-</entry>
2116             </row>
2117             <row>
2118               <entry><option>-optdll</option> <replaceable>option</replaceable></entry>
2119               <entry>pass <replaceable>option</replaceable> to the DLL generator</entry>
2120               <entry>dynamic</entry>
2121               <entry>-</entry>
2122             </row>
2123             <row>
2124               <entry><option>-optwindres</option> <replaceable>option</replaceable></entry>
2125               <entry>pass <replaceable>option</replaceable> to <literal>windres</literal>.</entry>
2126               <entry>dynamic</entry>
2127               <entry>-</entry>
2128             </row>
2129           </tbody>
2130         </tgroup>
2131       </informaltable>
2132     </sect2>
2133
2134     <sect2>
2135       <title>Platform-specific options</title>
2136       
2137       <para><xref linkend="options-platform"/></para>
2138
2139       <informaltable>
2140         <tgroup cols="4" align="left" colsep="1" rowsep="1">
2141           <thead>
2142             <row>
2143               <entry>Flag</entry>
2144               <entry>Description</entry>
2145               <entry>Static/Dynamic</entry>
2146               <entry>Reverse</entry>
2147             </row>
2148           </thead>
2149           <tbody>
2150             <row>
2151               <entry><option>-msse2</option></entry>
2152               <entry>(x86 only) Use SSE2 for floating point</entry>
2153               <entry>dynamic</entry>
2154               <entry>-</entry>
2155             </row>
2156           </tbody>
2157           <tbody>
2158             <row>
2159               <entry><option>-monly-[432]-regs</option></entry>
2160               <entry>(x86 only) give some registers back to the C compiler</entry>
2161               <entry>dynamic</entry>
2162               <entry>-</entry>
2163             </row>
2164           </tbody>
2165         </tgroup>
2166       </informaltable>
2167     </sect2>
2168
2169          
2170     <sect2>
2171       <title>External core file options</title>
2172
2173       <para><xref linkend="ext-core"/></para>
2174
2175       <informaltable>
2176         <tgroup cols="4" align="left" colsep="1" rowsep="1">
2177           <thead>
2178             <row>
2179               <entry>Flag</entry>
2180               <entry>Description</entry>
2181               <entry>Static/Dynamic</entry>
2182               <entry>Reverse</entry>
2183             </row>
2184           </thead>
2185           <tbody>
2186             <row>
2187               <entry><option>-fext-core</option></entry>
2188               <entry>Generate <filename>.hcr</filename> external Core files</entry>
2189               <entry>dynamic</entry>
2190               <entry>-</entry>
2191             </row>
2192           </tbody>
2193         </tgroup>
2194       </informaltable>
2195     </sect2>
2196
2197
2198     <sect2>
2199       <title>Compiler debugging options</title>
2200
2201       <para><xref linkend="options-debugging"/></para>
2202
2203       <informaltable>
2204         <tgroup cols="4" align="left" colsep="1" rowsep="1">
2205           <thead>
2206             <row>
2207               <entry>Flag</entry>
2208               <entry>Description</entry>
2209               <entry>Static/Dynamic</entry>
2210               <entry>Reverse</entry>
2211             </row>
2212           </thead>
2213           <tbody>
2214             <row>
2215               <entry><option>-dcore-lint</option></entry>
2216               <entry>Turn on internal sanity checking</entry>
2217               <entry>dynamic</entry>
2218               <entry>-</entry>
2219             </row>
2220             <row>
2221               <entry><option>-ddump-asm</option></entry>
2222               <entry>Dump assembly</entry>
2223               <entry>dynamic</entry>
2224               <entry>-</entry>
2225             </row>
2226             <row>
2227               <entry><option>-ddump-bcos</option></entry>
2228               <entry>Dump interpreter byte code</entry>
2229               <entry>dynamic</entry>
2230               <entry>-</entry>
2231             </row>
2232             <row>
2233               <entry><option>-ddump-cmm</option></entry>
2234               <entry>Dump C-- output</entry>
2235               <entry>dynamic</entry>
2236               <entry>-</entry>
2237             </row>
2238             <row>
2239               <entry><option>-ddump-cpranal</option></entry>
2240               <entry>Dump output from CPR analysis</entry>
2241               <entry>dynamic</entry>
2242               <entry>-</entry>
2243             </row>
2244             <row>
2245               <entry><option>-ddump-cse</option></entry>
2246               <entry>Dump CSE output</entry>
2247               <entry>dynamic</entry>
2248               <entry>-</entry>
2249             </row>
2250             <row>
2251               <entry><option>-ddump-deriv</option></entry>
2252               <entry>Dump deriving output</entry>
2253               <entry>dynamic</entry>
2254               <entry>-</entry>
2255             </row>
2256             <row>
2257               <entry><option>-ddump-ds</option></entry>
2258               <entry>Dump desugarer output</entry>
2259               <entry>dynamic</entry>
2260               <entry>-</entry>
2261             </row>
2262             <row>
2263               <entry><option>-ddump-flatC</option></entry>
2264               <entry>Dump &ldquo;flat&rdquo; C</entry>
2265               <entry>dynamic</entry>
2266               <entry>-</entry>
2267             </row>
2268             <row>
2269               <entry><option>-ddump-foreign</option></entry>
2270               <entry>Dump <literal>foreign export</literal> stubs</entry>
2271               <entry>dynamic</entry>
2272               <entry>-</entry>
2273             </row>
2274             <row>
2275               <entry><option>-ddump-hpc</option></entry>
2276               <entry>Dump after instrumentation for program coverage</entry>
2277               <entry>dynamic</entry>
2278               <entry>-</entry>
2279             </row>
2280             <row>
2281               <entry><option>-ddump-inlinings</option></entry>
2282               <entry>Dump inlining info</entry>
2283               <entry>dynamic</entry>
2284               <entry>-</entry>
2285             </row>
2286             <row>
2287               <entry><option>-ddump-llvm</option></entry>
2288               <entry>Dump LLVM intermediate code</entry>
2289               <entry>dynamic</entry>
2290               <entry>-</entry>
2291             </row>
2292             <row>
2293               <entry><option>-ddump-occur-anal</option></entry>
2294               <entry>Dump occurrence analysis output</entry>
2295               <entry>dynamic</entry>
2296               <entry>-</entry>
2297             </row>
2298             <row>
2299               <entry><option>-ddump-opt-cmm</option></entry>
2300               <entry>Dump the results of C-- to C-- optimising passes</entry>
2301               <entry>dynamic</entry>
2302               <entry>-</entry>
2303             </row>
2304             <row>
2305               <entry><option>-ddump-parsed</option></entry>
2306               <entry>Dump parse tree</entry>
2307               <entry>dynamic</entry>
2308               <entry>-</entry>
2309             </row>
2310             <row>
2311               <entry><option>-ddump-prep</option></entry>
2312               <entry>Dump prepared core</entry>
2313               <entry>dynamic</entry>
2314               <entry>-</entry>
2315             </row>
2316             <row>
2317               <entry><option>-ddump-rn</option></entry>
2318               <entry>Dump renamer output</entry>
2319               <entry>dynamic</entry>
2320               <entry>-</entry>
2321             </row>
2322             <row>
2323               <entry><option>-ddump-rule-firings</option></entry>
2324               <entry>Dump rule firing info</entry>
2325               <entry>dynamic</entry>
2326               <entry>-</entry>
2327             </row>
2328             <row>
2329               <entry><option>-ddump-rule-rewrites</option></entry>
2330               <entry>Dump detailed rule firing info</entry>
2331               <entry>dynamic</entry>
2332               <entry>-</entry>
2333             </row>
2334             <row>
2335               <entry><option>-ddump-rules</option></entry>
2336               <entry>Dump rules</entry>
2337               <entry>dynamic</entry>
2338               <entry>-</entry>
2339             </row>
2340             <row>
2341               <entry><option>-ddump-simpl</option></entry>
2342               <entry>Dump final simplifier output</entry>
2343               <entry>dynamic</entry>
2344               <entry>-</entry>
2345             </row>
2346             <row>
2347               <entry><option>-ddump-simpl-phases</option></entry>
2348               <entry>Dump output from each simplifier phase</entry>
2349               <entry>dynamic</entry>
2350               <entry>-</entry>
2351             </row>
2352             <row>
2353               <entry><option>-ddump-simpl-iterations</option></entry>
2354               <entry>Dump output from each simplifier iteration</entry>
2355               <entry>dynamic</entry>
2356               <entry>-</entry>
2357             </row>
2358             <row>
2359               <entry><option>-ddump-spec</option></entry>
2360               <entry>Dump specialiser output</entry>
2361               <entry>dynamic</entry>
2362               <entry>-</entry>
2363             </row>
2364             <row>
2365               <entry><option>-ddump-splices</option></entry>
2366               <entry>Dump TH spliced expressions, and what they evaluate to</entry>
2367               <entry>dynamic</entry>
2368               <entry>-</entry>
2369             </row>
2370             <row>
2371               <entry><option>-ddump-stg</option></entry>
2372               <entry>Dump final STG</entry>
2373               <entry>dynamic</entry>
2374               <entry>-</entry>
2375             </row>
2376             <row>
2377               <entry><option>-ddump-stranal</option></entry>
2378               <entry>Dump strictness analyser output</entry>
2379               <entry>dynamic</entry>
2380               <entry>-</entry>
2381             </row>
2382             <row>
2383               <entry><option>-ddump-tc</option></entry>
2384               <entry>Dump typechecker output</entry>
2385               <entry>dynamic</entry>
2386               <entry>-</entry>
2387             </row>
2388             <row>
2389               <entry><option>-ddump-types</option></entry>
2390               <entry>Dump type signatures</entry>
2391               <entry>dynamic</entry>
2392               <entry>-</entry>
2393             </row>
2394             <row>
2395               <entry><option>-ddump-worker-wrapper</option></entry>
2396               <entry>Dump worker-wrapper output</entry>
2397               <entry>dynamic</entry>
2398               <entry>-</entry>
2399             </row>
2400             <row>
2401               <entry><option>-ddump-if-trace</option></entry>
2402               <entry>Trace interface files</entry>
2403               <entry>dynamic</entry>
2404               <entry>-</entry>
2405             </row>
2406             <row>
2407               <entry><option>-ddump-tc-trace</option></entry>
2408               <entry>Trace typechecker</entry>
2409               <entry>dynamic</entry>
2410               <entry>-</entry>
2411             </row>
2412             <row>
2413               <entry><option>-ddump-rn-trace</option></entry>
2414               <entry>Trace renamer</entry>
2415               <entry>dynamic</entry>
2416               <entry>-</entry>
2417             </row>
2418             <row>
2419               <entry><option>-ddump-rn-stats</option></entry>
2420               <entry>Renamer stats</entry>
2421               <entry>dynamic</entry>
2422               <entry>-</entry>
2423             </row>
2424             <row>
2425               <entry><option>-ddump-simpl-stats</option></entry>
2426               <entry>Dump simplifier stats</entry>
2427               <entry>dynamic</entry>
2428               <entry>-</entry>
2429             </row>
2430             <row>
2431               <entry><option>-dno-debug-output</option></entry>
2432               <entry>Suppress unsolicited debugging output</entry>
2433               <entry>static</entry>
2434               <entry>-</entry>
2435             </row>
2436             <row>
2437               <entry><option>-dppr-debug</option></entry>
2438               <entry>Turn on debug printing (more verbose)</entry>
2439               <entry>static</entry>
2440               <entry>-</entry>
2441             </row>
2442             <row>
2443               <entry><option>-dsuppress-uniques</option></entry>
2444               <entry>Suppress the printing of uniques in debug output (easier to use <command>diff</command>.</entry>
2445               <entry>static</entry>
2446               <entry>-</entry>
2447             </row>
2448             <row>
2449               <entry><option>-dsuppress-coercions</option></entry>
2450               <entry>Suppress the printing of coercions in Core dumps to make them shorter.</entry>
2451               <entry>static</entry>
2452               <entry>-</entry>
2453             </row>
2454             <row>
2455               <entry><option>-dsuppress-module-prefixes</option></entry>
2456               <entry>Suppress the printing of module qualification prefixes in Core dumps to make them easier to read.</entry>
2457               <entry>static</entry>
2458               <entry>-</entry>
2459             </row>
2460             <row>
2461               <entry><option>-dppr-noprags</option></entry>
2462               <entry>Don't output pragma info in dumps</entry>
2463               <entry>static</entry>
2464               <entry>-</entry>
2465             </row>
2466             <row>
2467               <entry><option>-dppr-user-length</option></entry>
2468               <entry>Set the depth for printing expressions in error msgs</entry>
2469               <entry>static</entry>
2470               <entry>-</entry>
2471             </row>
2472             <row>
2473               <entry><option>-dsource-stats</option></entry>
2474               <entry>Dump haskell source stats</entry>
2475               <entry>dynamic</entry>
2476               <entry>-</entry>
2477             </row>
2478             <row>
2479               <entry><option>-dcmm-lint</option></entry>
2480               <entry>C-- pass sanity checking</entry>
2481               <entry>dynamic</entry>
2482               <entry>-</entry>
2483             </row>
2484             <row>
2485               <entry><option>-dstg-lint</option></entry>
2486               <entry>STG pass sanity checking</entry>
2487               <entry>dynamic</entry>
2488               <entry>-</entry>
2489             </row>
2490             <row>
2491               <entry><option>-dstg-stats</option></entry>
2492               <entry>Dump STG stats</entry>
2493               <entry>dynamic</entry>
2494               <entry>-</entry>
2495             </row>
2496             <row>
2497               <entry><option>-dverbose-core2core</option></entry>
2498               <entry>Show output from each core-to-core pass</entry>
2499               <entry>dynamic</entry>
2500               <entry>-</entry>
2501             </row>
2502             <row>
2503               <entry><option>-dverbose-stg2stg</option></entry>
2504               <entry>Show output from each STG-to-STG pass</entry>
2505               <entry>dynamic</entry>
2506               <entry>-</entry>
2507             </row>
2508             <row>
2509               <entry><option>-dshow-passes</option></entry>
2510               <entry>Print out each pass name as it happens</entry>
2511               <entry>dynamic</entry>
2512               <entry>-</entry>
2513             </row>
2514             <row>
2515               <entry><option>-dfaststring-stats</option></entry>
2516               <entry>Show statistics for fast string usage when finished</entry>
2517               <entry>dynamic</entry>
2518               <entry>-</entry>
2519             </row>
2520           </tbody>
2521         </tgroup>
2522       </informaltable>
2523     </sect2>
2524       
2525     <sect2>
2526       <title>Misc compiler options</title>
2527
2528       <informaltable>
2529         <tgroup cols="4" align="left" colsep="1" rowsep="1">
2530           <thead>
2531             <row>
2532               <entry>Flag</entry>
2533               <entry>Description</entry>
2534               <entry>Static/Dynamic</entry>
2535               <entry>Reverse</entry>
2536             </row>
2537           </thead>
2538           <tbody>
2539             <row>
2540               <entry><option>-fno-hi-version-check</option></entry>
2541               <entry>Don't complain about <literal>.hi</literal> file mismatches</entry>
2542               <entry>static</entry>
2543               <entry>-</entry>
2544             </row>
2545             <row>
2546               <entry><option>-dno-black-holing</option></entry>
2547               <entry>Turn off black holing (probably doesn't work)</entry>
2548               <entry>static</entry>
2549               <entry>-</entry>
2550             </row>
2551             <row>
2552               <entry><option>-fhistory-size</option></entry>
2553               <entry>Set simplification history size</entry>
2554               <entry>static</entry>
2555               <entry>-</entry>
2556             </row>
2557             <row>
2558               <entry><option>-funregisterised</option></entry>
2559               <entry>Unregisterised compilation (use <option>-unreg</option> instead)</entry>
2560               <entry>static</entry>
2561               <entry>-</entry>
2562             </row>
2563             <row>
2564               <entry><option>-fno-asm-mangling</option></entry>
2565               <entry>Turn off assembly mangling (use <option>-unreg</option> instead)</entry>
2566               <entry>dynamic</entry>
2567               <entry>-</entry>
2568             </row>
2569             <row>
2570               <entry><option>-fno-ghci-sandbox</option></entry>
2571               <entry>Turn off the GHCi sandbox. Means computations are run in teh main thread, rather than a forked thread.</entry>
2572               <entry>dynamic</entry>
2573               <entry>-</entry>
2574             </row>
2575           </tbody>
2576         </tgroup>
2577       </informaltable>
2578     </sect2>
2579   </sect1>
2580
2581
2582 <!--
2583 Still to document:
2584
2585 Misc:
2586   ,  ( "H"                 , HasArg (setHeapSize . fromIntegral . decodeSize) )
2587
2588   -Bdir
2589 -->
2590
2591 <!-- Emacs stuff:
2592      ;;; Local Variables: ***
2593      ;;; sgml-parent-document: ("users_guide.xml" "book" "chapter") ***
2594      ;;; End: ***
2595  -->