Implement a new target.process.follow-fork-mode setting to control LLDB's behavior on fork. If set to 'parent', the forked child is detached and parent continues being traced. If set to 'child', the parent is detached and child becomes traced instead. Differential Revision: https://reviews.llvm.org/D100503
15 lines
385 B
Plaintext
15 lines
385 B
Plaintext
# REQUIRES: native
|
|
# UNSUPPORTED: system-darwin
|
|
# UNSUPPORTED: system-windows
|
|
# RUN: %clangxx_host %p/Inputs/fork.cpp -DTEST_FORK=fork -o %t
|
|
# RUN: %lldb -b -s %s %t | FileCheck %s
|
|
b parent_func
|
|
b child_func
|
|
process launch
|
|
# CHECK-NOT: function run in parent
|
|
# CHECK: stop reason = breakpoint
|
|
# CHECK-NEXT: parent_func
|
|
continue
|
|
# CHECK: function run in parent
|
|
# CHECK: child exited: 0
|