1 // Copyright 2020 Google LLC
2 //
3 // This source code is licensed under the BSD-style license found in the
4 // LICENSE file in the root directory of this source tree.
5 //
6 // Auto-generated file. Do not edit!
7 // Specification: test/f32-ibilinear-chw.yaml
8 // Generator: tools/generate-ibilinear-chw-test.py
9
10
11 #include <gtest/gtest.h>
12
13 #include <xnnpack/common.h>
14 #include <xnnpack/isa-checks.h>
15
16 #include <xnnpack/ibilinear.h>
17 #include "ibilinear-microkernel-tester.h"
18
19
TEST(F32_IBILINEAR_CHW__SCALAR_P1,pixels_eq_1)20 TEST(F32_IBILINEAR_CHW__SCALAR_P1, pixels_eq_1) {
21 IBilinearMicrokernelTester()
22 .pixels(1)
23 .channels(1)
24 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
25 }
26
TEST(F32_IBILINEAR_CHW__SCALAR_P1,pixels_gt_1)27 TEST(F32_IBILINEAR_CHW__SCALAR_P1, pixels_gt_1) {
28 for (size_t pixels = 2; pixels < 10; pixels++) {
29 IBilinearMicrokernelTester()
30 .pixels(pixels)
31 .channels(1)
32 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
33 }
34 }
35
TEST(F32_IBILINEAR_CHW__SCALAR_P1,channels_eq_1)36 TEST(F32_IBILINEAR_CHW__SCALAR_P1, channels_eq_1) {
37 for (size_t pixels = 1; pixels <= 5; pixels += 1) {
38 IBilinearMicrokernelTester()
39 .pixels(pixels)
40 .channels(1)
41 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
42 }
43 }
44
TEST(F32_IBILINEAR_CHW__SCALAR_P1,channels_gt_1)45 TEST(F32_IBILINEAR_CHW__SCALAR_P1, channels_gt_1) {
46 for (size_t channels = 2; channels < 3; channels++) {
47 for (size_t pixels = 1; pixels <= 5; pixels += 1) {
48 IBilinearMicrokernelTester()
49 .pixels(pixels)
50 .channels(channels)
51 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
52 }
53 }
54 }
55
TEST(F32_IBILINEAR_CHW__SCALAR_P1,input_offset)56 TEST(F32_IBILINEAR_CHW__SCALAR_P1, input_offset) {
57 for (size_t pixels = 1; pixels < 5; pixels += 1) {
58 for (size_t channels = 1; channels <= 5; channels += 1) {
59 IBilinearMicrokernelTester()
60 .pixels(pixels)
61 .channels(channels)
62 .input_offset(7)
63 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
64 }
65 }
66 }
67
TEST(F32_IBILINEAR_CHW__SCALAR_P1,input_stride)68 TEST(F32_IBILINEAR_CHW__SCALAR_P1, input_stride) {
69 for (size_t pixels = 1; pixels < 5; pixels += 1) {
70 for (size_t channels = 1; channels <= 5; channels += 1) {
71 IBilinearMicrokernelTester()
72 .pixels(pixels)
73 .channels(channels)
74 .input_stride(23)
75 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p1);
76 }
77 }
78 }
79
80
TEST(F32_IBILINEAR_CHW__SCALAR_P2,pixels_eq_2)81 TEST(F32_IBILINEAR_CHW__SCALAR_P2, pixels_eq_2) {
82 IBilinearMicrokernelTester()
83 .pixels(2)
84 .channels(1)
85 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
86 }
87
TEST(F32_IBILINEAR_CHW__SCALAR_P2,pixels_div_2)88 TEST(F32_IBILINEAR_CHW__SCALAR_P2, pixels_div_2) {
89 for (size_t pixels = 4; pixels < 20; pixels += 2) {
90 IBilinearMicrokernelTester()
91 .pixels(pixels)
92 .channels(1)
93 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
94 }
95 }
96
TEST(F32_IBILINEAR_CHW__SCALAR_P2,pixels_lt_2)97 TEST(F32_IBILINEAR_CHW__SCALAR_P2, pixels_lt_2) {
98 for (size_t pixels = 1; pixels < 2; pixels++) {
99 IBilinearMicrokernelTester()
100 .pixels(pixels)
101 .channels(1)
102 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
103 }
104 }
105
TEST(F32_IBILINEAR_CHW__SCALAR_P2,pixels_gt_2)106 TEST(F32_IBILINEAR_CHW__SCALAR_P2, pixels_gt_2) {
107 for (size_t pixels = 3; pixels < 4; pixels++) {
108 IBilinearMicrokernelTester()
109 .pixels(pixels)
110 .channels(1)
111 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
112 }
113 }
114
TEST(F32_IBILINEAR_CHW__SCALAR_P2,channels_eq_1)115 TEST(F32_IBILINEAR_CHW__SCALAR_P2, channels_eq_1) {
116 for (size_t pixels = 1; pixels <= 10; pixels += 1) {
117 IBilinearMicrokernelTester()
118 .pixels(pixels)
119 .channels(1)
120 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
121 }
122 }
123
TEST(F32_IBILINEAR_CHW__SCALAR_P2,channels_gt_1)124 TEST(F32_IBILINEAR_CHW__SCALAR_P2, channels_gt_1) {
125 for (size_t channels = 2; channels < 3; channels++) {
126 for (size_t pixels = 1; pixels <= 10; pixels += 1) {
127 IBilinearMicrokernelTester()
128 .pixels(pixels)
129 .channels(channels)
130 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
131 }
132 }
133 }
134
TEST(F32_IBILINEAR_CHW__SCALAR_P2,input_offset)135 TEST(F32_IBILINEAR_CHW__SCALAR_P2, input_offset) {
136 for (size_t pixels = 1; pixels < 10; pixels += 1) {
137 for (size_t channels = 1; channels <= 5; channels += 1) {
138 IBilinearMicrokernelTester()
139 .pixels(pixels)
140 .channels(channels)
141 .input_offset(7)
142 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
143 }
144 }
145 }
146
TEST(F32_IBILINEAR_CHW__SCALAR_P2,input_stride)147 TEST(F32_IBILINEAR_CHW__SCALAR_P2, input_stride) {
148 for (size_t pixels = 1; pixels < 10; pixels += 1) {
149 for (size_t channels = 1; channels <= 5; channels += 1) {
150 IBilinearMicrokernelTester()
151 .pixels(pixels)
152 .channels(channels)
153 .input_stride(43)
154 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p2);
155 }
156 }
157 }
158
159
TEST(F32_IBILINEAR_CHW__SCALAR_P4,pixels_eq_4)160 TEST(F32_IBILINEAR_CHW__SCALAR_P4, pixels_eq_4) {
161 IBilinearMicrokernelTester()
162 .pixels(4)
163 .channels(1)
164 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
165 }
166
TEST(F32_IBILINEAR_CHW__SCALAR_P4,pixels_div_4)167 TEST(F32_IBILINEAR_CHW__SCALAR_P4, pixels_div_4) {
168 for (size_t pixels = 8; pixels < 40; pixels += 4) {
169 IBilinearMicrokernelTester()
170 .pixels(pixels)
171 .channels(1)
172 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
173 }
174 }
175
TEST(F32_IBILINEAR_CHW__SCALAR_P4,pixels_lt_4)176 TEST(F32_IBILINEAR_CHW__SCALAR_P4, pixels_lt_4) {
177 for (size_t pixels = 1; pixels < 4; pixels++) {
178 IBilinearMicrokernelTester()
179 .pixels(pixels)
180 .channels(1)
181 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
182 }
183 }
184
TEST(F32_IBILINEAR_CHW__SCALAR_P4,pixels_gt_4)185 TEST(F32_IBILINEAR_CHW__SCALAR_P4, pixels_gt_4) {
186 for (size_t pixels = 5; pixels < 8; pixels++) {
187 IBilinearMicrokernelTester()
188 .pixels(pixels)
189 .channels(1)
190 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
191 }
192 }
193
TEST(F32_IBILINEAR_CHW__SCALAR_P4,channels_eq_1)194 TEST(F32_IBILINEAR_CHW__SCALAR_P4, channels_eq_1) {
195 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
196 IBilinearMicrokernelTester()
197 .pixels(pixels)
198 .channels(1)
199 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
200 }
201 }
202
TEST(F32_IBILINEAR_CHW__SCALAR_P4,channels_gt_1)203 TEST(F32_IBILINEAR_CHW__SCALAR_P4, channels_gt_1) {
204 for (size_t channels = 2; channels < 3; channels++) {
205 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
206 IBilinearMicrokernelTester()
207 .pixels(pixels)
208 .channels(channels)
209 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
210 }
211 }
212 }
213
TEST(F32_IBILINEAR_CHW__SCALAR_P4,input_offset)214 TEST(F32_IBILINEAR_CHW__SCALAR_P4, input_offset) {
215 for (size_t pixels = 1; pixels < 20; pixels += 3) {
216 for (size_t channels = 1; channels <= 5; channels += 1) {
217 IBilinearMicrokernelTester()
218 .pixels(pixels)
219 .channels(channels)
220 .input_offset(7)
221 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
222 }
223 }
224 }
225
TEST(F32_IBILINEAR_CHW__SCALAR_P4,input_stride)226 TEST(F32_IBILINEAR_CHW__SCALAR_P4, input_stride) {
227 for (size_t pixels = 1; pixels < 20; pixels += 3) {
228 for (size_t channels = 1; channels <= 5; channels += 1) {
229 IBilinearMicrokernelTester()
230 .pixels(pixels)
231 .channels(channels)
232 .input_stride(83)
233 .TestCHW(xnn_f32_ibilinear_chw_ukernel__scalar_p4);
234 }
235 }
236 }
237
238
239 #if XNN_ARCH_WASMSIMD
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,pixels_eq_4)240 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, pixels_eq_4) {
241 IBilinearMicrokernelTester()
242 .pixels(4)
243 .channels(1)
244 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
245 }
246
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,pixels_div_4)247 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, pixels_div_4) {
248 for (size_t pixels = 8; pixels < 40; pixels += 4) {
249 IBilinearMicrokernelTester()
250 .pixels(pixels)
251 .channels(1)
252 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
253 }
254 }
255
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,pixels_lt_4)256 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, pixels_lt_4) {
257 for (size_t pixels = 1; pixels < 4; pixels++) {
258 IBilinearMicrokernelTester()
259 .pixels(pixels)
260 .channels(1)
261 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
262 }
263 }
264
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,pixels_gt_4)265 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, pixels_gt_4) {
266 for (size_t pixels = 5; pixels < 8; pixels++) {
267 IBilinearMicrokernelTester()
268 .pixels(pixels)
269 .channels(1)
270 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
271 }
272 }
273
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,channels_eq_1)274 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, channels_eq_1) {
275 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
276 IBilinearMicrokernelTester()
277 .pixels(pixels)
278 .channels(1)
279 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
280 }
281 }
282
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,channels_gt_1)283 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, channels_gt_1) {
284 for (size_t channels = 2; channels < 3; channels++) {
285 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
286 IBilinearMicrokernelTester()
287 .pixels(pixels)
288 .channels(channels)
289 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
290 }
291 }
292 }
293
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,input_offset)294 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, input_offset) {
295 for (size_t pixels = 1; pixels < 20; pixels += 3) {
296 for (size_t channels = 1; channels <= 5; channels += 1) {
297 IBilinearMicrokernelTester()
298 .pixels(pixels)
299 .channels(channels)
300 .input_offset(7)
301 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
302 }
303 }
304 }
305
TEST(F32_IBILINEAR_CHW__WASMSIMD_P4,input_stride)306 TEST(F32_IBILINEAR_CHW__WASMSIMD_P4, input_stride) {
307 for (size_t pixels = 1; pixels < 20; pixels += 3) {
308 for (size_t channels = 1; channels <= 5; channels += 1) {
309 IBilinearMicrokernelTester()
310 .pixels(pixels)
311 .channels(channels)
312 .input_stride(83)
313 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p4);
314 }
315 }
316 }
317 #endif // XNN_ARCH_WASMSIMD
318
319
320 #if XNN_ARCH_WASMSIMD
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,pixels_eq_8)321 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, pixels_eq_8) {
322 IBilinearMicrokernelTester()
323 .pixels(8)
324 .channels(1)
325 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
326 }
327
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,pixels_div_8)328 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, pixels_div_8) {
329 for (size_t pixels = 16; pixels < 80; pixels += 8) {
330 IBilinearMicrokernelTester()
331 .pixels(pixels)
332 .channels(1)
333 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
334 }
335 }
336
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,pixels_lt_8)337 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, pixels_lt_8) {
338 for (size_t pixels = 1; pixels < 8; pixels++) {
339 IBilinearMicrokernelTester()
340 .pixels(pixels)
341 .channels(1)
342 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
343 }
344 }
345
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,pixels_gt_8)346 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, pixels_gt_8) {
347 for (size_t pixels = 9; pixels < 16; pixels++) {
348 IBilinearMicrokernelTester()
349 .pixels(pixels)
350 .channels(1)
351 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
352 }
353 }
354
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,channels_eq_1)355 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, channels_eq_1) {
356 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
357 IBilinearMicrokernelTester()
358 .pixels(pixels)
359 .channels(1)
360 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
361 }
362 }
363
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,channels_gt_1)364 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, channels_gt_1) {
365 for (size_t channels = 2; channels < 3; channels++) {
366 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
367 IBilinearMicrokernelTester()
368 .pixels(pixels)
369 .channels(channels)
370 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
371 }
372 }
373 }
374
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,input_offset)375 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, input_offset) {
376 for (size_t pixels = 1; pixels < 40; pixels += 7) {
377 for (size_t channels = 1; channels <= 5; channels += 1) {
378 IBilinearMicrokernelTester()
379 .pixels(pixels)
380 .channels(channels)
381 .input_offset(7)
382 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
383 }
384 }
385 }
386
TEST(F32_IBILINEAR_CHW__WASMSIMD_P8,input_stride)387 TEST(F32_IBILINEAR_CHW__WASMSIMD_P8, input_stride) {
388 for (size_t pixels = 1; pixels < 40; pixels += 7) {
389 for (size_t channels = 1; channels <= 5; channels += 1) {
390 IBilinearMicrokernelTester()
391 .pixels(pixels)
392 .channels(channels)
393 .input_stride(163)
394 .TestCHW(xnn_f32_ibilinear_chw_ukernel__wasmsimd_p8);
395 }
396 }
397 }
398 #endif // XNN_ARCH_WASMSIMD
399
400
401 #if XNN_ARCH_ARM || XNN_ARCH_ARM64
TEST(F32_IBILINEAR_CHW__NEON_P4,pixels_eq_4)402 TEST(F32_IBILINEAR_CHW__NEON_P4, pixels_eq_4) {
403 TEST_REQUIRES_ARM_NEON;
404 IBilinearMicrokernelTester()
405 .pixels(4)
406 .channels(1)
407 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
408 }
409
TEST(F32_IBILINEAR_CHW__NEON_P4,pixels_div_4)410 TEST(F32_IBILINEAR_CHW__NEON_P4, pixels_div_4) {
411 TEST_REQUIRES_ARM_NEON;
412 for (size_t pixels = 8; pixels < 40; pixels += 4) {
413 IBilinearMicrokernelTester()
414 .pixels(pixels)
415 .channels(1)
416 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
417 }
418 }
419
TEST(F32_IBILINEAR_CHW__NEON_P4,pixels_lt_4)420 TEST(F32_IBILINEAR_CHW__NEON_P4, pixels_lt_4) {
421 TEST_REQUIRES_ARM_NEON;
422 for (size_t pixels = 1; pixels < 4; pixels++) {
423 IBilinearMicrokernelTester()
424 .pixels(pixels)
425 .channels(1)
426 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
427 }
428 }
429
TEST(F32_IBILINEAR_CHW__NEON_P4,pixels_gt_4)430 TEST(F32_IBILINEAR_CHW__NEON_P4, pixels_gt_4) {
431 TEST_REQUIRES_ARM_NEON;
432 for (size_t pixels = 5; pixels < 8; pixels++) {
433 IBilinearMicrokernelTester()
434 .pixels(pixels)
435 .channels(1)
436 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
437 }
438 }
439
TEST(F32_IBILINEAR_CHW__NEON_P4,channels_eq_1)440 TEST(F32_IBILINEAR_CHW__NEON_P4, channels_eq_1) {
441 TEST_REQUIRES_ARM_NEON;
442 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
443 IBilinearMicrokernelTester()
444 .pixels(pixels)
445 .channels(1)
446 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
447 }
448 }
449
TEST(F32_IBILINEAR_CHW__NEON_P4,channels_gt_1)450 TEST(F32_IBILINEAR_CHW__NEON_P4, channels_gt_1) {
451 TEST_REQUIRES_ARM_NEON;
452 for (size_t channels = 2; channels < 3; channels++) {
453 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
454 IBilinearMicrokernelTester()
455 .pixels(pixels)
456 .channels(channels)
457 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
458 }
459 }
460 }
461
TEST(F32_IBILINEAR_CHW__NEON_P4,input_offset)462 TEST(F32_IBILINEAR_CHW__NEON_P4, input_offset) {
463 TEST_REQUIRES_ARM_NEON;
464 for (size_t pixels = 1; pixels < 20; pixels += 3) {
465 for (size_t channels = 1; channels <= 5; channels += 1) {
466 IBilinearMicrokernelTester()
467 .pixels(pixels)
468 .channels(channels)
469 .input_offset(7)
470 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
471 }
472 }
473 }
474
TEST(F32_IBILINEAR_CHW__NEON_P4,input_stride)475 TEST(F32_IBILINEAR_CHW__NEON_P4, input_stride) {
476 TEST_REQUIRES_ARM_NEON;
477 for (size_t pixels = 1; pixels < 20; pixels += 3) {
478 for (size_t channels = 1; channels <= 5; channels += 1) {
479 IBilinearMicrokernelTester()
480 .pixels(pixels)
481 .channels(channels)
482 .input_stride(83)
483 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p4);
484 }
485 }
486 }
487 #endif // XNN_ARCH_ARM || XNN_ARCH_ARM64
488
489
490 #if XNN_ARCH_ARM || XNN_ARCH_ARM64
TEST(F32_IBILINEAR_CHW__NEON_P8,pixels_eq_8)491 TEST(F32_IBILINEAR_CHW__NEON_P8, pixels_eq_8) {
492 TEST_REQUIRES_ARM_NEON;
493 IBilinearMicrokernelTester()
494 .pixels(8)
495 .channels(1)
496 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
497 }
498
TEST(F32_IBILINEAR_CHW__NEON_P8,pixels_div_8)499 TEST(F32_IBILINEAR_CHW__NEON_P8, pixels_div_8) {
500 TEST_REQUIRES_ARM_NEON;
501 for (size_t pixels = 16; pixels < 80; pixels += 8) {
502 IBilinearMicrokernelTester()
503 .pixels(pixels)
504 .channels(1)
505 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
506 }
507 }
508
TEST(F32_IBILINEAR_CHW__NEON_P8,pixels_lt_8)509 TEST(F32_IBILINEAR_CHW__NEON_P8, pixels_lt_8) {
510 TEST_REQUIRES_ARM_NEON;
511 for (size_t pixels = 1; pixels < 8; pixels++) {
512 IBilinearMicrokernelTester()
513 .pixels(pixels)
514 .channels(1)
515 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
516 }
517 }
518
TEST(F32_IBILINEAR_CHW__NEON_P8,pixels_gt_8)519 TEST(F32_IBILINEAR_CHW__NEON_P8, pixels_gt_8) {
520 TEST_REQUIRES_ARM_NEON;
521 for (size_t pixels = 9; pixels < 16; pixels++) {
522 IBilinearMicrokernelTester()
523 .pixels(pixels)
524 .channels(1)
525 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
526 }
527 }
528
TEST(F32_IBILINEAR_CHW__NEON_P8,channels_eq_1)529 TEST(F32_IBILINEAR_CHW__NEON_P8, channels_eq_1) {
530 TEST_REQUIRES_ARM_NEON;
531 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
532 IBilinearMicrokernelTester()
533 .pixels(pixels)
534 .channels(1)
535 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
536 }
537 }
538
TEST(F32_IBILINEAR_CHW__NEON_P8,channels_gt_1)539 TEST(F32_IBILINEAR_CHW__NEON_P8, channels_gt_1) {
540 TEST_REQUIRES_ARM_NEON;
541 for (size_t channels = 2; channels < 3; channels++) {
542 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
543 IBilinearMicrokernelTester()
544 .pixels(pixels)
545 .channels(channels)
546 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
547 }
548 }
549 }
550
TEST(F32_IBILINEAR_CHW__NEON_P8,input_offset)551 TEST(F32_IBILINEAR_CHW__NEON_P8, input_offset) {
552 TEST_REQUIRES_ARM_NEON;
553 for (size_t pixels = 1; pixels < 40; pixels += 7) {
554 for (size_t channels = 1; channels <= 5; channels += 1) {
555 IBilinearMicrokernelTester()
556 .pixels(pixels)
557 .channels(channels)
558 .input_offset(7)
559 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
560 }
561 }
562 }
563
TEST(F32_IBILINEAR_CHW__NEON_P8,input_stride)564 TEST(F32_IBILINEAR_CHW__NEON_P8, input_stride) {
565 TEST_REQUIRES_ARM_NEON;
566 for (size_t pixels = 1; pixels < 40; pixels += 7) {
567 for (size_t channels = 1; channels <= 5; channels += 1) {
568 IBilinearMicrokernelTester()
569 .pixels(pixels)
570 .channels(channels)
571 .input_stride(163)
572 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neon_p8);
573 }
574 }
575 }
576 #endif // XNN_ARCH_ARM || XNN_ARCH_ARM64
577
578
579 #if XNN_ARCH_ARM || XNN_ARCH_ARM64
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,pixels_eq_4)580 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, pixels_eq_4) {
581 TEST_REQUIRES_ARM_NEON_FMA;
582 IBilinearMicrokernelTester()
583 .pixels(4)
584 .channels(1)
585 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
586 }
587
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,pixels_div_4)588 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, pixels_div_4) {
589 TEST_REQUIRES_ARM_NEON_FMA;
590 for (size_t pixels = 8; pixels < 40; pixels += 4) {
591 IBilinearMicrokernelTester()
592 .pixels(pixels)
593 .channels(1)
594 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
595 }
596 }
597
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,pixels_lt_4)598 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, pixels_lt_4) {
599 TEST_REQUIRES_ARM_NEON_FMA;
600 for (size_t pixels = 1; pixels < 4; pixels++) {
601 IBilinearMicrokernelTester()
602 .pixels(pixels)
603 .channels(1)
604 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
605 }
606 }
607
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,pixels_gt_4)608 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, pixels_gt_4) {
609 TEST_REQUIRES_ARM_NEON_FMA;
610 for (size_t pixels = 5; pixels < 8; pixels++) {
611 IBilinearMicrokernelTester()
612 .pixels(pixels)
613 .channels(1)
614 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
615 }
616 }
617
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,channels_eq_1)618 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, channels_eq_1) {
619 TEST_REQUIRES_ARM_NEON_FMA;
620 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
621 IBilinearMicrokernelTester()
622 .pixels(pixels)
623 .channels(1)
624 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
625 }
626 }
627
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,channels_gt_1)628 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, channels_gt_1) {
629 TEST_REQUIRES_ARM_NEON_FMA;
630 for (size_t channels = 2; channels < 3; channels++) {
631 for (size_t pixels = 1; pixels <= 20; pixels += 3) {
632 IBilinearMicrokernelTester()
633 .pixels(pixels)
634 .channels(channels)
635 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
636 }
637 }
638 }
639
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,input_offset)640 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, input_offset) {
641 TEST_REQUIRES_ARM_NEON_FMA;
642 for (size_t pixels = 1; pixels < 20; pixels += 3) {
643 for (size_t channels = 1; channels <= 5; channels += 1) {
644 IBilinearMicrokernelTester()
645 .pixels(pixels)
646 .channels(channels)
647 .input_offset(7)
648 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
649 }
650 }
651 }
652
TEST(F32_IBILINEAR_CHW__NEONFMA_P4,input_stride)653 TEST(F32_IBILINEAR_CHW__NEONFMA_P4, input_stride) {
654 TEST_REQUIRES_ARM_NEON_FMA;
655 for (size_t pixels = 1; pixels < 20; pixels += 3) {
656 for (size_t channels = 1; channels <= 5; channels += 1) {
657 IBilinearMicrokernelTester()
658 .pixels(pixels)
659 .channels(channels)
660 .input_stride(83)
661 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p4);
662 }
663 }
664 }
665 #endif // XNN_ARCH_ARM || XNN_ARCH_ARM64
666
667
668 #if XNN_ARCH_ARM || XNN_ARCH_ARM64
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,pixels_eq_8)669 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, pixels_eq_8) {
670 TEST_REQUIRES_ARM_NEON_FMA;
671 IBilinearMicrokernelTester()
672 .pixels(8)
673 .channels(1)
674 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
675 }
676
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,pixels_div_8)677 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, pixels_div_8) {
678 TEST_REQUIRES_ARM_NEON_FMA;
679 for (size_t pixels = 16; pixels < 80; pixels += 8) {
680 IBilinearMicrokernelTester()
681 .pixels(pixels)
682 .channels(1)
683 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
684 }
685 }
686
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,pixels_lt_8)687 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, pixels_lt_8) {
688 TEST_REQUIRES_ARM_NEON_FMA;
689 for (size_t pixels = 1; pixels < 8; pixels++) {
690 IBilinearMicrokernelTester()
691 .pixels(pixels)
692 .channels(1)
693 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
694 }
695 }
696
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,pixels_gt_8)697 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, pixels_gt_8) {
698 TEST_REQUIRES_ARM_NEON_FMA;
699 for (size_t pixels = 9; pixels < 16; pixels++) {
700 IBilinearMicrokernelTester()
701 .pixels(pixels)
702 .channels(1)
703 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
704 }
705 }
706
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,channels_eq_1)707 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, channels_eq_1) {
708 TEST_REQUIRES_ARM_NEON_FMA;
709 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
710 IBilinearMicrokernelTester()
711 .pixels(pixels)
712 .channels(1)
713 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
714 }
715 }
716
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,channels_gt_1)717 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, channels_gt_1) {
718 TEST_REQUIRES_ARM_NEON_FMA;
719 for (size_t channels = 2; channels < 3; channels++) {
720 for (size_t pixels = 1; pixels <= 40; pixels += 7) {
721 IBilinearMicrokernelTester()
722 .pixels(pixels)
723 .channels(channels)
724 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
725 }
726 }
727 }
728
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,input_offset)729 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, input_offset) {
730 TEST_REQUIRES_ARM_NEON_FMA;
731 for (size_t pixels = 1; pixels < 40; pixels += 7) {
732 for (size_t channels = 1; channels <= 5; channels += 1) {
733 IBilinearMicrokernelTester()
734 .pixels(pixels)
735 .channels(channels)
736 .input_offset(7)
737 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
738 }
739 }
740 }
741
TEST(F32_IBILINEAR_CHW__NEONFMA_P8,input_stride)742 TEST(F32_IBILINEAR_CHW__NEONFMA_P8, input_stride) {
743 TEST_REQUIRES_ARM_NEON_FMA;
744 for (size_t pixels = 1; pixels < 40; pixels += 7) {
745 for (size_t channels = 1; channels <= 5; channels += 1) {
746 IBilinearMicrokernelTester()
747 .pixels(pixels)
748 .channels(channels)
749 .input_stride(163)
750 .TestCHW(xnn_f32_ibilinear_chw_ukernel__neonfma_p8);
751 }
752 }
753 }
754 #endif // XNN_ARCH_ARM || XNN_ARCH_ARM64
755