Dear Maintainer,
I tried to have a look at this issue and I saw
that the allocation takes place inside libdolfinx_real.so.2019.2,
inside /usr/include/eigen3/Eigen/src/Core/util/Memory.h.

But the failing free is done in libgmsh.so.4.7,
which uses ./contrib/eigen/Eigen/src/Core/util/Memory.h.

There seem to be a disagreement if the allocator is
already returning aligned addresses,
therefore one uses handmade_aligned_malloc,
but the free uses directly std::free() instead handmade_aligned_free.

Might this cause the issue?

Kind regards,
Bernhard


Allocation:
    (rr) bt
    #0  0x00007f2860acc19d in __GI___libc_malloc (bytes=<optimized out>) at 
malloc.c:3082
    #1  0x00007f285e7d2bdb in Eigen::internal::handmade_aligned_malloc 
(size=16) at /usr/include/eigen3/Eigen/src/Core/util/Memory.h:88
    #2  Eigen::internal::aligned_malloc (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:164
    #3  Eigen::internal::conditional_aligned_malloc<true> (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:214
    #4  Eigen::internal::conditional_aligned_new_auto<int, true> (size=4) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:374
    #5  Eigen::DenseStorage<int, -1, -1, 1, 0>::resize (rows=4, size=4, 
this=0x7ffe74198f58) at /usr/include/eigen3/Eigen/src/Core/DenseStorage.h:557
    ...

Free:
    (rr) bt
    #0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
    #1  0x00007f2860a67537 in __GI_abort () at abort.c:79
    #2  0x00007f2860ac0768 in __libc_message (action=action@entry=do_abort, 
fmt=fmt@entry=0x7f2860bcee31 "%s\n") at ../sysdeps/posix/libc_fatal.c:155
    #3  0x00007f2860ac7a5a in malloc_printerr (str=str@entry=0x7f2860bd1210 "double 
free or corruption (out)") at malloc.c:5347
    #4  0x00007f2860ac9088 in _int_free (av=0x7f2860c00b80 <main_arena>, p=0x23cb2f0, 
have_lock=<optimized out>) at malloc.c:4314
    #5  0x00007f2851183ad8 in Eigen::internal::aligned_free (ptr=<optimized 
out>) at ./contrib/eigen/Eigen/src/Core/util/Memory.h:177
    #6  Eigen::internal::conditional_aligned_free<true> (ptr=<optimized out>) 
at ./contrib/eigen/Eigen/src/Core/util/Memory.h:230
    #7  Eigen::internal::conditional_aligned_delete_auto<int, true> (size=<optimized 
out>, ptr=<optimized out>) at ./contrib/eigen/Eigen/src/Core/util/Memory.h:416
    #8  Eigen::DenseStorage<int, -1, -1, 1, 0>::~DenseStorage (this=0x7ffe74198f58, 
__in_chrg=<optimized out>) at ./contrib/eigen/Eigen/src/Core/DenseStorage.h:542
    ...

# Bullseye amd64 qemu VM 2021-02-11


apt update
apt dist-upgrade


apt install systemd-coredump valgrind mc rr gdb dolfinx-doc python3-gmsh
apt build-dep libc6
apt install libgmsh4-dbgsym libdolfinx-real2019.2-dbgsym

echo 1 > /proc/sys/kernel/perf_event_paranoid






mkdir /home/benutzer/source/libc6/orig -p
cd /home/benutzer/source/libc6/orig
apt source libc6
cd

mkdir /home/benutzer/source/libgmsh4/orig -p
cd /home/benutzer/source/libgmsh4/orig
apt source libgmsh4
cd







$ rr record python3 /usr/share/dolfinx/demo-python/gmsh/demo_gmsh.py
rr: Saving execution to trace directory 
`/home/benutzer/.local/share/rr/python3-0'.
double free or corruption (out)

Loguru caught a signal: SIGABRT
Abgebrochen



$ rr replay python3-0
GNU gdb (Debian 10.1-1.7) 10.1.90.20210103-git
Copyright (C) 2021 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
Type "show copying" and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<https://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
    <http://www.gnu.org/software/gdb/documentation/>.

For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from /usr/bin/python3.9...
(No debugging symbols found in /usr/bin/python3.9)
Really redefine built-in command "restart"? (y or n) [answered Y; input not 
from terminal]
Remote debugging using 127.0.0.1:22636
Reading symbols from /lib64/ld-linux-x86-64.so.2...
Reading symbols from 
/usr/lib/debug/.build-id/5b/e47e85c990f390b0dccb6ca9dc3e70f410dc6a.debug...
0x00007f2860de8090 in _start () from /lib64/ld-linux-x86-64.so.2
(rr) directory /home/benutzer/source/libc6/orig/glibc-2.31/malloc
Source directories searched: 
/home/benutzer/source/libc6/orig/glibc-2.31/malloc:$cdir:$cwd
(rr) directory /home/benutzer/source/libgmsh4/orig/gmsh-4.7.1+ds1
Source directories searched: 
/home/benutzer/source/libgmsh4/orig/gmsh-4.7.1+ds1:/home/benutzer/source/libc6/orig/glibc-2.31/malloc:$cdir:$cwd
(rr) set width 0
(rr) set pagination off
(rr) cont
Continuing.
double free or corruption (out)
[New Thread 10825.10830]
[New Thread 10825.10831]

Thread 1 received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50        return ret;
(rr) when
Current event: 16792
(rr) bt
#0  __GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
#1  0x00007f2860a67537 in __GI_abort () at abort.c:79
#2  0x00007f2860ac0768 in __libc_message (action=action@entry=do_abort, 
fmt=fmt@entry=0x7f2860bcee31 "%s\n") at ../sysdeps/posix/libc_fatal.c:155
#3  0x00007f2860ac7a5a in malloc_printerr (str=str@entry=0x7f2860bd1210 "double 
free or corruption (out)") at malloc.c:5347
#4  0x00007f2860ac9088 in _int_free (av=0x7f2860c00b80 <main_arena>, 
p=0x23cb2f0, have_lock=<optimized out>) at malloc.c:4314
#5  0x00007f2851183ad8 in Eigen::internal::aligned_free (ptr=<optimized out>) 
at ./contrib/eigen/Eigen/src/Core/util/Memory.h:177
#6  Eigen::internal::conditional_aligned_free<true> (ptr=<optimized out>) at 
./contrib/eigen/Eigen/src/Core/util/Memory.h:230
#7  Eigen::internal::conditional_aligned_delete_auto<int, true> 
(size=<optimized out>, ptr=<optimized out>) at 
./contrib/eigen/Eigen/src/Core/util/Memory.h:416
#8  Eigen::DenseStorage<int, -1, -1, 1, 0>::~DenseStorage (this=0x7ffe74198f58, 
__in_chrg=<optimized out>) at ./contrib/eigen/Eigen/src/Core/DenseStorage.h:542
#9  Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 1, 0, -1, 1> 
>::~PlainObjectBase (this=0x7ffe74198f58, __in_chrg=<optimized out>) at 
./contrib/eigen/Eigen/src/Core/PlainObjectBase.h:98
#10 Eigen::Matrix<int, -1, 1, 0, -1, 1>::~Matrix (this=0x7ffe74198f58, 
__in_chrg=<optimized out>) at ./contrib/eigen/Eigen/src/Core/Matrix.h:178
#11 Eigen::Transpositions<-1, -1, int>::~Transpositions (this=0x7ffe74198f58, 
__in_chrg=<optimized out>) at 
./contrib/eigen/Eigen/src/Core/Transpositions.h:158
#12 Eigen::PartialPivLU<Eigen::Matrix<double, -1, -1, 0, -1, -1> 
>::~PartialPivLU (this=0x7ffe74198f30, __in_chrg=<optimized out>) at 
./contrib/eigen/Eigen/src/LU/PartialPivLU.h:75
#13 Eigen::internal::compute_inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, -1>::run (matrix=..., result=...) at 
./contrib/eigen/Eigen/src/LU/InverseImpl.h:28
#14 0x00007f285118974f in 
Eigen::internal::Assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, 
-1>, 0, Eigen::Stride<0, 0> >, Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, 
-1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > >, 
Eigen::internal::assign_op<double, double>, Eigen::internal::Dense2Dense, 
void>::run (src=..., dst=...) at ./contrib/eigen/Eigen/src/LU/InverseImpl.h:310
#15 Eigen::internal::call_assignment_no_alias<Eigen::Map<Eigen::Matrix<double, 
-1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > >, Eigen::internal::assign_op<double, double> > 
(func=..., src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:836
#16 Eigen::internal::call_assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > >, Eigen::internal::assign_op<double, double> 
>(Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> 
>&, Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > > const&, Eigen::internal::assign_op<double, double> 
const&, 
Eigen::internal::enable_if<!Eigen::internal::evaluator_assume_aliasing<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double,
 -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > >, 
Eigen::internal::evaluator_traits<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double,
 -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > > >::Shape>::value, void*>::type) 
(func=..., src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:804
#17 Eigen::internal::call_assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > > > (src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:782
#18 Eigen::MatrixBase<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > 
>::operator=<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, 
-1>, 0, Eigen::Stride<0, 0> > > > (other=..., this=0x7ffe74199160) at 
./contrib/eigen/Eigen/src/Core/Assign.h:66
#19 fullMatrix<double>::invert (result=..., this=0x7ffe74199100) at 
./Numeric/fullMatrix.h:650
#20 (anonymous namespace)::generateLagrangeMonomialCoefficients (point=..., 
monomial=...) at ./Numeric/polynomialBasis.cpp:46
#21 polynomialBasis::polynomialBasis (this=0x20c8690, tag=<optimized out>) at 
./Numeric/polynomialBasis.cpp:104
#22 0x00007f28510f1bca in gmsh::model::mesh::getElementProperties 
(elementType=4, name=..., dim=@0x7f285eba5590: 0, order=@0x7f285eba5610: 0, 
numNodes=@0x7f285eba5710: 0, localNodeCoord=std::vector of length 0, capacity 
0, numPrimaryNodes=@0x7f285eba5f90: 0) at ./Common/gmsh.cpp:1841
#23 0x00007f2851cab640 in gmshModelMeshGetElementProperties 
(elementType=<optimized out>, elementName=0x7f285eba5510, dim=<optimized out>, 
order=<optimized out>, numNodes=<optimized out>, localNodeCoord=0x7f285eba5790, 
localNodeCoord_n=0x7f285eba5890, numPrimaryNodes=0x7f285eba5f90, 
ierr=0x7f285ebbf090) at ./api/gmshc.cpp:1124
#24 0x00007f285fcb8d1d in ?? () from /lib/x86_64-linux-gnu/libffi.so.7
#25 0x00007f285fcb8289 in ?? () from /lib/x86_64-linux-gnu/libffi.so.7
#26 0x00007f285fcd1340 in ?? () from 
/usr/lib/python3.9/lib-dynload/_ctypes.cpython-39-x86_64-linux-gnu.so
#27 0x00007f285fcc78d6 in ?? () from 
/usr/lib/python3.9/lib-dynload/_ctypes.cpython-39-x86_64-linux-gnu.so
#28 0x000000000051df4b in _PyObject_MakeTpCall ()
#29 0x0000000000517bf7 in _PyEval_EvalFrameDefault ()
#30 0x00000000005294e3 in _PyFunction_Vectorcall ()
#31 0x0000000000517537 in _PyEval_EvalFrameDefault ()
#32 0x0000000000510d0d in ?? ()
#33 0x0000000000510ab7 in _PyEval_EvalCodeWithName ()
#34 0x00000000005f5043 in PyEval_EvalCode ()
#35 0x0000000000619757 in ?? ()
#36 0x0000000000614f80 in ?? ()
#37 0x00000000006196e9 in ?? ()
#38 0x0000000000619186 in PyRun_SimpleFileExFlags ()
#39 0x000000000060ca03 in Py_RunMain ()
#40 0x00000000005e9b49 in Py_BytesMain ()
#41 0x00007f2860a68d0a in __libc_start_main (main=0x5e9b10, argc=2, 
argv=0x7ffe74199f58, init=<optimized out>, fini=<optimized out>, 
rtld_fini=<optimized out>, stack_end=0x7ffe74199f48) at ../csu/libc-start.c:308
#42 0x00000000005e9a4a in _start ()
(rr) reverse-finish
Run back to call of #0  __GI_raise (sig=sig@entry=6) at 
../sysdeps/unix/sysv/linux/raise.c:50

Thread 1 received signal SIGABRT, Aborted.
__GI_raise (sig=sig@entry=6) at ../sysdeps/unix/sysv/linux/raise.c:50
50        return ret;
(rr) 
Run back to call of #0  __GI_raise (sig=sig@entry=6) at 
../sysdeps/unix/sysv/linux/raise.c:50
0x00007f2860a67532 in __GI_abort () at abort.c:79
79      abort.c: Datei oder Verzeichnis nicht gefunden.
(rr) 
Run back to call of #0  0x00007f2860a67532 in __GI_abort () at abort.c:79
__libc_message (action=action@entry=do_abort, fmt=fmt@entry=0x7f2860bcee31 
"%s\n") at ../sysdeps/posix/libc_fatal.c:155
155         abort ();
(rr) 
Run back to call of #0  __libc_message (action=action@entry=do_abort, 
fmt=fmt@entry=0x7f2860bcee31 "%s\n") at ../sysdeps/posix/libc_fatal.c:155
0x00007f2860ac7a55 in malloc_printerr (str=str@entry=0x7f2860bd1210 "double 
free or corruption (out)") at malloc.c:5347
5347      __libc_message (do_abort, "%s\n", str);
(rr) 
Run back to call of #0  0x00007f2860ac7a55 in malloc_printerr 
(str=str@entry=0x7f2860bd1210 "double free or corruption (out)") at 
malloc.c:5347
0x00007f2860ac9083 in _int_free (av=0x7f2860c00b80 <main_arena>, p=0x23cb2f0, 
have_lock=<optimized out>) at malloc.c:4314
4314            malloc_printerr ("double free or corruption (out)");
(rr) 
Run back to call of #0  0x00007f2860ac9083 in _int_free (av=0x7f2860c00b80 
<main_arena>, p=0x23cb2f0, have_lock=<optimized out>) at malloc.c:4314
0x00007f2860acc777 in __GI___libc_free (mem=<optimized out>) at malloc.c:3125
3125      _int_free (ar_ptr, p, 0);
(rr) 
Run back to call of #0  0x00007f2860acc777 in __GI___libc_free (mem=<optimized 
out>) at malloc.c:3125
0x00007f2851183ad3 in Eigen::internal::aligned_free (ptr=0x23cb300) at 
./contrib/eigen/Eigen/src/Core/util/Memory.h:177
177         std::free(ptr);
(rr) list
172
173     /** \internal Frees memory allocated with aligned_malloc. */
174     EIGEN_DEVICE_FUNC inline void aligned_free(void *ptr)
175     {
176       #if (EIGEN_DEFAULT_ALIGN_BYTES==0) || EIGEN_MALLOC_ALREADY_ALIGNED
177         std::free(ptr);
178       #else
179         handmade_aligned_free(ptr);
180       #endif
181     }
(rr) b *(__GI___libc_malloc+173) if $rax == 0x23cb2f0

Breakpoint 1 at 0x7f2860acc19d: file malloc.c, line 3082.
(rr) 
Note: breakpoint 1 also set at pc 0x7f2860acc19d.
Breakpoint 2 at 0x7f2860acc19d: file malloc.c, line 3082.
(rr) dele 2
(rr) reverse-cont
Continuing.

Thread 1 hit Breakpoint 1, 0x00007f2860acc19d in __GI___libc_malloc 
(bytes=<optimized out>) at malloc.c:3082
3082    }
(rr) when
Current event: 16766
(rr) bt
#0  0x00007f2860acc19d in __GI___libc_malloc (bytes=<optimized out>) at 
malloc.c:3082
#1  0x00007f285e7d2bdb in Eigen::internal::handmade_aligned_malloc (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:88
#2  Eigen::internal::aligned_malloc (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:164
#3  Eigen::internal::conditional_aligned_malloc<true> (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:214
#4  Eigen::internal::conditional_aligned_new_auto<int, true> (size=4) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:374
#5  Eigen::DenseStorage<int, -1, -1, 1, 0>::resize (rows=4, size=4, 
this=0x7ffe74198f58) at /usr/include/eigen3/Eigen/src/Core/DenseStorage.h:557
#6  Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 1, 0, -1, 1> >::resize 
(size=4, this=0x7ffe74198f58) at 
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:319
#7  Eigen::PlainObjectBase<Eigen::Matrix<int, -1, 1, 0, -1, 1> 
>::_init1<long>(long, 
Eigen::internal::enable_if<((((Eigen::DenseBase<Eigen::Matrix<int, -1, 1, 0, 
-1, 1> >::{unnamed type#1})-1)!=(1))||(!Eigen::internal::is_convertible<long, 
int>::value))&&((!((Eigen::internal::is_same<Eigen::MatrixXpr, 
Eigen::ArrayXpr>::{unnamed type#1})0))||((({unnamed 
type#1})-1)==Eigen::Dynamic)), Eigen::internal::is_convertible>::type*) 
(size=4, this=0x7ffe74198f58) at 
/usr/include/eigen3/Eigen/src/Core/PlainObjectBase.h:782
#8  Eigen::Matrix<int, -1, 1, 0, -1, 1>::Matrix<long> (x=<synthetic pointer>: 
4, this=0x7ffe74198f58) at /usr/include/eigen3/Eigen/src/Core/Matrix.h:294
#9  Eigen::Transpositions<-1, -1, int>::Transpositions (size=4, 
this=0x7ffe74198f58) at /usr/include/eigen3/Eigen/src/Core/Transpositions.h:177
#10 Eigen::PartialPivLU<Eigen::Matrix<double, -1, -1, 0, -1, -1> 
>::PartialPivLU<Eigen::Matrix<double, -1, -1, 0, -1, -1> > 
(this=0x7ffe74198f30, matrix=...) at 
/usr/include/eigen3/Eigen/src/LU/PartialPivLU.h:321
#11 0x00007f2851183643 in Eigen::MatrixBase<Eigen::Map<Eigen::Matrix<double, 
-1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > >::partialPivLu (this=0x80) at 
./contrib/eigen/Eigen/src/Core/util/Meta.h:300
#12 Eigen::internal::compute_inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, -1>::run (matrix=..., result=...) at 
./contrib/eigen/Eigen/src/LU/InverseImpl.h:28
#13 0x00007f285118974f in 
Eigen::internal::Assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, 
-1>, 0, Eigen::Stride<0, 0> >, Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, 
-1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > >, 
Eigen::internal::assign_op<double, double>, Eigen::internal::Dense2Dense, 
void>::run (src=..., dst=...) at ./contrib/eigen/Eigen/src/LU/InverseImpl.h:310
#14 Eigen::internal::call_assignment_no_alias<Eigen::Map<Eigen::Matrix<double, 
-1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > >, Eigen::internal::assign_op<double, double> > 
(func=..., src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:836
#15 Eigen::internal::call_assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > >, Eigen::internal::assign_op<double, double> 
>(Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> 
>&, Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > > const&, Eigen::internal::assign_op<double, double> 
const&, 
Eigen::internal::enable_if<!Eigen::internal::evaluator_assume_aliasing<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double,
 -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > >, 
Eigen::internal::evaluator_traits<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double,
 -1, -1, 0, -1, -1>, 0, Eigen::Stride<0, 0> > > >::Shape>::value, void*>::type) 
(func=..., src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:804
#16 Eigen::internal::call_assignment<Eigen::Map<Eigen::Matrix<double, -1, -1, 
0, -1, -1>, 0, Eigen::Stride<0, 0> >, 
Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > > > (src=..., dst=...) at 
./contrib/eigen/Eigen/src/Core/AssignEvaluator.h:782
#17 Eigen::MatrixBase<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, -1>, 0, 
Eigen::Stride<0, 0> > 
>::operator=<Eigen::Inverse<Eigen::Map<Eigen::Matrix<double, -1, -1, 0, -1, 
-1>, 0, Eigen::Stride<0, 0> > > > (other=..., this=0x7ffe74199160) at 
./contrib/eigen/Eigen/src/Core/Assign.h:66
#18 fullMatrix<double>::invert (result=..., this=0x7ffe74199100) at 
./Numeric/fullMatrix.h:650
#19 (anonymous namespace)::generateLagrangeMonomialCoefficients (point=..., 
monomial=...) at ./Numeric/polynomialBasis.cpp:46
#20 polynomialBasis::polynomialBasis (this=0x20c8690, tag=<optimized out>) at 
./Numeric/polynomialBasis.cpp:104
#21 0x00007f28510f1bca in gmsh::model::mesh::getElementProperties 
(elementType=4, name=..., dim=@0x7f285eba5590: 0, order=@0x7f285eba5610: 0, 
numNodes=@0x7f285eba5710: 0, localNodeCoord=std::vector of length 0, capacity 
0, numPrimaryNodes=@0x7f285eba5f90: 0) at ./Common/gmsh.cpp:1841
#22 0x00007f2851cab640 in gmshModelMeshGetElementProperties 
(elementType=<optimized out>, elementName=0x7f285eba5510, dim=<optimized out>, 
order=<optimized out>, numNodes=<optimized out>, localNodeCoord=0x7f285eba5790, 
localNodeCoord_n=0x7f285eba5890, numPrimaryNodes=0x7f285eba5f90, 
ierr=0x7f285ebbf090) at ./api/gmshc.cpp:1124
#23 0x00007f285fcb8d1d in ?? () from /lib/x86_64-linux-gnu/libffi.so.7
#24 0x00007f285fcb8289 in ?? () from /lib/x86_64-linux-gnu/libffi.so.7
#25 0x00007f285fcd1340 in ?? () from 
/usr/lib/python3.9/lib-dynload/_ctypes.cpython-39-x86_64-linux-gnu.so
#26 0x00007f285fcc78d6 in ?? () from 
/usr/lib/python3.9/lib-dynload/_ctypes.cpython-39-x86_64-linux-gnu.so
#27 0x000000000051df4b in _PyObject_MakeTpCall ()
#28 0x0000000000517bf7 in _PyEval_EvalFrameDefault ()
#29 0x00000000005294e3 in _PyFunction_Vectorcall ()
#30 0x0000000000517537 in _PyEval_EvalFrameDefault ()
#31 0x0000000000510d0d in ?? ()
#32 0x0000000000510ab7 in _PyEval_EvalCodeWithName ()
#33 0x00000000005f5043 in PyEval_EvalCode ()
#34 0x0000000000619757 in ?? ()
#35 0x0000000000614f80 in ?? ()
#36 0x00000000006196e9 in ?? ()
#37 0x0000000000619186 in PyRun_SimpleFileExFlags ()
#38 0x000000000060ca03 in Py_RunMain ()
#39 0x00000000005e9b49 in Py_BytesMain ()
#40 0x00007f2860a68d0a in __libc_start_main (main=0x5e9b10, argc=2, 
argv=0x7ffe74199f58, init=<optimized out>, fini=<optimized out>, 
rtld_fini=<optimized out>, stack_end=0x7ffe74199f48) at ../csu/libc-start.c:308
#41 0x00000000005e9a4a in _start ()
(rr) finish
Run till exit from #0  0x00007f2860acc19d in __GI___libc_malloc 
(bytes=<optimized out>) at malloc.c:3082
Eigen::internal::handmade_aligned_malloc (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:89
89        if (original == 0) return 0;
Value returned is $1 = (void *) 0x23cb2f0
(rr) list
84        * Fast, but wastes 16 additional bytes of memory. Does not throw any 
exception.
85        */
86      inline void* handmade_aligned_malloc(std::size_t size)
87      {
88        void *original = std::malloc(size+EIGEN_DEFAULT_ALIGN_BYTES);
89        if (original == 0) return 0;
90        void *aligned = 
reinterpret_cast<void*>((reinterpret_cast<std::size_t>(original) & 
~(std::size_t(EIGEN_DEFAULT_ALIGN_BYTES-1))) + EIGEN_DEFAULT_ALIGN_BYTES);
91        *(reinterpret_cast<void**>(aligned) - 1) = original;
92        return aligned;
93      }
(rr) up
#1  Eigen::internal::aligned_malloc (size=16) at 
/usr/include/eigen3/Eigen/src/Core/util/Memory.h:164
164         result = handmade_aligned_malloc(size);
(rr) list 155
150     /** \internal Allocates \a size bytes. The returned pointer is 
guaranteed to have 16 or 32 bytes alignment depending on the requirements.
151       * On allocation error, the returned pointer is null, and 
std::bad_alloc is thrown.
152       */
153     EIGEN_DEVICE_FUNC inline void* aligned_malloc(std::size_t size)
154     {
155       check_that_malloc_is_allowed();
156
157       void *result;
158       #if (EIGEN_DEFAULT_ALIGN_BYTES==0) || EIGEN_MALLOC_ALREADY_ALIGNED
159         result = std::malloc(size);
(rr) 
160         #if EIGEN_DEFAULT_ALIGN_BYTES==16
161         eigen_assert((size<16 || (std::size_t(result)%16)==0) && "System's 
malloc returned an unaligned pointer. Compile with 
EIGEN_MALLOC_ALREADY_ALIGNED=0 to fallback to handmade alignd memory 
allocator.");
162         #endif
163       #else
164         result = handmade_aligned_malloc(size);
165       #endif
166
167       if(!result && size)
168         throw_std_bad_alloc();
169
(rr) 
170       return result;
171     }
172
173     /** \internal Frees memory allocated with aligned_malloc. */
174     EIGEN_DEVICE_FUNC inline void aligned_free(void *ptr)
175     {
176       #if (EIGEN_DEFAULT_ALIGN_BYTES==0) || EIGEN_MALLOC_ALREADY_ALIGNED
177         std::free(ptr);
178       #else
179         handmade_aligned_free(ptr);
(rr) display/i $pc
1: x/i $pc
=> 0x7f285e7d2bdb 
<_ZN5Eigen12PartialPivLUINS_6MatrixIdLin1ELin1ELi0ELin1ELin1EEEEC2IS2_EERKNS_9EigenBaseIT_EE+1483>:
   mov    -0x60(%rbp),%r8
(rr) info share
From                To                  Syms Read   Shared Object Library
...
0x00007f2850fe9110  0x00007f2851cbce4e  Yes         
/lib/x86_64-linux-gnu/libgmsh.so.4.7
...
0x00007f285e778b20  0x00007f285e8ad79e  Yes         
/lib/x86_64-linux-gnu/libdolfinx_real.so.2019.2
...
(*): Shared library is missing debugging information.



# dpkg -S /usr/lib/x86_64-linux-gnu/libgmsh.so.4.7
libgmsh4:amd64: /usr/lib/x86_64-linux-gnu/libgmsh.so.4.7
# dpkg -S /usr/lib/x86_64-linux-gnu/libdolfinx_real.so.2019.2
libdolfinx-real2019.2:amd64: /usr/lib/x86_64-linux-gnu/libdolfinx_real.so.2019.2
# dpkg -l | grep -E "libgmsh4|libdolfinx-real2019.2"
ii  libdolfinx-real2019.2:amd64            2019.2.0~git20201109.17bda9f-6 amd64 
       Shared libraries for DOLFIN
ii  libdolfinx-real2019.2-dbgsym:amd64     2019.2.0~git20201109.17bda9f-6 amd64 
       debug symbols for libdolfinx-real2019.2
ii  libgmsh4:amd64                         4.7.1+ds1-2                    amd64 
       Three-dimensional finite element mesh generator shared library
ii  libgmsh4-dbgsym:amd64                  4.7.1+ds1-2                    amd64 
       debug symbols for libgmsh4

Reply via email to