2019-01-31 01:37:47 +08:00
|
|
|
// RUN: mlir-opt %s -mlir-print-debuginfo -strip-debuginfo | FileCheck %s
|
2019-01-24 12:48:23 +08:00
|
|
|
// This test verifies that debug locations are stripped.
|
|
|
|
|
|
|
|
#set0 = (d0) : (1 == 0)
|
|
|
|
|
2019-07-04 04:21:24 +08:00
|
|
|
// CHECK-LABEL: func @inline_notation
|
|
|
|
func @inline_notation() -> i32 {
|
2019-01-24 12:48:23 +08:00
|
|
|
// CHECK: "foo"() : () -> i32 loc(unknown)
|
|
|
|
%1 = "foo"() : () -> i32 loc("foo")
|
|
|
|
|
2019-02-02 08:42:18 +08:00
|
|
|
// CHECK: } loc(unknown)
|
2019-03-26 01:14:34 +08:00
|
|
|
affine.for %i0 = 0 to 8 {
|
2019-02-02 08:42:18 +08:00
|
|
|
} loc(fused["foo", "mysource.cc":10:8])
|
2019-01-24 12:48:23 +08:00
|
|
|
|
2019-01-29 13:23:53 +08:00
|
|
|
// CHECK: } loc(unknown)
|
2019-01-24 12:48:23 +08:00
|
|
|
%2 = constant 4 : index
|
2019-03-25 11:35:07 +08:00
|
|
|
affine.if #set0(%2) {
|
2019-01-29 13:23:53 +08:00
|
|
|
} loc(fused<"myPass">["foo", "foo2"])
|
2019-01-24 12:48:23 +08:00
|
|
|
|
|
|
|
// CHECK: return %0 : i32 loc(unknown)
|
|
|
|
return %1 : i32 loc("bar")
|
|
|
|
}
|