Skip to content
  • NARUSE, Yui's avatar
    6bf32cbe
    merge revision(s)... · 6bf32cbe
    NARUSE, Yui authored
    
    merge revision(s) 63abb5c2,34d02631,2adbf01a,3acc81d9: [Backport #17612]
    
    	dtoa.c: make compilable independently
    
    	Except for `-Dxmalloc=malloc -Dxfree=free`.
    	---
    	 missing/dtoa.c | 24 ++++++++++++++++++------
    	 1 file changed, 18 insertions(+), 6 deletions(-)
    
    	dtoa.c: constified
    
    	clang seems to locate never modified local data in the const
    	segment implicitly.
    	---
    	 missing/dtoa.c | 2 +-
    	 1 file changed, 1 insertion(+), 1 deletion(-)
    
    	dtoa.c: make thread-safe by using atomic CAS
    
    	---
    	 common.mk      |  2 ++
    	 missing/dtoa.c | 75 ++++++++++++++++++++++++++++++++++++++++++----------------
    	 util.c         |  1 +
    	 3 files changed, 57 insertions(+), 21 deletions(-)
    
    	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: default avatarKoichi Sasada <ko1@atdot.net>
    	---
    	 bootstraptest/test_ractor.rb | 11 +++++++++++
    	 missing/dtoa.c               | 13 ++++++++++---
    	 2 files changed, 21 insertions(+), 3 deletions(-)
    6bf32cbe
    merge revision(s)...
    NARUSE, Yui authored
    
    merge revision(s) 63abb5c2,34d02631,2adbf01a,3acc81d9: [Backport #17612]
    
    	dtoa.c: make compilable independently
    
    	Except for `-Dxmalloc=malloc -Dxfree=free`.
    	---
    	 missing/dtoa.c | 24 ++++++++++++++++++------
    	 1 file changed, 18 insertions(+), 6 deletions(-)
    
    	dtoa.c: constified
    
    	clang seems to locate never modified local data in the const
    	segment implicitly.
    	---
    	 missing/dtoa.c | 2 +-
    	 1 file changed, 1 insertion(+), 1 deletion(-)
    
    	dtoa.c: make thread-safe by using atomic CAS
    
    	---
    	 common.mk      |  2 ++
    	 missing/dtoa.c | 75 ++++++++++++++++++++++++++++++++++++++++++----------------
    	 util.c         |  1 +
    	 3 files changed, 57 insertions(+), 21 deletions(-)
    
    	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: default avatarKoichi Sasada <ko1@atdot.net>
    	---
    	 bootstraptest/test_ractor.rb | 11 +++++++++++
    	 missing/dtoa.c               | 13 ++++++++++---
    	 2 files changed, 21 insertions(+), 3 deletions(-)
Loading