[m-rev.] diff: enable --generate-trail-ops-inline by default

Julien Fischer juliensf at cs.mu.OZ.AU
Mon Dec 19 13:11:44 AEDT 2005


On Mon, 19 Dec 2005, Julien Fischer wrote:

>
> Estimated hours taken: 1.2
> Branches: main
>
> Make --generate-trail-ops-inline the default for trailing with the high-level
> C backend.
>
> compiler/options.m:
> doc/user_guide.texi:
> 	Make --generate-trail-ops-inline the default.
>
> 	Document --no-generate-trail-ops-inline.
>

In addition to which this also requires:


compiler/mercury_compile.m:
	Disable --generate-trail-ops-inline for non-C backends.

Index: mercury_compile.m
===================================================================
RCS file: /home/mercury1/repository/mercury/compiler/mercury_compile.m,v
retrieving revision 1.369
diff -u -r1.369 mercury_compile.m
--- mercury_compile.m	16 Dec 2005 12:17:52 -0000	1.369
+++ mercury_compile.m	19 Dec 2005 02:09:35 -0000
@@ -3165,8 +3165,20 @@
     (
         UseTrail = yes,
         globals.io_lookup_bool_option(optimize_trail_usage, OptTrailUse, !IO),
-        globals.io_lookup_bool_option(generate_trail_ops_inline,
-            GenerateInline, !IO),
+        globals.io_get_target(Target, !IO),
+        (
+            Target = c,
+            globals.io_lookup_bool_option(generate_trail_ops_inline,
+                GenerateInline, !IO)
+        ;
+            % XXX Currently, we can only generate trail ops inline for
+            % the C backends.
+            %
+            ( Target = il
+            ; Target = java
+            ; Target = asm ),
+            GenerateInline = no
+        ),
         maybe_write_string(Verbose, "% Adding trailing operations...\n", !IO),
         maybe_flush_output(Verbose, !IO),
         process_all_nonimported_procs(
--------------------------------------------------------------------------
mercury-reviews mailing list
post:  mercury-reviews at cs.mu.oz.au
administrative address: owner-mercury-reviews at cs.mu.oz.au
unsubscribe: Address: mercury-reviews-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-reviews-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the reviews mailing list