Open schwehr opened 5 years ago
Kurt,
On May 2, 2019, at 8:05 PM, Kurt Schwehr notifications@github.com wrote:
This is a place for me to take notes while looking at mb_rt.c. I don't totally understand the design of it and before I try to improve it, it needs to have good test coverage. It's a great candidate for fuzzing and microbenchmarks.
Lots of questions starting with:
• Why the global static model variable when a ptr is already passed? Can we just fix a few functions and drop the model variable poluting all of mb_rt's scope? I don’t know why I did this - using a static pointer variable seems bad - feel free to fix it.
• What is MBBA? Ancient history not worth explaining. We should change MBBA to MBIO in these statements.
• Is the assumption of plotting baked into this? Yes, it is used in mbvelocitytool.
Also, the notion of a revision id tied to the repository is meaningless with Git, so we should get rid of the svn_id and rcs_id strings and print statements throughout the codebase.
Cheers, Dave
David W. Caress Principal Engineer Seafloor Mapping Lab
Monterey Bay Aquarium Research Institute 7700 Sandholdt Road Moss Landing, CA 95039
caress@mbari.org http://www.mbari.org/~caress/
Phone: 831-775-1775
Thanks for the quick response. I'll look at removing the static pointer after I get some tests in place.
This is a place for me to take notes while looking at mb_rt.c. I don't totally understand the design of it and before I try to improve it, it needs to have good test coverage. It's a great candidate for fuzzing and microbenchmarks.
Lots of questions starting with:
MBBA
?So far, I have a start to mb_rt.h and an alloc test:
and
Causing crashes is super easy to do. Give a too long size or having the two arrays be different lengths. What should size of 0 do?