1 /* SPDX-License-Identifier: Apache-2.0
2 * Copyright(c) 2021 Cisco Systems, Inc.
5 #include <vppinfra/format.h>
6 #include <vppinfra/vector/test/test.h>
8 test_registration_t *test_registrations[CLIB_MARCH_TYPE_N_VARIANTS] = {};
11 test_march_supported (clib_march_variant_type_t type)
14 if (CLIB_MARCH_VARIANT_TYPE_##s == type) \
15 return clib_cpu_march_priority_##s ();
22 main (int argc, char *argv[])
24 clib_mem_init (0, 64ULL << 20);
26 for (int i = 0; i < CLIB_MARCH_TYPE_N_VARIANTS; i++)
28 test_registration_t *r = test_registrations[i];
30 if (r == 0 || test_march_supported (i) < 0)
33 fformat (stdout, "\nMultiarch Variant: %U\n", format_march_variant, i);
35 "-------------------------------------------------------\n");
40 fformat (stdout, "%-50s %s\n", r->name, err ? "FAIL" : "PASS");
43 clib_error_report (err);
44 fformat (stdout, "\n");
51 fformat (stdout, "\n");