Repository navigation
do not use valgrind for initial pass /return values from fail/pass/crash parsing #62
Description
Activity
From what I understand we should not use Valgrind in the compile, analyze steps, and use the inputs from the analyze step and run it with Valgrind.
This is a good approach as we don't really use the log generated in the first step of the compilation.
I can implement this for next time.- changed the title
[-]do not use valgrind for initial pass[/-][+]do not use valgrind for initial pass /return values from fail/pass/crash parsing[/+]on Oct 14, 2020 > data.table(input_file="~/R/RcppExports/packages/BNSL/inst/testfiles/mi/mi_output/00f6ebd2f636a3f88055f63e4ea26fc6fbce6906.pass", input_list=list(list(x=c(1, 5 , NA), y=1:10)), trace=list(data.table(file.line="mi.cpp:55", msg="stack overflow"))) input_file 1: ~/R/RcppExports/packages/BNSL/inst/testfiles/mi/mi_output/00f6ebd2f636a3f88055f63e4ea26fc6fbce6906.pass input_list trace 1: <list[2]> <data.table[1x2]> >
suggested data type return value for one pass/crash/fail file = 1 row data table
(several pass/fail/crash files should result in a data table with that many rows)is this resolved?
Yes, the issue is resolved.
> rd <- deepstate_analyze_fun("~/extdata/packages/BNSL/inst/testfiles/mi") Read 1 item Read 1 item Read 1 item > rd binaryfile 1: /home/akolla/extdata/packages/BNSL/inst/testfiles/mi/mi_output/009e5ab9b0b69e3f96b34a1e8ef26f27fb5451d0.crash 2: /home/akolla/extdata/packages/BNSL/inst/testfiles/mi/mi_output/00b86d0e250dd13dcf8410799279a38b33390382.crash 3: /home/akolla/extdata/packages/BNSL/inst/testfiles/mi/mi_output/00d4c92d20520ff4d766d3cd53fa2f72f46bd98f.crash inputs logtable 1: <list[3]> <data.table[1x5]> 2: <list[3]> <data.table[1x5]> 3: <list[3]> No source trace found > rd$logtable [[1]] kind msg errortrace 1: InvalidRead Invalid read of size 8 src/mi_cmi.cpp : 57 address trace 1: Address 0xaa90cc0 is 0 bytes after a block of size 288 alloc'd NA [[2]] kind msg errortrace 1: InvalidRead Invalid read of size 8 src/mi_cmi.cpp : 57 address trace 1: Address 0x96e23b0 is 0 bytes after a block of size 752 alloc'd NA [[3]] [1] "No source trace found" >Still working on compressing the Read 1 item message on the console. Used sink(/dev/null), invisible they didn't work.
usually the "read 1 item" comes from some function that takes an argument you can use to suppress it, e.g.
> cat("2 3", file=f <- tempfile()) > scan(f) Read 2 items [1] 2 3 > scan(f, quiet = TRUE) [1] 2 3 >
Yes, got it. I updated it.
Issue resolved. Using Valgrind in the second pass and able to parse the log successfully.
great
hi @akhikolla there is a problem in your current implementation.
Right now deepstate_compile_fun runs the test harness with multiple inputs under valgrind. This is problematic for several reasons
To fix I propose that you change the code to
what do you think? does that make sense? can you code that for next week please?