mirror of
https://github.com/apple/swift.git
synced 2026-02-27 18:26:24 +01:00
33 lines
1.7 KiB
Plaintext
33 lines
1.7 KiB
Plaintext
// RUN: %empty-directory(%t)
|
||
// RUN: %target-build-swift %S/Inputs/Crash.swift -parse-as-library -O %swift-debug-flags -o %t/CrashOpt.exe
|
||
// RUN: %target-codesign %t/CrashOpt.exe
|
||
|
||
// RUN: env SWIFT_BACKTRACE=enable=yes,cache=no %target-run %t/CrashOpt.exe > %t/Optimized.out 2>&1 || true
|
||
// RUN: %FileCheck %s --ignore-case --check-prefix OPTIMIZED < %t/Optimized.out
|
||
|
||
// UNSUPPORTED: use_os_stdlib
|
||
// UNSUPPORTED: back_deployment_runtime
|
||
// UNSUPPORTED: asan
|
||
// REQUIRES: executable_test
|
||
// REQUIRES: backtracing
|
||
// REQUIRES: OS=macosx || OS=linux-gnu
|
||
|
||
|
||
// CHECK: *** Program crashed: {{(Bad // OPTIMIZED: *** Program crashed: {{(Bad pointer dereference|Access violation)}} at 0x{{0+}}4 ***
|
||
|
||
// OPTIMIZED: Thread 0 {{(".*" )?}}crashed:
|
||
|
||
// OPTIMIZED: 0 [inlined] 0x{{[0-9a-f]+}} level5() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:20:15
|
||
// OPTIMIZED-NEXT: 1 [inlined] 0x{{[0-9a-f]+}} level4() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:14:3
|
||
// OPTIMIZED-NEXT: 2 [inlined] 0x{{[0-9a-f]+}} level3() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:10:3
|
||
// OPTIMIZED-NEXT: 3 [inlined] 0x{{[0-9a-f]+}} level2() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:6:3
|
||
// OPTIMIZED-NEXT: 4 [inlined] 0x{{[0-9a-f]+}} level1() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:2:3
|
||
// OPTIMIZED-NEXT: 5 [inlined] 0x{{[0-9a-f]+}} static Crash.main() in CrashOpt.exe at {{.*[\\/]}}Crash.swift:26:5
|
||
// OPTIMIZED: {{6|7}} [system] 0x{{[0-9a-f]+}} main + {{[0-9]+}} in CrashOpt.exe at {{.*}}
|
||
|
||
// OPTIMIZED: Registers:
|
||
|
||
// OPTIMIZED: Images ({{[0-9]+}} omitted):
|
||
|
||
// OPTIMIZED: {{0x[0-9a-f]+}}–{{0x[0-9a-f]+}}{{ +}}{{([0-9a-f]+|<no build ID>)}}{{ +}}CrashOpt.exe{{ +}}{{.*[\\/]}}CrashOpt.exe
|