[m-rev.] for review: deep profiling fixes, determinism algorithm change

Fergus Henderson fjh at cs.mu.OZ.AU
Tue Aug 13 20:58:03 AEST 2002


On 13-Aug-2002, Zoltan Somogyi <zs at cs.mu.OZ.AU> wrote:
> runtime/mercury_deep_profiling.[ch]:
> 	Add two extra arguments to MR_deep_assert, and print them if an
> 	assertion fails. This makes it easier to decide what p

The log message there is incomplete.

> Index: compiler/det_analysis.m
...
> +	(
> +		MaxSolns0 \= at_most_zero,
> +		MaxSolns1 = at_most_zero,
> +		goal_info_has_feature(GoalInfo, preserve_backtrack_into)
> +	->
> +		AdjMaxSolns1 = at_most_one
> +	;
> +		AdjMaxSolns1 = MaxSolns1
> +	),

There should be a comment there.

> Index: compiler/hlds_goal.m
...
> @@ -715,6 +724,8 @@
>  				% determinism analysis say that the
>  				% nondeterminism inside the some() should be
>  				% exposed to the environment outside.
> +	;	preserve_backtrack_into
> +				% This
>  	;	tailcall.	% This goal represents a tail call. This marker
>  				% is used by deep profiling.

The comment there is incomplete.

> +++ runtime/mercury_wrapper.h	2002/08/12 08:03:20
> @@ -229,8 +229,24 @@
>  /* low level debugging */
>  extern	MR_bool		MR_check_space;
>  extern	MR_Word		*MR_watch_addr;
> -extern	MR_Word		*MR_watch_csd_addr;
> -extern	int		MR_watch_csd_ignore;
> +extern	MR_CallSiteDynamic
> +			*MR_watch_csd_addr;
> +extern	MR_bool		MR_watch_csd_started;
> +extern	char		*MR_watch_csd_start_name;
> +
> +extern	unsigned long	MR_lld_cur_call;
> +extern	int		MR_lld_print_enabled;
> +extern	int		MR_lld_print_name_enabled;
> +extern	int		MR_lld_print_csd_enabled;
> +extern	int		MR_lld_print_region_enabled;

They should be bool rather than int.
Also, there should be comments explaining what each of them mean.

> +extern	char		*MR_lld_start_name;
> +extern	unsigned	MR_lld_start_block;
> +extern	unsigned long	MR_lld_start_until;
> +extern	unsigned long	MR_lld_csd_until;
> +extern	unsigned long	MR_lld_print_min;
> +extern	unsigned long	MR_lld_print_max;
> +extern	char		*MR_lld_print_more_min_max;

Likewise comments here.

[... to be continued ...]

-- 
Fergus Henderson <fjh at cs.mu.oz.au>  |  "I have always known that the pursuit
The University of Melbourne         |  of excellence is a lethal habit"
WWW: <http://www.cs.mu.oz.au/~fjh>  |     -- the last words of T. S. Garp.
--------------------------------------------------------------------------
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