Re: prescheme & boehm leak detection?
Richard Kelsey <[email protected]> Tue, 12 Aug 2014 11:50:54 +0000
| Newsgroups | gmane.lisp.scheme.scheme48 |
|---|---|
| Message-ID | <[email protected]> |
Michael Sperber <[email protected]> writes: > Raoul Duke <[email protected]> writes: > >> http://hboehm.info/gc/leak.html >> >> so prescheme doesn't use a gc, but i am wondering... does it use >> malloc/free such that i could easily patch it to use boehm gc in the >> leak detection mode? >> >> i have downloaded the sources and am looking at them but remain >> stunningly clueless so far... > > I'm not aware that anyone has tried, but I don't see why it wouldn't > work. (Unless you use funky address arithmetic like the VM, of course.) > Also, I don't see why plugging in the Boehm GC shouldn't work. Just to be clear, compiled PreScheme programs do use malloc() and free(). If you look at prescheme/test/write.scm, 'allocate-memory' and 'deallocate-memory' compile to calls to malloc() and free(). As Mike says, it should work fine with Boehm's GC as long as your program doesn't itself do anything odd with pointers. -Richard