[Openmcl-devel] CCL crash in GSLL
Daniel Herring
dherring at tentpost.com
Thu Jul 8 18:59:17 PDT 2010
On Thu, 24 Jun 2010, Gary Byers wrote:
> Linux's malloc implementation has a facility ("mtrace") that causes all calls
> to malloc/free/realloc/... to be logged to a file; CCL has some utilites
> that can parse this log file and report some kinds of inconsistencies. The
> wiki page <http://trac.clozure.com/ccl/wiki/MemoryLeaks> describes thes
> facilities. (I think that it's safe to ignore the claim that those tools
> are only available in a development branch, and that they've been in the
> trunk/releases for a while now.)
...
> If none of this gets you anywhere ... well, the only thing that I can say
> is that this sort of thing can be very hard to debug.
Valgrind may be another tool worth using.
- Daniel
P.S. There don't appear to be many places in gsll that free memory; it
may be possible to trace all of them. Or put a trace on every function in
the package and see which one is called last.
path: ~/lisp/gsll
# git grep free | grep -v software | grep -v freedom
and a few other lines removed
data/combination.lisp: (tg:finalize object (lambda () (cffi:foreign-free mptr)))))
data/marray.lisp: (cffi:foreign-free blockptr)
data/marray.lisp: (cffi:foreign-free array-struct)))))))
data/permutation.lisp: (tg:finalize object (lambda () (cffi:foreign-free mptr)))))
init/mobject.lisp: arglists-function inputs gsl-version allocator allocate-inputs freer
init/mobject.lisp: class cl-alloc-args cl-initialize-args prefix freer)
init/mobject.lisp: (class cl-alloc-args cl-initialize-args prefix freer)
init/mobject.lisp: ,(or freer (format nil "~a_free" prefix))
init/mobject.lisp: (cffi:foreign-free ,cbstruct))))))
ordinary-differential-equations/control.lisp: :freer "gsl_odeiv_control_free"
ordinary-differential-equations/control.lisp: :freer "gsl_odeiv_control_free"
ordinary-differential-equations/control.lisp: :freer "gsl_odeiv_control_free"
ordinary-differential-equations/control.lisp: :freer "gsl_odeiv_control_free"
More information about the Openmcl-devel
mailing list