Re: Packet loss every 30.999 seconds



On Mon, 17 Dec 2007, David G Lawrence wrote:

One more comment on my last email... The patch that I included is not
meant as a real fix - it is just a bandaid. The real problem appears to
be that a very large number of vnodes (all of them?) are getting synced
(i.e. calling ffs_syncvnode()) every time. This should normally only
happen for dirty vnodes. I suspect that something is broken with this
check:

if (vp->v_type == VNON || ((ip->i_flag &
(IN_ACCESS | IN_CHANGE | IN_MODIFIED | IN_UPDATE)) == 0 &&
vp->v_bufobj.bo_dirty.bv_cnt == 0)) {
VI_UNLOCK(vp);
continue;
}

Isn't it just the O(N) algorithm with N quite large? Under ~5.2, on
a 2.2GHz A64 UP in 32-bit mode, I see a latency of 3 ms for 17500 vnodes,
which would be explained by the above (and the VI_LOCK() and loop
overhead) taking 171 ns per vnode. I would expect it to take more like
20 ns per vnode for UP and 60 for SMP.

The comment before this code shows that the problem is known, and says
that a subroutine call cannot be afforded unless there is work to do,
but the, the locking accesses look like subroutine calls, have subroutine
calls in their internals, and take longer than simple subroutine calls
in the SMP case even when they don't make subroutine calls. (IIRC, on
A64 a minimal subroutine call takes 4 cycles while a minimal locked
instructions takes 18 cycles; subroutine calls are only slow when their
branches are mispredicted.)

Bruce
_______________________________________________
freebsd-stable@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-stable
To unsubscribe, send any mail to "freebsd-stable-unsubscribe@xxxxxxxxxxx"



Relevant Pages

  • Re: Packet loss every 30.999 seconds
    ... meant as a real fix - it is just a bandaid. ... happen for dirty vnodes. ... but the, the locking accesses look like subroutine calls, have subroutine ... so the upcoming flush is going to be expensive. ...
    (freebsd-net)
  • Re: Packet loss every 30.999 seconds
    ... meant as a real fix - it is just a bandaid. ... happen for dirty vnodes. ... but the, the locking accesses look like subroutine calls, have subroutine ... so the upcoming flush is going to be expensive. ...
    (freebsd-stable)
  • Re: Packet loss every 30.999 seconds
    ... meant as a real fix - it is just a bandaid. ... The real problem appears to ... happen for dirty vnodes. ... but the, the locking accesses look like subroutine calls, have subroutine ...
    (freebsd-net)
  • Still filename problem
    ... The compiler error message I am getting says "object variable or with block ... this subroutine calls another subroutine where I use a similar ... It was not an XLS file and that caused some confusion but it now seems ... evident that the real problem is that this same strMGR_SHORT_NAME is now ...
    (microsoft.public.excel.programming)