-
-
Notifications
You must be signed in to change notification settings - Fork 481
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix refcounting of libsingular rings #13450
Comments
comment:1
duplicate of #13447? |
Reviewer: Nils Bruin |
comment:3
I guess that makes it a positive review with you as reviewer, with the suggested resolution "duplicate of #13447 ". |
comment:5
Jeroen, why "sage-pending"? It is clear that this ticket is a duplicate of #13447. |
comment:6
Replying to @simon-king-jena:
Then the milestone should be set to sage-duplicate/invalid/wontfix. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
While working on #715/#11521, a sporadic error has occurred:
On bsd.math (hence, OS X on Intel chips),
sage -t sage/misc/cachefunc.pyx
fails with signal 11. Apparently it is fine on different machines, even though with additional patches (such as #13370 or #12876) there are signal 11 in other tests and on other machines as well.The segfault disappears when running the tests in verbose mode. It also disappears if the tests are run under gdb (but then a different error occurs, that is unrelated with the problem we are dealing with here).
Nils (see #715) was able to track the problem down to libsingular. He found (correct me if I misunderstood):
A segfault occurs in
MPolynomialRing_libsingular.__init__
in the line:Digging deeper, he came to
sage/libs/singular/ring.pyx
in the lines:Strange enough, the segfault occurs in
omStrDup
.He found several ways to work around:
sage/libs/singular/ring.pyx
, copy the strings manually, such asprovided that the parameter
perturb
is at least 7.2. Modify manual refcounting in
sage/libs/singular/ring.pyx
to prevent deallocation:Options 2. and 3. would not be nice: The aim of #715, #11521, #12215 and #12313 was to make caches for parents weak in order to prevent memory leaks.
Since the problem disappears when deallocation of libsingular rings is prevented, it seems that the bug is in the deallocation of libsingular rings. Note that the problem is not fixed by #13145.
I don't know if it is an upstream bug or a bug in the Sage library. Hence, no idea what to report upstream.
Depends on #11521
Upstream: None of the above - read trac for reasoning.
CC: @nbruin @malb
Component: commutative algebra
Reviewer: Nils Bruin
Issue created by migration from https://trac.sagemath.org/ticket/13450
The text was updated successfully, but these errors were encountered: