diff options
| author | gingerBill <bill@gingerbill.org> | 2021-04-14 20:19:02 +0100 |
|---|---|---|
| committer | gingerBill <bill@gingerbill.org> | 2021-04-14 20:19:02 +0100 |
| commit | 05a181d719c57b6be73ab5cd726c2d418a8a9026 (patch) | |
| tree | 20470f3b1809ffd19692e9542066b279c1dde2f0 /core/sync/sync2 | |
| parent | d24784074cd5cb7ac340f975b207e6d80abbd5a6 (diff) | |
Fix style issues; Use new attribute `@(cold)` where appropriate in the new sync package
Diffstat (limited to 'core/sync/sync2')
| -rw-r--r-- | core/sync/sync2/primitives_atomic.odin | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/sync/sync2/primitives_atomic.odin b/core/sync/sync2/primitives_atomic.odin index d65403076..610ab7ee0 100644 --- a/core/sync/sync2/primitives_atomic.odin +++ b/core/sync/sync2/primitives_atomic.odin @@ -38,7 +38,7 @@ _mutex_try_lock :: proc(m: ^Mutex) -> bool { } - +@(cold) _mutex_lock_slow :: proc(m: ^Mutex, curr_state: _Mutex_State) { new_state := curr_state; // Make a copy of it @@ -68,6 +68,7 @@ _mutex_lock_slow :: proc(m: ^Mutex, curr_state: _Mutex_State) { } +@(cold) _mutex_unlock_slow :: proc(m: ^Mutex) { // TODO(bill): Use a Futex here for Linux to improve performance and error handling } |