This is the mail archive of the
ecos-discuss@sources.redhat.com
mailing list for the eCos project.
Re: ASSERT: cyg_callout_reset() We didn't pick the smallestdelta!
On Wed, 2002-11-27 at 17:52, Kevin Hilman wrote:
> Gary Thomas <gthomas@ecoscentric.com> writes:
>
> > On Wed, 2002-11-27 at 17:23, Kevin Hilman wrote:
> > > Gary Thomas <gthomas@ecoscentric.com> writes:
> > >
> > > > On Wed, 2002-11-27 at 16:37, Kevin Hilman wrote:
> > > > > Gary Thomas <gthomas@ecoscentric.com> writes:
> > > > >
> > > > > > > Nope, my last update was Nov 6. However, now I've merged the latest
> > > > > > > CVS, and this assert goes away. Now I'm consistently hitting the
> > > > > > > assert below, the "delta is right now" one.
> > > > > > >
> > > > > >
> > > > > > Harrumph! I've never seen that one. Maybe you could detect this case
> > > > > > and print some data so we can analyze the failure (asserts are nice, but
> > > > > > sometimes one needs more). Something like this:
> > > > > > if (delta <= 0) {
> > > > > > diag_printf("Bad delta: %d, callout: %p, fun: %p(%x)\n", delta, c, f, p);
> > > > >
> > > > > This run shows a failure with your suggested diag_printf(). I've also
> > > > > included some relevant parts of 'nm'
> > > > >
> > > >
> > > > I'm still not sure why this fails. Two more things to try:
> > > > * Change the 'assert' to be CYG_ASSERT(0 <= delta, ...)
> > > > * Print one more piece (using the previos setup/test)
> > > > diag_printf("Called from %p\n", __builtin_return_address(0));
> > >
> > > OK, changing the assert to <= makes it run happily for quite a while
> > > longer but eventually runs into problems running out of mbufs and then
> > > packets out of sequence and then some different timeout error (see
> > > output below). The caller is the same every time and is
> > > cyg_tcp_input().
> > >
> >
> > Actually, the "errors" you are seeing are quite normal, especially if
> > one end of your test is faster than the other. This part of the test
> > is trying to do major amounts of UDP traffic which has no flow control
> > and is guaranteed to drop packets. The test should eventually recover
> > (it may take a little while - a few tens of seconds I would think) and
> > then carry or.
>
> OK, should I consider this a "passed" test then?
>
> I'd assumed it failed somehow because the host program (on x86 linux)
> ends up looping, unable to contact the target again:
>
It really should continue after this. Maybe try to change the code
to be something like this:
if (delta <= 0) {
... whatever prints you have now
delta = 1;
}
Also, how many times do you see this [delta == 0] occur?
--
------------------------------------------------------------
Gary Thomas |
eCosCentric, Ltd. |
+1 (970) 229-1963 | eCos & RedBoot experts
gthomas@ecoscentric.com |
http://www.ecoscentric.com/ |
------------------------------------------------------------
--
Before posting, please read the FAQ: http://sources.redhat.com/fom/ecos
and search the list archive: http://sources.redhat.com/ml/ecos-discuss