Project

General

Profile

Bug #12711

Darwin doesn't show C backtrace correctly if iSIGSEGV is received when IP is in userland

Added by naruse (Yui NARUSE) almost 4 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Target version:
-
ruby -v:
ruby 2.4.0dev (2016-08-18 trunk 55955) [x86_64-darwin15]
[ruby-core:77096]

Description

Current Ruby can show C backtrace on the following case

Process.kill :SEGV, $$

But can't on the following:

require"fiddle"
Fiddle.dlunwrap(100).class

Related issues

Related to Ruby master - Bug #13566: A process freezes at the beginning of C level backtrace when a certain SEGV is occurredClosednaruse (Yui NARUSE)Actions
#1

Updated by naruse (Yui NARUSE) almost 4 years ago

  • Status changed from Open to Closed

Applied in changeset r56030.


  • vm_dump.c (backtrace): use rip in the saved context for the case the SIGSEGV is received when the process is in userland. Note that ip in the stack should be used if the signal is received when it is in kernel (when it is calling syscall) [Bug #12711]

Updated by nagachika (Tomoyuki Chikanaga) almost 4 years ago

  • Backport changed from 2.1: REQUIRED, 2.2: REQUIRED, 2.3: REQUIRED to 2.1: REQUIRED, 2.2: REQUIRED, 2.3: DONE

ruby_2_3 r56257 merged revision(s) 56030,56035.

Updated by usa (Usaku NAKAMURA) over 3 years ago

  • Backport changed from 2.1: REQUIRED, 2.2: REQUIRED, 2.3: DONE to 2.1: REQUIRED, 2.2: DONE, 2.3: DONE
#4

Updated by wanabe (_ wanabe) about 3 years ago

  • Related to Bug #13566: A process freezes at the beginning of C level backtrace when a certain SEGV is occurred added

Also available in: Atom PDF