1 # REQUIRES: python, native && target-aarch64 && system-darwin
4 # RUN: yaml2obj %S/Inputs/interactive_crashlog/multithread-test.yaml > %t.dir/multithread-test
5 # RUN: %lldb -o 'command script import lldb.macosx.crashlog' \
6 # RUN: -o 'crashlog -a -i -t %t.dir/multithread-test %S/Inputs/interactive_crashlog/multithread-test.crash' \
7 # RUN: -o "thread list" -o "bt all" 2>&1 | FileCheck %s
9 # CHECK: "crashlog" {{.*}} commands have been installed, use the "--help" options on these commands
11 # CHECK: (lldb) process status
12 # CHECK-NEXT: Process 22511 stopped
13 # CHECK-NEXT: * thread #3, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
14 # CHECK-NEXT: frame #0: 0x0000000100ec58f4 multithread-test`bar
16 # CHECK: (lldb) thread backtrace
17 # CHECK-NEXT: * thread #3, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
18 # CHECK-NEXT: * frame #0: 0x0000000100ec58f4 multithread-test`bar{{.*}} [artificial]
19 # CHECK-NEXT: frame #1: 0x0000000100ec591b multithread-test`foo{{.*}} [artificial]
20 # CHECK-NEXT: frame #2: 0x0000000100ec5a87 multithread-test`compute_pow{{.*}} [artificial]
22 # CHECK: (lldb) thread list
23 # CHECK-NEXT: Process 22511 stopped
24 # CHECK-NEXT: thread #1: tid = 0x0000, 0x000000019cc40b84{{.*}}
25 # CHECK-NEXT: thread #2: tid = 0x0001, 0x000000019cc42c9c{{.*}}
26 # CHECK-NEXT: * thread #3: tid = 0x0002, 0x0000000100ec58f4 multithread-test`bar{{.*}}, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
28 # CHECK: (lldb) bt all
30 # CHECK: frame #{{[0-9]+}}: 0x000000019cc40b84{{.*}} [artificial]
31 # CHECK: frame #{{[0-9]+}}: 0x0000000100ec5b3b multithread-test`main{{.*}} [artificial]
32 # CHECK: frame #{{[0-9]+}}: 0x00000002230f8da7{{.*}} [artificial]
33 # CHECK-NEXT: thread #2
34 # CHECK-NEXT: frame #0: 0x000000019cc42c9c{{.*}} [artificial]
35 # CHECK: frame #{{[0-9]+}}: 0x0000000100ec5957 multithread-test`call_and_wait{{.*}} [artificial]
36 # CHECK: frame #{{[0-9]+}}: 0x000000019cc7e06b{{.*}} [artificial]
37 # CHECK: frame #{{[0-9]+}}: 0x000000019cc78e2b{{.*}} [artificial]
38 # CHECK-NEXT:* thread #3, stop reason = EXC_BAD_ACCESS (code=1, address=0x0)
39 # CHECK-NEXT: * frame #0: 0x0000000100ec58f4 multithread-test`bar{{.*}} [artificial]
40 # CHECK-NEXT: frame #1: 0x0000000100ec591b multithread-test`foo{{.*}} [artificial]
41 # CHECK-NEXT: frame #2: 0x0000000100ec5a87 multithread-test`compute_pow{{.*}} [artificial]
42 # CHECK: frame #{{[0-9]+}}: 0x000000019cc7e06b{{.*}} [artificial]
43 # CHECK: frame #{{[0-9]+}}: 0x000000019cc78e2b{{.*}} [artificial]