#13731: Fix libsingular memory management
---------------------------+------------------------------------------------
Reporter: nbruin | Owner: rlm
Type: defect | Status: new
Priority: major | Milestone: sage-5.6
Component: memleak | Resolution:
Keywords: | Work issues:
Report Upstream: N/A | Reviewers:
Authors: | Merged in:
Dependencies: | Stopgaps:
---------------------------+------------------------------------------------
Comment (by SimonKing):
I managed to build Sage with Singular-malloc. What I did to make it work:
* open the spkg
* remove all autogenerated files
* change src/omalloc/Makefile.in so that the freshly built `omMalloc.h`
is installed in `$(includedir)/omalloc` (creating that directory first)
Apparently the singular executable is not usable (when I try to start it,
it simply seems to hang).
I can reproduce the crash from the ticket description:
{{{
simon@linux-sqwp:~/SAGE/debug/sage-5.5.rc0> export MALLOC_CHECK_=3
simon@linux-sqwp:~/SAGE/debug/sage-5.5.rc0> ./sage
----------------------------------------------------------------------
| Sage Version 5.5.rc0, Release Date: 2012-11-17 |
| Type "notebook()" for the browser-based notebook interface. |
| Type "help()" for help. |
----------------------------------------------------------------------
**********************************************************************
* *
* Warning: this is a prerelease version, and it may be unstable. *
* *
**********************************************************************
sage: A.<x,y> = FreeAlgebra(QQ, 2)
sage: P.<x,y> = A.g_algebra({y*x:-x*y})
sage: x*y
*** glibc detected *** python: free(): invalid pointer: 0x0000000002806c90
***
======= Backtrace: =========
/lib64/libc.so.6(+0x766d6)[0x7fa9ed9cc6d6]
/home/simon/SAGE/debug/sage-5.5.rc0/local/lib/libsingular.so(_Z14gnc_mm_Mult_nnPiS_P9sip_sring+0x294)[0x7fa9d35c7c54]
/home/simon/SAGE/debug/sage-5.5.rc0/local/lib/libsingular.so(_Z20gnc_p_Mult_mm_CommonP8spolyrecS0_iP9sip_sring+0x1ec)[0x7fa9d35c8acc]
/home/simon/SAGE/debug/sage-5.5.rc0/local/lib/python2.7/site-
packages/sage/libs/singular/polynomial.so(+0x4bd0)[0x7fa9d29a9bd0]
/home/simon/SAGE/debug/sage-5.5.rc0/local/lib/python2.7/site-
packages/sage/rings/polynomial/plural.so(+0x1fbd8)[0x7fa9d2deebd8]
/home/simon/SAGE/debug/sage-5.5.rc0/local/lib/python2.7/site-
packages/sage/structure/element.so(+0x2a399)[0x7fa9e4bed399]
...
}}}
So, that's a good platform to try to hunt the Heisenbugs from #12215, #715
and friends once and for all.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/13731#comment:16>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica,
and MATLAB
--
You received this message because you are subscribed to the Google Groups
"sage-trac" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/sage-trac?hl=en.