Files
swift-mirror/test/DebugInfo/dbgvalue-insertpt.swift
Bob Wilson e4cc933f70 master-next: adjust test output for change in LLVM block syntax
LLVM r356789 changed the format of textual IR to print nameless
blocks with labels instead of comments with "; <label>". Adjust Swift
tests to match. I also updated the utils/viewcfg script to match.
2019-03-29 18:19:26 -07:00

20 lines
846 B
Swift

// RUN: %target-swift-frontend -g -emit-ir %s | %FileCheck %s
// FIXME: This test should be testing a non-shadow-copied value instead.
for i in 0 ..< 3 {
// CHECK: %[[ALLOCA:[0-9]+]] = alloca %TSiSg
// CHECK: %i.debug = alloca i{{32|64}}
// CHECK-NEXT: call void @llvm.dbg.declare(metadata i{{32|64}}* %i.debug,
// CHECK-SAME: metadata ![[I:[0-9]+]],
// CHECK: call swiftcc{{.*}} @{{.*}}next{{.*}}
// CHECK: %[[LD:[0-9]+]] = load i{{32|64}}, i{{32|64}}*
// CHECK: br i1 {{%.*}}, label %[[FAIL:.*]], label %[[SUCCESS:.*]],
//
// CHECK: [[SUCCESS]]:
// CHECK: br label %[[NEXT_BB:.*]],
//
// CHECK: [[NEXT_BB]]:
// CHECK: %[[PHI_VAL:.*]] = phi i{{32|64}} [ %[[LD]], %[[SUCCESS]] ]
// CHECK: store i{{32|64}} %[[PHI_VAL]], i{{32|64}}* %i.debug
// CHECK: ![[I]] = !DILocalVariable(name: "i",
}