[Larceny-users] assertion failure in stats_start_timer

Felix Klock felixluser at pnkfx.org
Mon Jan 5 09:14:44 EST 2009


Marco (cc'ing larceny-users)-

On Jan 5, 2009, at 2:52 AM, Marco Maggi wrote:

> When running my test suite for POSIX
> functions, I get an assertion failure
> on "Sys/stats.c" line 283.  The test
> just forks a new process and exits:
>
> | (let ((pid (fork)))
> |   (if (= 0 pid)
> |       (exit)
> |     #t)
>
> it is the child who fails.  It is a
> bohrbug, but happens only when I
> call EXIT after FORK, if I call
> "execv()", or the other functions
> like it, no failure happens.
>
> i686-pc-linux-gnu, larceny-5886.


Well, you learn something new every day; I had never heard the term  
"bohrbug", nor of the distinction between "bohrbug" and "heisenbug"  
before, but there it is on wikipedia!

----

 From the line number information, it seems I added that assertion  
about two years ago as an attempt to find out more about another  
intermittent bug:
https://trac.ccs.neu.edu/trac/larceny/changeset/4035

My plan of attack right now would be to shift the assertion logic  
further back in the control flow, into osdep-unix.c's  
osdep_realclock() and osdep_cpuclock(), to determine under what  
conditions those functions are returning 0.

Marco: I am unable to reproduce the problem on my end.  You called  
this a bohrbug, so I assume you can readily reproduce the problem but  
cannot determine the full set of conditions that cause it.  Since you  
are using a very recent SVN version of Larceny, I assume you won't  
mind if I communicate source code changes to you via the repository?   
Assuming that you do not mind my using that as my communication  
channel, then I will set aside some time today to put such code into  
the trunk's copy of osdep-unix.c (unless Will objects to such changes  
being made on the trunk and would prefer I send you patches or put the  
work onto a branch).

-Felix





More information about the Larceny-users mailing list