should_yield problem [Was: svn commit: r251322 - head/sys/kern]
attilio at freebsd.org
Tue Jul 2 17:52:28 UTC 2013
On Tue, Jul 2, 2013 at 7:24 PM, Andriy Gapon <avg at freebsd.org> wrote:
> on 02/07/2013 20:12 Attilio Rao said the following:
>> While "ticks" is signed it is used as an unsigned int.
>> td_swvolticks is always derived by ticks, which again will always be
>> used as an unisgned and then the subtractions among the 2 will be
> So returning to my example where ticks == -1946084020 and td_swvoltick == 0 and
> (ticks - td->td_swvoltick) == -1946084020. Is this consistent in your opinion?
I was just pointing out that the real bug is not in the subtraction
itself but on the hogticks comparison.
This is because hogticks is not an absolute measurement but it
represents really a ticks difference.
In my opinion we should define hogticks as an unsigned int and add a
small comment saying that it is a differential.
This will fix the issue.
Peace can only be achieved by understanding - A. Einstein
More information about the svn-src-head