Tarantool development patches archive
 help / color / mirror / Atom feed
* [Tarantool-patches] [PATCH 0/2] fiber_wakeup() nop on self
@ 2021-04-23 23:15 Vladislav Shpilevoy via Tarantool-patches
  2021-04-23 23:15 ` [Tarantool-patches] [PATCH 1/2] fiber: make wakeup in Lua and C " Vladislav Shpilevoy via Tarantool-patches
                   ` (3 more replies)
  0 siblings, 4 replies; 9+ messages in thread
From: Vladislav Shpilevoy via Tarantool-patches @ 2021-04-23 23:15 UTC (permalink / raw)
  To: tarantool-patches, gorcunov, sergepetrenko

The patchset makes fiber_wakeup() in C and fiber.wakeup() in Lua
nop when called on the current fiber. This fixes a couple of
crashes in the public API, and prevent spurious wakeups in
certain cases.

Branch: http://github.com/tarantool/tarantool/tree/gerold103/gh-5292-6043-fiber-wakeup-nop
Issue: https://github.com/tarantool/tarantool/issues/5292
Issue: https://github.com/tarantool/tarantool/issues/6043

Vladislav Shpilevoy (2):
  fiber: make wakeup in Lua and C nop on self
  fiber: use wakeup safely on self everywhere

 .../unreleased/gh-6043-fiber-wakeup-self.md   | 33 +++++++
 src/box/applier.cc                            |  4 +-
 src/box/journal.c                             |  6 ++
 src/box/journal.h                             |  7 ++
 src/box/raft.c                                | 14 +--
 src/box/txn.c                                 |  6 +-
 src/box/txn_limbo.c                           | 14 +--
 src/lib/core/fiber.c                          | 85 +++++++++++--------
 src/lib/core/fiber.h                          |  6 +-
 src/lib/swim/swim.c                           |  1 -
 .../gh-6043-fiber-wakeup-self.test.lua        | 50 +++++++++++
 test/unit/fiber.cc                            | 33 ++++++-
 test/unit/fiber.result                        |  2 +
 test/unit/fiber_stress.cc                     |  6 +-
 14 files changed, 191 insertions(+), 76 deletions(-)
 create mode 100644 changelogs/unreleased/gh-6043-fiber-wakeup-self.md
 create mode 100755 test/app-tap/gh-6043-fiber-wakeup-self.test.lua

-- 
2.24.3 (Apple Git-128)


^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2021-04-27 12:03 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-23 23:15 [Tarantool-patches] [PATCH 0/2] fiber_wakeup() nop on self Vladislav Shpilevoy via Tarantool-patches
2021-04-23 23:15 ` [Tarantool-patches] [PATCH 1/2] fiber: make wakeup in Lua and C " Vladislav Shpilevoy via Tarantool-patches
2021-04-25  9:21   ` Serge Petrenko via Tarantool-patches
2021-04-25 15:53     ` Vladislav Shpilevoy via Tarantool-patches
2021-04-26  9:21       ` Serge Petrenko via Tarantool-patches
2021-04-23 23:15 ` [Tarantool-patches] [PATCH 2/2] fiber: use wakeup safely on self everywhere Vladislav Shpilevoy via Tarantool-patches
2021-04-25  9:23   ` Serge Petrenko via Tarantool-patches
2021-04-26 21:56 ` [Tarantool-patches] [PATCH 0/2] fiber_wakeup() nop on self Cyrill Gorcunov via Tarantool-patches
2021-04-27 12:03 ` Kirill Yukhin via Tarantool-patches

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox