[m-rev.] for review: IL back-end: options for verifiable code

Tyson Dowd trd at cs.mu.OZ.AU
Thu Aug 2 20:04:38 AEST 2001


On 02-Aug-2001, Fergus Henderson <fjh at cs.mu.OZ.AU> wrote:
> This patch is basically a revised and extended version of the one that I posted
> earlier for putting nondet environments on the stack rather than the heap.
> It addresses Tyson's concerns about keeping things verifiable by introducing
> a bunch of options related to generating verifiable code.
> 

Thanks, this is nice.

> There's a couple of things I still need to fix in mlds_to_il.m
> (I've done them before in different patches but haven't yet
> merged them into this patch) which are marked with XXXs below,
> but I'd appreciate any review comments at this stage.
> 
> ----------
> 
> Improve the support for generating verifiable code and/or efficient but
> unverifiable code for the IL back-end.
> 
> We now allocate nondet environments on the stack by default, but they will get
> allocated on the heap if you specify --verifiable-code.
> 
> compiler/options.m:
> 	Add several new options:
> 		--verifiable-code
> 		--il-funcptr-types
> 		--il-refany-fields
> 		--il-byref-tailcalls
> 		--put-nondet-env-on-heap
> 	Currently these are all not officially documented, for various reasons,
> 	so I have not yet added grade components for any of these options.
> 
> compiler/handle_options.m:
> 	Set --put-nondet-env-on-heap if --verifiable-code is specified,
> 	unless both --il-funcptr-types and --il-refany-fields are specified.
> 
> compiler/ml_elim_nested.m:
> 	Support the --put-nondet-env-on-heap option:
> 	allocate the environment on the stack by default.
> 
> compiler/mlds_to_il.m:
> 	Add a new field to the il_data_rep_type to handle the different
> 	representations for the environment pointer types.
> 	Add a new procedure get_il_data_rep for computing it.
> 
> 	XXX TODO: handle casts to/from refany
> 	XXX TODO: handle casts to/from unmanaged pointers (don't cast)
> 
> compiler/mlds_to_csharp.m
> compiler/mlds_to_mcpp.m
> 	Use get_il_data_rep rather than constructing it manually.
> 

The change looks good, thanks.

Tyson.
--------------------------------------------------------------------------
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