[mercury-users] Another Mercury Modes Problem

Bob McKay bob_mckay at mac.com
Fri May 31 15:15:59 AEST 2002


On Friday, May 31, 2002, at 01:04 PM, Ralph Becket wrote:

> Bob McKay, Friday, 31 May 2002:
>>
>> This seems to be the killer for what I am trying to do.
>
> Uniqueness provides two things: the potential for more efficient
> update-in-place (only realized in arrays, stores and hash tables in the
> current release) and the imposition of a linear processing order.
>
> The former does not appear to be necessary in this case.
>
> It's not clear that the latter is required, either.
>
> Why not just forget about uniqueness?
>
Hi Ralph; I'd come to the conclusion I would have to switch to arrays
for just this reason. Typically, individuals might occupy a few K
(in my main application, they will be resolution clause sets). I
expect to need to run populations of a few thousand. So we're likely
up in the 10s of MB. Assuming that I will need to run for hundreds
or thousands of generations, then destructive update of this main
data structure is going to be crucial.

However I had decided to try to get the module structure right first,
before I switched representations. The underlying issue, that I will
need parametric modes, is still there I think. But perhaps I should
go the other way, switch to arrays first, then try to fix up the
module structure. Maybe some of the built-in array modes will solve
the problem for me (I haven't really looked at the arrays library
yet).

The underlying issue, though, seems to be an important one for
Mercury: I can't really see the point of having parametric types
and parametric insts if you can't have parametric modes, or at least
not parametric ones that involve unique or ground. Or am I
missing something here?

	Best Wishes
	Bob

--------------------------------------------------------------------------
mercury-users mailing list
post:  mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe:   Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------



More information about the users mailing list