bug-glpk
[Top][All Lists]
Advanced

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

Re: [Bug-glpk] [Fwd: Bug in GLPK Graph]


From: Andrew Makhorin
Subject: Re: [Bug-glpk] [Fwd: Bug in GLPK Graph]
Date: Tue, 01 Aug 2017 16:54:37 +0300

Thank you for your bug report.

> I was using the Graph method with the algorithm Relax-IV from GLPK 4.60
>  with successful results.
> But now, when I migrate to GLPK 4.63, the same code is causing a error:
> 
> 
> glp_free: memory allocation error
> Error detected in file ..\svr\env\alloc.c at line 72
> 
> 
> This occur when I call one of both functions:
> 
> 
> glp_delete_v_index
> glp_delete_graph
> 
> 

There were no changes between 4.60 and 4.63 regarding these functions,
so this looks like a latent bug which was not observed before.

Please note that there is a bug in the original RELAX IV Fortran code,
which I tried to fix with a brute force changes; see
https://lists.gnu.org/archive/html/bug-glpk/2013-04/msg00009.html
(I reported this bug to Prof. Bertsekas, the author of RELAX IV,
however, he was not able to help me, because the code was written a long
time ago, and he just didn't remember details.)

Also it may happen that the bug in your code, so please check it more
carefully. The message "glp_free: memory allocation error" means that
the header of some dynamically allocated block was clobbered by using an
invalid pointer to store data.

> 
> I hope I can help with the improvement of the tool.
> 

If you wish to help, please try to replace a call to glp_mincost_relax4
by a call to glp_mincost_okalg that solves the same problem. If the bug
will disappear, it is most likely in RELAX IV code. If not, it is most
likely in your code. You also may try to use valgrind to obtain a more
detailed information about the bug. In any case, please report your
results. Thanks.


Andrew Makhorin




reply via email to

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