1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00
Commit graph

5 commits

Author SHA1 Message Date
Nobuyoshi Nakada
3acc81d9e4 Fixed race in dtoa [Bug #17612]
Fixed the race condition when replacing `freelist` entry with its
chained next element.  At acquiring an entry, hold the entry once
with the special value, then release by replacing it with the next
element again after acquired.  If another thread is holding the
same entry at that time, spinning until the entry gets released.

Co-Authored-By: Koichi Sasada <ko1@atdot.net>
2021-02-10 19:44:47 +09:00
Nobuyoshi Nakada
2adbf01ae1
dtoa.c: make thread-safe by using atomic CAS 2021-01-10 18:19:53 +09:00
Nobuyoshi Nakada
34d02631e7
dtoa.c: constified
clang seems to locate never modified local data in the const
segment implicitly.
2021-01-10 16:42:36 +09:00
Nobuyoshi Nakada
63abb5c227
dtoa.c: make compilable independently
Except for `-Dxmalloc=malloc -Dxfree=free`.
2021-01-10 16:28:58 +09:00
nobu
867338c36e Split dtoa.c
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@67022 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2019-02-07 08:53:11 +00:00