Bill Allombert on Thu, 22 Jun 2017 00:22:46 +0200 |
[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]
Re: GMP memory allocation and Macaulay2 (cont.) |
On Wed, Jun 21, 2017 at 04:33:12PM -0400, Doug Torrance wrote: > Hello! > A while ago [1], I inquired about an segfaults when Macaulay2 is linked > against both PARI and GMP due to memory allocation issues. > > Note that I tried using the new-ish INIT_noINTGMPm option to pari_init_opts > when calling from Macaulay2 to no avail. > > I promised a backtrace to help identify the problem, but am only now getting > around to it. > > Here is the output from gdb: > (gdb) bt > #0 __GI___libc_free (mem=0xfffffffffffffff8) at malloc.c:2966 > #1 0x00007ffff40be12f in pari_var_close () > from /usr/lib/x86_64-linux-gnu/libpari-gmp-tls.so.5 > #2 0x00007ffff4102d7c in pari_close_opts () > from /usr/lib/x86_64-linux-gnu/libpari-gmp-tls.so.5 > #3 0x000055555559d239 in closepari () at pari-c.c:79 > #4 0x00007ffff7de8e7a in _dl_fini () at dl-fini.c:235 > #5 0x00007ffff2f03910 in __run_exit_handlers (status=status@entry=1, > listp=0x7ffff32675d8 <__exit_funcs>, > run_list_atexit=run_list_atexit@entry=true, > run_dtors=run_dtors@entry=true) > at exit.c:83 > #6 0x00007ffff2f0396a in __GI_exit (status=status@entry=1) at exit.c:105 > #7 0x00005555555f6d61 in system_exit (x=1) at system.d:78 > #8 0x000055555569e4b8 in Exit (err=<optimized out>) at interp.dd:575 > #9 0x00005555556a1197 in interp_process () at interp.dd:601 > #10 0x00005555555f59f0 in interpFunc (vargs2=<optimized out>) at M2lib.c:604 > #11 0x00005555558fa6ab in ThreadTask::run (this=0x5555561fada0, > thread=thread@entry=0x55555607d4d0) at supervisor.cpp:360 > #12 0x00005555558fa880 in SupervisorThread::threadEntryPoint ( > this=0x55555607d4d0) at supervisor.cpp:422 > #13 0x00005555558fad99 in SupervisorThread::threadEntryPoint ( > st=<optimized out>) at supervisor.hpp:96 > #14 0x00007ffff588c28e in GC_inner_start_routine () > from /usr/lib/x86_64-linux-gnu/libgc.so.1 > #15 0x00007ffff58873c2 in GC_call_with_stack_base () > from /usr/lib/x86_64-linux-gnu/libgc.so.1 > #16 0x00007ffff38f9494 in start_thread (arg=0x7fffed327700) > at pthread_create.c:333 > #17 0x00007ffff2fb6a8f in clone () > at ../sysdeps/unix/sysv/linux/x86_64/clone.S:97 > > Is this helpful? This does not seems related to GMP. Are you using thread ? Do you use the thread-safe version of PARI ? Cheers, Bill.