1717// RUN: tpp-run %s -e entry -entry-point-result=void -print-mlir=early -seed 123 -splat-to-random -init-type=normal 2>&1 | \
1818// RUN: FileCheck %s --check-prefix=OPT-NORMAL
1919
20- func.func @entry (%arg0: tensor <4 x2 xf32 >, %arg1: tensor <4 x2 xi32 >, %arg2: tensor <4 x2 xi32 >, %arg3: tensor <4 x2 xf16 >) {
20+ func.func @entry (%arg0: tensor <4 x2 xf32 >, %arg1: tensor <4 x2 xi32 >, %arg2: tensor <4 x2 xi32 >, %arg3: tensor <4 x2 xf16 >, %arg4: tensor < 4 x 2 x i8 > ) {
2121 %0 = arith.constant dense <1.0 > : tensor <2 x16 xf32 >
2222 %5 = arith.constant dense <1.0 > : tensor <2 x16 xf64 >
2323 %1 = arith.constant dense <2.0 > : tensor <4 x16 xf32 >
2424 %10 = arith.constant dense <2.0 > : tensor <4 x4 xf32 >
2525 %2 = arith.constant dense <0.0 > : tensor <4 x8 xf32 >
2626 %3 = arith.constant dense <[[0.0 , 1.0 ],[2.0 , 3.0 ]]> : tensor <2 x2 xf32 >
27+ %13 = arith.constant dense <1 > : tensor <4 x2 xi8 >
2728 %4 = arith.constant dense <0 > : tensor <4 x8 xi32 >
2829 %6 = arith.constant dense <1 > : tensor <4 x8 xi32 >
2930 %11 = arith.constant dense <1 > : tensor <4 x8 xi32 >
@@ -39,13 +40,15 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
3940// SPLAT-DAG: memref.global "private" @__wrapper_1 : memref<4x2xi32> = dense<1>
4041// SPLAT-DAG: memref.global "private" @__wrapper_2 : memref<4x2xi32> = dense<1>
4142// SPLAT-DAG: memref.global "private" @__wrapper_3 : memref<4x2xf16> = dense<1.000000e+00>
43+ // SPLAT-DAG: memref.global "private" @__wrapper_4 : memref<4x2xi8> = dense<1>
4244// SPLAT-LABEL: @_entry
4345// SPLAT: arith.constant dense<1.000000e+00> : tensor<2x16xf32>
4446// SPLAT: arith.constant dense<1.000000e+00> : tensor<2x16xf64>
4547// SPLAT: arith.constant dense<2.000000e+00> : tensor<4x16xf32>
4648// SPLAT: arith.constant dense<2.000000e+00> : tensor<4x4xf32>
4749// SPLAT: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
4850// SPLAT: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}> : tensor<2x2xf32>
51+ // SPLAT: arith.constant dense<1> : tensor<4x2xi8>
4952// SPLAT: arith.constant dense<0> : tensor<4x8xi32>
5053// SPLAT: arith.constant dense<1> : tensor<4x8xi32>
5154// SPLAT: arith.constant dense<1> : tensor<4x8xi32>
@@ -62,13 +65,15 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
6265// RANDOM-DAG: memref.global "private" @__wrapper_1 : memref<4x2xi32> = dense<{{\[}}{{\[}}132, 126], [117, 123], [126, 121], [132, 133]]>
6366// RANDOM-DAG: memref.global "private" @__wrapper_2 : memref<4x2xi32> = dense<{{\[}}{{\[}}129, 134], [129, 126], [141, 131], [138, 121]]>
6467// RANDOM-DAG: memref.global "private" @__wrapper_3 : memref<4x2xf16> = dense<{{\[}}{{\[}}0.000000e+00, 1.303710e-01], [1.512450e-01, 1.063540e-02]
68+ // RANDOM-DAG: memref.global "private" @__wrapper_4 : memref<4x2xi8> = dense<{{\[}}{{\[}}67, 63], [56, 60], [62, 59], [60, 71]]>
6569// RANDOM-LABEL: @_entry
6670// RANDOM: arith.constant dense<1.000000e+00> : tensor<2x16xf32>
6771// RANDOM: arith.constant dense<1.000000e+00> : tensor<2x16xf64>
6872// RANDOM: arith.constant dense<2.000000e+00> : tensor<4x16xf32>
6973// RANDOM: arith.constant dense<2.000000e+00> : tensor<4x4xf32>
7074// RANDOM: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
7175// RANDOM: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}> : tensor<2x2xf32>
76+ // RANDOM: arith.constant dense<1> : tensor<4x2xi8>
7277// RANDOM: arith.constant dense<0> : tensor<4x8xi32>
7378// RANDOM: arith.constant dense<1> : tensor<4x8xi32>
7479// RANDOM: arith.constant dense<1> : tensor<4x8xi32>
@@ -85,6 +90,7 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
8590// RANDOM-SPLAT-NOT: memref.global "private" @__wrapper_1 : memref<4x2xi32> = dense<1>
8691// RANDOM-SPLAT-NOT: memref.global "private" @__wrapper_2 : memref<4x2xi32> = dense<1>
8792// RANDOM-SPLAT-NOT: memref.global "private" @__wrapper_3 : memref<4x2xf16> = dense<1.000000e+00>
93+ // RANDOM-SPLAT-NOT: memref.global "private" @__wrapper_4 : memref<4x2xi8> = dense<1>
8894// RANDOM-SPLAT-LABEL: @_entry
8995// RANDOM-SPLAT-NOT: arith.constant dense<1.000000e+00> : tensor<2x16xf32>
9096// RANDOM-SPLAT-NOT: arith.constant dense<1.000000e+00> : tensor<2x16xf64>
@@ -96,6 +102,9 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
96102// RANDOM-SPLAT: arith.constant dense<{{\[}}{{\[}}0.0440550111, 0.221581057, 0.000000e+00{{.*}}: tensor<4x4xf32>
97103// RANDOM-SPLAT: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
98104// RANDOM-SPLAT: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}> : tensor<2x2xf32>
105+ // RANDOM-SPLAT-NOT: arith.constant dense<1> : tensor<4x2xi8>
106+ // RANDOM-SPLAT: arith.constant dense<{{\[}}{{\[}}67, 63{{.*}}> : tensor<4x2xi8>
107+ // RANDOM-SPLAT-NOT: arith.constant dense<1> : tensor<4x2xi8>
99108// RANDOM-SPLAT: arith.constant dense<0> : tensor<4x8xi32>
100109// RANDOM-SPLAT-NOT: arith.constant dense<1> : tensor<4x8xi32>
101110// RANDOM-SPLAT-NOT: arith.constant dense<1> : tensor<4x8xi64>
@@ -116,6 +125,7 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
116125// OPT-CONST: arith.constant dense<1.000000e+00> : tensor<4x4xf32>
117126// OPT-CONST: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
118127// OPT-CONST: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}>
128+ // OPT-CONST: arith.constant dense<1> : tensor<4x2xi8>
119129// OPT-CONST: arith.constant dense<0> : tensor<4x8xi32>
120130// OPT-CONST: arith.constant dense<1> : tensor<4x8xi32>
121131// OPT-CONST: arith.constant dense<1> : tensor<4x8xi32>
@@ -131,6 +141,8 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
131141// OPT-SIMPLE: arith.constant dense<{{.*}}3.000000e-01, 6.000000e-01, 0.899999976, {{.*}}> : tensor<4x4xf32>
132142// OPT-SIMPLE: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
133143// OPT-SIMPLE: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}>
144+ // OPT-SIMPLE-NOT: arith.constant dense<1> : tensor<4x2xi8>
145+ // OPT-SIMPLE: arith.constant dense<{{\[}}{{\[}}0, 1{{.*}}> : tensor<4x2xi8>
134146// OPT-SIMPLE: arith.constant dense<0> : tensor<4x8xi32>
135147// OPT-SIMPLE-NOT: arith.constant dense<1> : tensor<4x8xi32>
136148// OPT-SIMPLE-NOT: arith.constant dense<1> : tensor<4x8xi64>
@@ -148,6 +160,8 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
148160// OPT-CONT: arith.constant dense<{{.*}}0.000000e+00, 6.250000e-02, 1.250000e-01, {{.*}}> : tensor<4x4xf32>
149161// OPT-CONT: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
150162// OPT-CONT: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}>
163+ // OPT-CONT-NOT: arith.constant dense<1> : tensor<4x2xi8>
164+ // OPT-CONT: arith.constant dense<{{\[}}{{\[}}0, 15{{.*}}> : tensor<4x2xi8>
151165// OPT-CONT: arith.constant dense<0> : tensor<4x8xi32>
152166// OPT-CONT-NOT: arith.constant dense<1> : tensor<4x8xi32>
153167// OPT-CONT-NOT: arith.constant dense<1> : tensor<4x8xi64>
@@ -165,6 +179,8 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
165179// OPT-RANDOM: arith.constant dense<{{.*}}0.685934782, 0.505808651, 0.126024485, {{.*}}> : tensor<4x4xf32>
166180// OPT-RANDOM: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
167181// OPT-RANDOM: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}>
182+ // OPT-RANDOM: arith.constant dense<{{\[}}{{\[}}0, 22{{.*}}> : tensor<4x2xi8>
183+ // OPT-RANDOM-NOT: arith.constant dense<1> : tensor<4x2xi8>
168184// OPT-RANDOM: arith.constant dense<0> : tensor<4x8xi32>
169185// OPT-RANDOM-NOT: arith.constant dense<1> : tensor<4x8xi32>
170186// OPT-RANDOM-NOT: arith.constant dense<1> : tensor<4x8xi64>
@@ -182,6 +198,8 @@ func.func @entry(%arg0: tensor<4x2xf32>, %arg1: tensor<4x2xi32>, %arg2: tensor<4
182198// OPT-NORMAL: arith.constant dense<{{.*}}0.0440550111, 0.221581057, 0.000000e+00, {{.*}}> : tensor<4x4xf32>
183199// OPT-NORMAL: arith.constant dense<0.000000e+00> : tensor<4x8xf32>
184200// OPT-NORMAL: arith.constant dense<{{.*}}0.000000e+00, 1.000000e+00], [2.000000e+00, 3.000000e+00{{.*}}>
201+ // OPT-NORMAL-NOT: arith.constant dense<1> : tensor<4x2xi8>
202+ // OPT-NORMAL: arith.constant dense<{{\[}}{{\[}}67, 63{{.*}}> : tensor<4x2xi8>
185203// OPT-NORMAL: arith.constant dense<0> : tensor<4x8xi32>
186204// OPT-NORMAL-NOT: arith.constant dense<1> : tensor<4x8xi32>
187205// OPT-NORMAL-NOT: arith.constant dense<1> : tensor<4x8xi64>
0 commit comments