[Tarantool-patches] [PATCH 2/2] app/fiber: wait till a full event loop iteration ends.

Vladislav Shpilevoy v.shpilevoy at tarantool.org
Fri Nov 15 00:44:53 MSK 2019


Hi! Thanks for the fixes!

>> But more important questions are:
>> - How can a number from top() have a not 'number' type? 
> 
> It can't. I just wanted to implement a caconical is_finite check.
> I can remove it, if you want me to.
> 
>>
>> - How can top() contain a NaN, and an infinite value? 
> 
> NaN: you issue fiber.top() on the same iteration you called
> fiber.top_enable(). cord()->clock_delta_last and fiber()->clock_delta_last
> both are 0, because clock_delta_last contains data from a previous ev loop
> iteration. Division gives you NaN.

Hm, so a user should be ready that top() can return invalid values?
I think that it may be better to return 0, when cord()->clock_delta_last
is 0.


More information about the Tarantool-patches mailing list