malloc+utrace, tracking memory leaks in a running program.

Konstantin Belousov kostikbel at gmail.com
Thu Jan 10 07:39:03 UTC 2013


On Thu, Jan 10, 2013 at 01:56:48AM -0500, Alfred Perlstein wrote:
> Here are more convenient links that give diffs against FreeBSD and 
> jemalloc for the proposed changes:
> 
> FreeBSD:
> https://github.com/alfredperlstein/freebsd/compare/13e7228d5b83c8fcfc63a0803a374212018f6b68~1...utrace2
> 
Why  do you need to expedite the records through the ktrace at all ?
Wouldn't direct write(2)s to a file allow for better performance
due to not stressing kernel memory allocator and single writing thread ?
Also, the malloc coupling to the single-system interface would be
prevented.

I believe that other usermode tracers also behave in the similar way,
using writes and not private kernel interface.

Also, what /proc issues did you mentioned ? There is
sysctl kern.proc.vmmap which is much more convenient than /proc/pid/map
and does not require /proc mounted.

> jemalloc:
> https://github.com/alfredperlstein/jemalloc/compare/master...utrace2
> 
> -Alfred
> 
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 834 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20130110/d6423f68/attachment.sig>


More information about the freebsd-hackers mailing list