[mercury-users] Strange performance anomaly; can anyone confirm?
Chris King
colanderman at gmail.com
Mon Mar 28 22:06:43 AEDT 2011
On Mon, Mar 28, 2011 at 12:52 AM, Peter Wang <novalazy at gmail.com> wrote:
> Below is the diff of the HLDS dumps (mmc -dall) at a certain stage.
> Without the conditional, the set.insert call is not being delayed til
> after the set.member check, as would be expected.
>
> The workaround is to write the construction at the end of the
> predicate instead of in the head.
A-ha! I never thought of that; makes sense. I was assuming bindings
in the head were by default ordered last. Shows what happens when one
assumes... :)
Thanks!
- Chris
--------------------------------------------------------------------------
mercury-users mailing list
Post messages to: mercury-users at csse.unimelb.edu.au
Administrative Queries: owner-mercury-users at csse.unimelb.edu.au
Subscriptions: mercury-users-request at csse.unimelb.edu.au
--------------------------------------------------------------------------
More information about the users
mailing list