[GenABEL-dev] patch for bug #2525

L.C. Karssen lennart at karssen.org
Tue May 14 19:13:24 CEST 2013


Dear Yurii,

I just tested export.plink() in the development version of GenABEL (SVN
r1214) to see if it still leaks memory, so bug 2055 isn't fixed by
Vladimir's fix, unfortunately.

FYI, to check this I ran:
library(GenABEL)
data(srdta)
export.plink(data=srdta, filebasename="plink", transpose=FALSE)

If you repeat the last statements a couple of times you'll see R's
memory use increase and only decrease when you exit R.

No idea about a unittest for this... Valgrind should be able to track
it. I'll have to read up on using Valgrind with C code in R...


Best,

Lennart.

On 04-04-13 13:44, Yurii Aulchenko wrote:
> Thank you, Vladimir! - nice fix! 
> 
> Lennart, I wonder if this fix somehow also address the export.plink bug
> #2055 discussed earlier. I also wonder what kind of unit test one can
> introduce for such 'memory leak' problem...
> 
> Below please find description of testing of the patch and some minor
> changes I introduced. I have updated the code on SVN
> (http://lists.r-forge.r-project.org/pipermail/genabel-commits/2013-April/000575.html)
> and closed the bug. 
> 
> best wishes,
> Yurii
> 
> I have added a unit test for this bug in r. 1185,
> see http://lists.r-forge.r-project.org/pipermail/genabel-commits/2013-April/000574.html)
> 
> Then I ran unit tests without applying the patch yet by 
> 
> cd pkg/GenABEL/inst/unitTests
> make
> 
> which gave me - as expected - 
> 
> GenABEL unit testing - 20 test functions, 1 error, 2 failures
> FAILURE in test.export.merlin.bug2525: Error in checkIdentical(xN, xO) :
> FALSE 
> FAILURE in test.exports: Error in checkIdentical(xN, xO) : FALSE 
> ERROR in test.impute2databel: Error in .Call("iterator",
> 
> (you can also check report.html for details; the FAILURE's are related
> to the bug 2525, and the ERROR is related to other bug, so our aim is to
> eliminate these FAILURES)
> 
> Next (from ../../../) I have applied the patch by 
> 
> patch -p0 -i ~/Downloads/patch_2525
> 
> and run unit tests again by
> 
> cd pkg/GenABEL/inst/unitTests
> make
> 
> which gave me 
> 
> GenABEL unit testing - 20 test functions, 1 error, 0 failures
> ERROR in test.impute2databel: Error in .Call("iterator",
> 
> which I thought was good - basically the test FAILURES were eliminated.
> 
> Now, the patch as submitted prints out much debugging (?) related staff
> to STDOUT, so next I commented out Rprintf's and ran the tests agin,
> getting 
> 
> GenABEL unit testing - 20 test functions, 1 error, 0 failures
> ERROR in test.impute2databel: Error in .Call("iterator", 
> 
> So, I conclude that the bug is fixed!
> 
> 
> On Wed, Apr 3, 2013 at 4:54 PM, Vladimir Naumov <looongdog at gmail.com
> <mailto:looongdog at gmail.com>> wrote:
> 
>     http://r-forge.r-project.org/tracker/index.php?func=detail&aid=2525&group_id=505&atid=2058
> 
> 
>     It was problem with cycle that didn't renew sex values - so they
>     were periodically written into output file with period of 100 (by
>     default) 
> 
>     -- 
>     Vladimir Naumov
>     0079156727733
>     Skype: snow_wow
> 
> 
>     _______________________________________________
>     genabel-devel mailing list
>     genabel-devel at lists.r-forge.r-project.org
>     <mailto:genabel-devel at lists.r-forge.r-project.org>
>     https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/genabel-devel
> 
> 
> 
> 
> -- 
> -----------------------------------------------------
> Yurii S. Aulchenko
> 
> [ LinkedIn <http://nl.linkedin.com/in/yuriiaulchenko> ] [ Twitter
> <http://twitter.com/YuriiAulchenko> ] [ Blog
> <http://yurii-aulchenko.blogspot.nl/> ]
> 
> 
> _______________________________________________
> genabel-devel mailing list
> genabel-devel at lists.r-forge.r-project.org
> https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/genabel-devel
> 

-- 
-----------------------------------------------------------------
L.C. Karssen
Utrecht
The Netherlands

lennart at karssen.org
http://blog.karssen.org

Stuur mij aub geen Word of Powerpoint bestanden!
Zie http://www.gnu.org/philosophy/no-word-attachments.nl.html
------------------------------------------------------------------

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 230 bytes
Desc: OpenPGP digital signature
URL: <http://lists.r-forge.r-project.org/pipermail/genabel-devel/attachments/20130514/ff966e62/attachment.sig>


More information about the genabel-devel mailing list