[R-pkg-devel] Package valgrind problem I can't solve: Direction?
PDunn2 at usc.edu.au
Wed Nov 1 05:56:16 CET 2017
Wow: Thanks again. You are going above and beyond Iñaki which I appreciate greatly.
But same error message appears, even after fixing (both the relerr, which I had already attended to, and the lambda issue).
I have since initialised *every* variable in the subroutine smallp (even the *input* variables to some arbitrary value to try to work out what is causing the issue) yet the error persists. There surely cannot be any uninitialized variables now *every* var in the subroutine is explicitly initialised.
That tells me that there is nothing I can do to remove the error. If everything is initialised…
Frustrated… And wasting so much time!
Thanks for any help from anyone.
On 30/Oct/17, 9:06 pm, "Iñaki Úcar" <i.ucar86 at gmail.com> wrote:
2017-10-30 0:54 GMT+01:00 Peter Dunn <PDunn2 at usc.edu.au>:
> Thanks for this direction.
> But I am still confused, as the problem persists after attending to any
> possible issue: That piece of identified code only has four variables, and I
> can account for them all.
> The two variables its and aimrerr are now explicitly initialised. So they
> cannot be the problem.
> The variables maxit and relerr are inputs to the subroutine... and both are
> explicitly initialised in the only subroutine which calls smallp. So I can’t
> see how that can be a problem. (Clearly they cannot be initialised in the
> subroutine smallp or their input values are overwritten.)
Found it. "relerr" may be uninitialised because "w" is uninitialised
in smallp (tweedie 2.2.5, line 2169).
When you try to debug this kind of things, you must track not only
explicit initialisations, but also all the assignments with possibly
BTW, I also see:
if ( funvalue .LT. exp(-lambda) ) then
Warning: 'lambda' may be used uninitialized in this function
USC, Locked Bag 4, Maroochydore DC, Queensland, 4558 Australia.
CRICOS Provider No: 01595D
Please consider the environment before printing this email.
This email is confidential. If received in error, please delete it from your system.
[[alternative HTML version deleted]]
More information about the R-package-devel