ecl.pyx should not touch SIGPWR neither SIGXCPU when initializing ecl
|Reported by:||pcpa||Owned by:||was|
|Authors:||Paulo César Pereira de Andrade||Reviewers:||Nils Bruin|
|Report Upstream:||N/A||Work issues:|
Description (last modified by leif)
I experienced a problem in the Mandriva sagemath 4.7.1 that was causing sage to exit with the this somewhat funny message:
sage: from sage.interfaces.maxima_lib import maxima_lib
/usr/share/sage/local/bin/sage-sage: line 178: 7177 Power failure sage-ipython "$@" -i
The problem is the logic in ecl.pyx that saves all signal handlers, initializes ecl and restores them, but this has the nasty side effect of messing with Boehm GC thread handling, that uses SIGXCPU and SIGPWR to stop/restart threads during gc.The attached patch corrects the problem for me, but is just a suggestion, and may need proper testing on non Linux systems, but on other systems Boehm GC should use a signal number larger than 32. Or, maybe add some comments about what those numbers are (SIGPWR = 30 and SIGXCPU = 24).
Solution turned out to be: tell ECL not to create a separate signal-handling thread (which it won't do if threads are not enabled, as in the standard Sage build of ECL).
Change History (22)
Changed 2 years ago by pcpa
comment:11 Changed 2 years ago by nbruin
- Priority changed from major to minor
- Reviewers set to Nils Bruin
- Status changed from new to needs_review