[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Excessive copies of set elements in GMPL

From: Andrew Makhorin
Subject: Re: Excessive copies of set elements in GMPL
Date: Thu, 16 Jul 2020 23:01:39 +0300

> After doing some experimentation I think I found an easy way to 
> eliminate unnecessary set copies here is a commit on 
> b17cf2ded40, 
> also see bellow, glpsol now uses 1/3 of the memory and is slight
> faster:

Please note that in the MathProg translator there are two ways used to
pass array objects: by reference, when no copy is created, and by
value, when a copy is created. In the latter case it is assumed that
the routine may change the object passed (directly or indirectly), so
I'm not sure that your approach based on using reference counts will
work correctly in a general case.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]