Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | mutex: Raise a ThreadError when detecting a fiber deadlock (#6680) | Jean byroot Boussier | 2022-11-09 | 1 | -1/+21 |
| | | | | | | | | | [Bug #19105] If no fiber scheduler is registered and the fiber that owns the lock and the one that try to acquire it both belong to the same thread, we're in a deadlock case. Co-authored-by: Jean Boussier <byroot@ruby-lang.org> | ||||
* | Prefer qualified names under Thread | Nobuyoshi Nakada | 2021-06-29 | 1 | -9/+9 |
| | |||||
* | Fix TestFiberMutex#test_condition_variable assertion | Benoit Daloze | 2020-11-08 | 1 | -5/+3 |
| | | | | * Now that it works correctly. | ||||
* | Rename to `Fiber#set_scheduler`. | Samuel Williams | 2020-11-07 | 1 | -10/+10 |
| | |||||
* | Refined assertions for better failure messages | Nobuyoshi Nakada | 2020-10-01 | 1 | -4/+4 |
| | |||||
* | Remove `Thread.scheduler` from public interface. | Samuel Williams | 2020-10-01 | 1 | -7/+6 |
| | | | | | | It's implementation is equivalent to: Thread.current.scheduler unless Thread.current.blocking? | ||||
* | Remove from waiter in Mutex#lock with ensure when calling rb_scheduler_block() | Benoit Daloze | 2020-09-20 | 1 | -0/+32 |
| | | | | | * Previously this could lead to an invalid waiter entry and then trying to wake up that waiter would result in various issues in rb_mutex_unlock_th(). | ||||
* | Fix Mutex#unlock with a scheduler and thread contention | Benoit Daloze | 2020-09-17 | 1 | -0/+23 |
| | | | | * It would hit "[BUG] unexpected THREAD_STOPPED" before. | ||||
* | Call scheduler.block instead of scheduler.kernel_sleep for blocking ↵ | Benoit Daloze | 2020-09-17 | 1 | -0/+25 |
| | | | | | | | Queue/SizedQueue operations * scheduler.unblock was already already called before but with no corresponding scheduler.block * add test that Queue#pop makes the scheduler wait until it gets an element. | ||||
* | Add support for Queue & SizedQueue. | Samuel Williams | 2020-09-14 | 1 | -0/+31 |
| | |||||
* | Add support for ConditionVariable. | Samuel Williams | 2020-09-14 | 1 | -0/+37 |
| | |||||
* | Make Mutex per-Fiber instead of per-Thread | Benoit Daloze | 2020-09-14 | 1 | -5/+33 |
| | | | | | | | | | * Enables Mutex to be used as synchronization between multiple Fibers of the same Thread. * With a Fiber scheduler we can yield to another Fiber on contended Mutex#lock instead of blocking the entire thread. * This also makes the behavior of Mutex consistent across CRuby, JRuby and TruffleRuby. * [Feature #16792] | ||||
* | Rename `Fiber{}` to `Fiber.schedule{}`. | Samuel Williams | 2020-09-14 | 1 | -2/+2 |
| | |||||
* | Rename TestScheduler* to TestFiber for convention of the test directory | Hiroshi SHIBATA | 2020-05-23 | 1 | -1/+1 |
| | |||||
* | Move `test/scheduler` -> `test/fiber` [Bug #16892][ruby-core:98366]. | Samuel Williams | 2020-05-15 | 1 | -0/+47 |