For performance reasons the reproducers don't copy the files captured by the file collector eagerly, but wait until the reproducer needs to be generated. This is a problematic when LLDB crashes and we have to do all this signal-unsafe work in the signal handler. This patch uses a similar trick to clang, which has the driver invoke a new cc1 instance to do all this work out-of-process. This patch moves the writing of the mapping file as well as copying over the reproducers into a separate process spawned when lldb crashes. Differential revision: https://reviews.llvm.org/D89600
15 lines
495 B
Plaintext
15 lines
495 B
Plaintext
# RUN: mkdir -p %t.repro
|
|
# RUN: touch %t.known.file
|
|
# RUN: mkdir -p %t.known.dir
|
|
# RUN: touch %t.repro/index.yaml
|
|
# RUN: echo -n "%t.known.file" > %t.repro/files.txt
|
|
# RUN: echo -n "%t.known.dir" > %t.repro/dirs.txt
|
|
|
|
# RUN: %lldb --reproducer-finalize %t.repro 2>&1 | FileCheck %s
|
|
# CHECK-NOT: error
|
|
# CHECK: Reproducer written to
|
|
|
|
# RUN: echo "CHECK-DAG: %t.known.file" > %t.filecheck
|
|
# RUN: echo "CHECK-DAG %t.known.dir" >> %t.filecheck
|
|
# RUN: cat %t.repro/files.yaml | FileCheck %t.filecheck
|