From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp39.i.mail.ru (smtp39.i.mail.ru [94.100.177.99]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id 69891452566 for ; Fri, 15 Nov 2019 17:59:12 +0300 (MSK) From: Serge Petrenko Date: Fri, 15 Nov 2019 17:58:57 +0300 Message-Id: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [Tarantool-patches] [PATCH v2 0/2] fiber.top(): minor fixup List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: v.shpilevoy@tarantool.org Cc: tarantool-patches@dev.tarantool.org The first patch fixes variable initialization after fiber.top_enable() so that cord clocks don't contain garbage on first event loop iteration after enable. The second patch alters fiber.top() test to wait for correct output before testing it. Follow-up https://github.com/tarantool/tarantool/issues/2694 Branch https://github.com/tarantool/tarantool/tree/sp/gh-2694-test-fixup Changes in v2: - clean up all fibers clock stats on fiber.top_enable() - push 0 instead of NaN when cord clock_delta_last is 0 - review fixes as per review from Vladislav Serge Petrenko (2): fiber: reset clock stats on fiber.top_enable() app/fiber: wait till a full event loop iteration ends src/lib/core/fiber.c | 21 +++++++++++++++++++++ src/lua/fiber.c | 12 ++++++++++-- test/app/fiber.result | 28 +++++++++++++++++++--------- test/app/fiber.test.lua | 26 ++++++++++++++++++-------- 4 files changed, 68 insertions(+), 19 deletions(-) -- 2.21.0 (Apple Git-122)