mirror of
https://github.com/apple/swift.git
synced 2025-12-14 20:36:38 +01:00
This instruction can be inserted by Onone optimizations as a replacement for deleted instructions to ensure that it's possible to single step on its location.
17 lines
486 B
Plaintext
17 lines
486 B
Plaintext
// RUN: %target-swift-frontend -g -emit-ir %s | %FileCheck %s
|
|
|
|
// CHECK-LABEL: define {{.*}} @test_debug_step
|
|
sil @test_debug_step : $@convention(thin) () -> () {
|
|
bb0:
|
|
// CHECK: "nop"{{.*}}, !dbg [[L1:![0-9]+]]
|
|
debug_step, loc "a.swift":1:2
|
|
// CHECK: "nop"{{.*}}, !dbg [[L2:![0-9]+]]
|
|
debug_step, loc "b.swift":3:4
|
|
%r = tuple ()
|
|
return %r : $()
|
|
}
|
|
|
|
// CHECK-DAG: [[L1]] = !DILocation(line: 1, column: 2, {{.*}})
|
|
// CHECK-DAG: [[L2]] = !DILocation(line: 3, column: 4, {{.*}})
|
|
|