| 1 | // |
| 2 | // SPDX-FileCopyrightText: Copyright 2025-2026 Arm Limited and/or its affiliates <open-source-office@arm.com> |
| 3 | // |
| 4 | // SPDX-License-Identifier: Apache-2.0 |
| 5 | // |
| 6 | |
| 7 | #include "matmul_registry.hpp" |
| 8 | |
| 9 | #include <array> |
| 10 | #include <cstddef> |
| 11 | #include <cstdint> |
| 12 | #include <test/common/cpu_info.hpp> |
| 13 | #include <test/common/data_type.hpp> |
| 14 | |
| 15 | #include "kai/ukernels/matmul/kai_matmul.h" |
| 16 | #include "kai/ukernels/matmul/kai_matmul_types.h" |
| 17 | #include "matmul_benchmark_logic.hpp" |
| 18 | #include "matmul_interface.hpp" |
| 19 | |
| 20 | #ifdef __GNUC__ |
| 21 | #pragma GCC diagnostic push |
| 22 | #pragma GCC diagnostic ignored "-Wswitch-default" |
| 23 | #endif // __GNUC__ |
| 24 | |
| 25 | #include <benchmark/benchmark.h> |
| 26 | |
| 27 | #ifdef __GNUC__ |
| 28 | #pragma GCC diagnostic pop |
| 29 | #endif // __GNUC__ |
| 30 | |
| 31 | // Micro-kernels to register for benchmarking |
| 32 | |
| 33 | // matmul_clamp_f16_bf16p_bf16p |
| 34 | #include "kai/ukernels/matmul/matmul_clamp_f16_bf16p_bf16p/kai_matmul_clamp_f16_bf16p8x4_bf16p12x4b_8x12_neon_mmla.h" |
| 35 | |
| 36 | // matmul_clamp_f16_f16_f16p |
| 37 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16_f16p/kai_matmul_clamp_f16_f16_f16p16x1biasf16_6x16x8_neon_mla.h" |
| 38 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16_f16p/kai_matmul_clamp_f16_f16_f16p2vlx2b_1x16vl_sme2_dot.h" |
| 39 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16_f16p/kai_matmul_clamp_f16_f16_f16p2vlx2b_1x8vl_sme_mla.h" |
| 40 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16_f16p/kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla.h" |
| 41 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16_f16p/kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_cortexa55.h" |
| 42 | |
| 43 | // matmul_clamp_f16_f16p_f16p |
| 44 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16p_f16p/kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2_2vlx2vl_sme2_mopa.h" |
| 45 | #include "kai/ukernels/matmul/matmul_clamp_f16_f16p_f16p/kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2b_2vlx2vl_sme_mopa.h" |
| 46 | |
| 47 | // matmul_clamp_f32_bf16p_bf16p |
| 48 | #include "kai/ukernels/matmul/matmul_clamp_f32_bf16p_bf16p/kai_matmul_clamp_f32_bf16p1x4_bf16p12x4b_1x36_neon_dot.h" |
| 49 | #include "kai/ukernels/matmul/matmul_clamp_f32_bf16p_bf16p/kai_matmul_clamp_f32_bf16p8x4_bf16p12x4b_8x12_neon_mmla.h" |
| 50 | |
| 51 | // matmul_clamp_f32_f16p_qsi4c32p |
| 52 | #include "kai/ukernels/matmul/matmul_clamp_f32_f16p_qsi4c32p/kai_matmul_clamp_f32_f16p1vlx2_qsi4c32p4vlx2_1vlx4vl_sme2_mopa.h" |
| 53 | |
| 54 | // matmul_clamp_f32_f32_f32p |
| 55 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p16vlx1b_1x16vl_sme2_mla.h" |
| 56 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla.h" |
| 57 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_cortexa55.h" |
| 58 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p2vlx1b_1x16vl_sme2_mla.h" |
| 59 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p2vlx1b_1x8vl_sme_mla.h" |
| 60 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p4vlx1b_6x4vl_sve_mla.h" |
| 61 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32_f32p/kai_matmul_clamp_f32_f32_f32p8x1biasf32_6x8x4_neon_mla.h" |
| 62 | |
| 63 | // matmul_clamp_f32_f32p_f32p |
| 64 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32p_f32p/kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1b_2vlx2vl_sme_mopa.h" |
| 65 | #include "kai/ukernels/matmul/matmul_clamp_f32_f32p_f32p/kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1biasf32_sme2_mopa.h" |
| 66 | |
| 67 | // matmul_clamp_f32_qai8dxp_qsu2cxp |
| 68 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsu2cxp/kai_matmul_clamp_f32_qai8dxp1vlx4_qsu2cxp4vlx4_1vlx4vl_sme2_mopa.h" |
| 69 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsu2cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4vlx4_1x4vl_sme2_dot.h" |
| 70 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsu2cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4x4bf32sf32_1x4_neon_dotprod.h" |
| 71 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsu2cxp/kai_matmul_clamp_f32_qai8dxp4x4_qsu2cxp4x4bf32sf32_8x4_neon_dotprod.h" |
| 72 | |
| 73 | // matmul_clamp_f32_qai8dxp_qsi4c32p |
| 74 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa.h" |
| 75 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4vlx4_1x4vl_sme2_dot.h" |
| 76 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4x4_1x4_neon_dotprod.h" |
| 77 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p8x4_1x8_neon_dotprod.h" |
| 78 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod.h" |
| 79 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8_neon_dotprod.h" |
| 80 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod.h" |
| 81 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p4x4_16x4_neon_dotprod.h" |
| 82 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p8x4_4x8_neon_dotprod.h" |
| 83 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_16x4x32_neon_i8mm.h" |
| 84 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_8x4x32_neon_i8mm.h" |
| 85 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8_neon_i8mm.h" |
| 86 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4c32p/kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8x32_neon_i8mm.h" |
| 87 | |
| 88 | // matmul_clamp_f32_qai8dxp_qsi4cxp |
| 89 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4cxp4vlx4_1vlx4vl_sme_mopa.h" |
| 90 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa.h" |
| 91 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot.h" |
| 92 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme_dot.h" |
| 93 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod.h" |
| 94 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp4x8_1x4x32_neon_dotprod.h" |
| 95 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp8x8_1x8x32_neon_dotprod.h" |
| 96 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x4_qsi4cxp8x4_8x8x32_neon_dotprod.h" |
| 97 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x4_16x4x32_neon_dotprod.h" |
| 98 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_4x4x32_neon_i8mm.h" |
| 99 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_8x4x32_neon_i8mm.h" |
| 100 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_4x8x32_neon_i8mm.h" |
| 101 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi4cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_8x8x32_neon_i8mm.h" |
| 102 | |
| 103 | // matmul_clamp_f32_qai8dxp_qsi8cxp |
| 104 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa.h" |
| 105 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme_mopa.h" |
| 106 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot.h" |
| 107 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme_dot.h" |
| 108 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod.h" |
| 109 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod.h" |
| 110 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod.h" |
| 111 | #include "kai/ukernels/matmul/matmul_clamp_f32_qai8dxp_qsi8cxp/kai_matmul_clamp_f32_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm.h" |
| 112 | |
| 113 | // matmul_clamp_f32_qsi8d32p_qsi4c32p |
| 114 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa.h" |
| 115 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme_mopa.h" |
| 116 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme2_sdot.h" |
| 117 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme_dot.h" |
| 118 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4x4_1x4_neon_dotprod.h" |
| 119 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p8x4_1x8_sve_dotprod.h" |
| 120 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p4x8_1x4x32_neon_dotprod.h" |
| 121 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p8x8_1x8_sve_dotprod.h" |
| 122 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p4x4_qsi4c32p4x4_16x4_neon_dotprod.h" |
| 123 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_16x4_neon_i8mm.h" |
| 124 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_8x4x32_neon_i8mm.h" |
| 125 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qsi4c32p/kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p8x8_16x8_sve_i8mm.h" |
| 126 | |
| 127 | // matmul_clamp_fp32_bf16p_bf16p |
| 128 | #include "kai/ukernels/matmul/matmul_clamp_fp32_bf16p_bf16p/kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme2_mopa.h" |
| 129 | #include "kai/ukernels/matmul/matmul_clamp_fp32_bf16p_bf16p/kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme_mopa.h" |
| 130 | |
| 131 | // matmul_clamp_qai8_qai8_qsi8cxp |
| 132 | #include "kai/ukernels/matmul/matmul_clamp_qai8_qai8_qsi8cxp/kai_matmul_clamp_qai8_qai8_qsi8cxp2vlx4sb_1x16vl_sme2_dot.h" |
| 133 | |
| 134 | // matmul_clamp_qai8_qai8p_qsi8cxp |
| 135 | #include "kai/ukernels/matmul/matmul_clamp_qai8_qai8p_qsi8cxp/kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxp2vlx4sb_2vlx2vl_sme_mopa.h" |
| 136 | #include "kai/ukernels/matmul/matmul_clamp_qai8_qai8p_qsi8cxp/kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxpsb2vlx4_2vlx2vl_sme2_mopa.h" |
| 137 | |
| 138 | // matmul_clamp_f16_qai8dxp_qsi4cxp |
| 139 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa.h" |
| 140 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot.h" |
| 141 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod.h" |
| 142 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp1x8_qsi4cxp4x8_1x4_neon_dotprod.h" |
| 143 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp4x4_qsi4cxp4x4_16x4_neon_dotprod.h" |
| 144 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi4cxp/kai_matmul_clamp_f16_qai8dxp4x8_qsi4cxp4x8_16x4_neon_i8mm.h" |
| 145 | |
| 146 | // matmul_clamp_f16_qai8dxp_qsi8cxp |
| 147 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa.h" |
| 148 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot.h" |
| 149 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod.h" |
| 150 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod.h" |
| 151 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod.h" |
| 152 | #include "kai/ukernels/matmul/matmul_clamp_f16_qai8dxp_qsi8cxp/kai_matmul_clamp_f16_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm.h" |
| 153 | |
| 154 | // matmul_clamp_f16_qsi8d32p_qai4c32p |
| 155 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa.h" |
| 156 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot.h" |
| 157 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod.h" |
| 158 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod.h" |
| 159 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod.h" |
| 160 | #include "kai/ukernels/matmul/matmul_clamp_f16_qsi8d32p_qai4c32p/kai_matmul_clamp_f16_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm.h" |
| 161 | |
| 162 | // matmul_clamp_f32_qsi8d32p_qai4c32p |
| 163 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa.h" |
| 164 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot.h" |
| 165 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod.h" |
| 166 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod.h" |
| 167 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod.h" |
| 168 | #include "kai/ukernels/matmul/matmul_clamp_f32_qsi8d32p_qai4c32p/kai_matmul_clamp_f32_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm.h" |
| 169 | |
| 170 | // matmul_clamp_bf16_qai8dxp_qsi4c32p |
| 171 | #include "kai/ukernels/matmul/matmul_clamp_bf16_qai8dxp_qsi4c32p/kai_matmul_clamp_bf16_qai8dxp1x8_qsi4c32p4x8_1x4_neon_dotprod.h" |
| 172 | #include "kai/ukernels/matmul/matmul_clamp_bf16_qai8dxp_qsi4c32p/kai_matmul_clamp_bf16_qai8dxp4x8_qsi4c32p4x8_16x4_neon_i8mm.h" |
| 173 | |
| 174 | // matmul_clamp_bf16_qai8dxp_qsi4cxp |
| 175 | #include "kai/ukernels/matmul/matmul_clamp_bf16_qai8dxp_qsi4cxp/kai_matmul_clamp_bf16_qai8dxp1x8_qsi4cxp8x8_1x8_neon_dotprod.h" |
| 176 | #include "kai/ukernels/matmul/matmul_clamp_bf16_qai8dxp_qsi4cxp/kai_matmul_clamp_bf16_qai8dxp4x8_qsi4cxp8x8_8x8_neon_i8mm.h" |
| 177 | |
| 178 | namespace kai::benchmark { |
| 179 | using DataType = test::DataType; |
| 180 | |
| 181 | // matmul_clamp_f16_bf16p_bf16p |
| 182 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_bf16p8x4_bf16p12x4b_8x12_neon_mmla_interface{ |
| 183 | .run_matmul = kai_run_matmul_clamp_f16_bf16p8x4_bf16p12x4b_8x12_neon_mmla, |
| 184 | }; |
| 185 | |
| 186 | // matmul_clamp_f16_f16_f16p |
| 187 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f16_f16_f16p2vlx2b_1x8vl_sme_mla_interface{ |
| 188 | .run_matmul = kai_run_matmul_clamp_f16_f16_f16p2vlx2b_1x8vl_sme_mla, |
| 189 | }; |
| 190 | |
| 191 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f16_f16_f16p2vlx2b_1x16vl_sme2_dot_interface{ |
| 192 | .run_matmul = kai_run_matmul_clamp_f16_f16_f16p2vlx2b_1x16vl_sme2_dot, |
| 193 | }; |
| 194 | |
| 195 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f16_f16_f16p16x1biasf16_6x16x8_neon_mla_interface{ |
| 196 | .run_matmul = kai_run_matmul_clamp_f16_f16_f16p16x1biasf16_6x16x8_neon_mla, |
| 197 | }; |
| 198 | |
| 199 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_interface{ |
| 200 | .run_matmul = kai_run_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla, |
| 201 | }; |
| 202 | |
| 203 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_cortexa55_interface{ |
| 204 | .run_matmul = kai_run_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_cortexa55, |
| 205 | }; |
| 206 | |
| 207 | inline constexpr MatMulUkernelApiInterface kai_matmul_clamp_f16_f16_f16p16vsx2bf16_6x16vs_sve2p1_dot_interface{ |
| 208 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 209 | .get_api = kai_matmul_clamp_f16_f16_f16p16vsx2bf16_6x16vs_sve2p1_dot, |
| 210 | }; |
| 211 | |
| 212 | // matmul_clamp_f16_f16p_f16p |
| 213 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2_2vlx2vl_sme2_mopa_interface{ |
| 214 | .run_matmul = kai_run_matmul_clamp_f16_f16p2vlx2_f16p2vlx2_2vlx2vl_sme2_mopa, |
| 215 | }; |
| 216 | |
| 217 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2b_2vlx2vl_sme_mopa_interface{ |
| 218 | .run_matmul = kai_run_matmul_clamp_f16_f16p2vlx2_f16p2vlx2b_2vlx2vl_sme_mopa, |
| 219 | }; |
| 220 | |
| 221 | // matmul_clamp_f32_bf16p_bf16p |
| 222 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_bf16p1x4_bf16p12x4b_1x36_neon_dot_interface{ |
| 223 | .run_matmul = kai_run_matmul_clamp_f32_bf16p1x4_bf16p12x4b_1x36_neon_dot, |
| 224 | }; |
| 225 | |
| 226 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_bf16p8x4_bf16p12x4b_8x12_neon_mmla_interface{ |
| 227 | .run_matmul = kai_run_matmul_clamp_f32_bf16p8x4_bf16p12x4b_8x12_neon_mmla, |
| 228 | }; |
| 229 | |
| 230 | // matmul_clamp_f32_f16p_qsi4c32p |
| 231 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 232 | kai_matmul_clamp_f32_f16p1vlx2_qsi4c32p4vlx2_1vlx4vl_sme2_mopa_interface{ |
| 233 | .run_matmul = kai_run_matmul_clamp_f32_f16p1vlx2_qsi4c32p4vlx2_1vlx4vl_sme2_mopa, |
| 234 | }; |
| 235 | |
| 236 | // matmul_clamp_f32_f32_f32p |
| 237 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p2vlx1b_1x16vl_sme2_mla_interface{ |
| 238 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p2vlx1b_1x16vl_sme2_mla, |
| 239 | }; |
| 240 | |
| 241 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p2vlx1b_1x8vl_sme_mla_interface{ |
| 242 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p2vlx1b_1x8vl_sme_mla, |
| 243 | }; |
| 244 | |
| 245 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p8x1biasf32_6x8x4_neon_mla_interface{ |
| 246 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p8x1biasf32_6x8x4_neon_mla, |
| 247 | }; |
| 248 | |
| 249 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_interface{ |
| 250 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla, |
| 251 | }; |
| 252 | |
| 253 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_cortexa55_interface{ |
| 254 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_cortexa55, |
| 255 | }; |
| 256 | |
| 257 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p16vlx1b_1x16vl_sme2_mla_interface{ |
| 258 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p16vlx1b_1x16vl_sme2_mla, |
| 259 | }; |
| 260 | |
| 261 | inline constexpr MatMulStridedLhsInterface kai_matmul_clamp_f32_f32_f32p4vlx1b_6x4vl_sve_mla_interface{ |
| 262 | .run_matmul = kai_run_matmul_clamp_f32_f32_f32p4vlx1b_6x4vl_sve_mla, |
| 263 | }; |
| 264 | |
| 265 | inline constexpr MatMulUkernelApiInterface kai_matmul_clamp_f32_f32_f32p4vsx1bf32_1x32vs_sme2_mla_interface{ |
| 266 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 267 | .get_api = kai_matmul_clamp_f32_f32_f32p4vsx1bf32_1x32vs_sme2_mla, |
| 268 | }; |
| 269 | |
| 270 | // matmul_clamp_f32_f32p_f32p |
| 271 | inline constexpr MatMulUkernelApiInterface |
| 272 | kai_matmul_clamp_f32_f32p4vsx1_f32p4vsx1b_8vsx8vs_elastic_sme2_mopa_interface{ |
| 273 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 274 | .get_api = kai_matmul_clamp_f32_f32p4vsx1_f32p4vsx1bf32_8vsx8vs_sme2_mopa, |
| 275 | .flags = KAI_MATMUL_UKER_FLAGS_ARGS_CLAMP, |
| 276 | }; |
| 277 | |
| 278 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1biasf32_sme2_mopa_interface{ |
| 279 | .run_matmul = kai_run_matmul_clamp_f32_f32p2vlx1_f32p2vlx1biasf32_sme2_mopa, |
| 280 | }; |
| 281 | |
| 282 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1b_2vlx2vl_sme_mopa_interface{ |
| 283 | .run_matmul = kai_run_matmul_clamp_f32_f32p2vlx1_f32p2vlx1b_2vlx2vl_sme_mopa, |
| 284 | }; |
| 285 | |
| 286 | // matmul_clamp_f32_i8p_i8p |
| 287 | inline constexpr MatMulUkernelApiInterface |
| 288 | kai_matmul_clamp_f32_u8p4vsx4_u8p4vsx4_i32_i32_f32_f32_8vsx8vs_sme2_mopa_interface{ |
| 289 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 290 | .get_api = kai_matmul_clamp_f32_u8p4vsx4_u8p4vsx4_i32_i32_f32_f32_8vsx8vs_sme2_mopa, |
| 291 | .flags = KAI_MATMUL_UKER_FLAGS_ARGS_CLAMP, |
| 292 | .args_flags = KAI_BENCHMARK_MATMUL_UKER_ARGS_ACC_BIAS_M | KAI_BENCHMARK_MATMUL_UKER_ARGS_ACC_BIAS_N | |
| 293 | KAI_BENCHMARK_MATMUL_UKER_ARGS_SCALE_BIAS_N | KAI_BENCHMARK_MATMUL_UKER_ARGS_ACC_SCALE_GLOBAL, |
| 294 | .acc_bias_elem_size = sizeof(int32_t), |
| 295 | .acc_scale_elem_size = sizeof(float), |
| 296 | .scale_bias_elem_size = sizeof(float), |
| 297 | }; |
| 298 | |
| 299 | // matmul_clamp_f32_qai8dxp_qsu2cxp |
| 300 | inline constexpr MatMulBlockwiseDynamicQuantLutInterface |
| 301 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsu2cxp4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 302 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx4_qsu2cxp4vlx4_1vlx4vl_sme2_mopa, |
| 303 | }; |
| 304 | |
| 305 | inline constexpr MatMulBlockwiseDynamicQuantLutInterface |
| 306 | kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4x4bf32sf32_1x4_neon_dotprod_interface{ |
| 307 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4x4bf32sf32_1x4_neon_dotprod, |
| 308 | }; |
| 309 | |
| 310 | inline constexpr MatMulBlockwiseDynamicQuantLutInterface |
| 311 | kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4vlx4_1x4vl_sme2_dot_interface{ |
| 312 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4vlx4_1x4vl_sme2_dot, |
| 313 | }; |
| 314 | |
| 315 | inline constexpr MatMulBlockwiseDynamicQuantLutInterface |
| 316 | kai_matmul_clamp_f32_qai8dxp4x4_qsu2cxp4x4bf32sf32_8x4_neon_dotprod_interface{ |
| 317 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x4_qsu2cxp4x4bf32sf32_8x4_neon_dotprod, |
| 318 | }; |
| 319 | |
| 320 | // matmul_clamp_f32_qai8dxp_qsi4c32p |
| 321 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 322 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4x4_1x4_neon_dotprod_interface{ |
| 323 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4x4_1x4_neon_dotprod, |
| 324 | }; |
| 325 | |
| 326 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 327 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p8x4_1x8_neon_dotprod_interface{ |
| 328 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4c32p8x4_1x8_neon_dotprod, |
| 329 | }; |
| 330 | |
| 331 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 332 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod_interface{ |
| 333 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod, |
| 334 | }; |
| 335 | |
| 336 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 337 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8_neon_dotprod_interface{ |
| 338 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8_neon_dotprod, |
| 339 | }; |
| 340 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 341 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod_interface{ |
| 342 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod, |
| 343 | }; |
| 344 | |
| 345 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 346 | kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p4x4_16x4_neon_dotprod_interface{ |
| 347 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x4_qsi4c32p4x4_16x4_neon_dotprod, |
| 348 | }; |
| 349 | |
| 350 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 351 | kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p8x4_4x8_neon_dotprod_interface{ |
| 352 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x4_qsi4c32p8x4_4x8_neon_dotprod, |
| 353 | }; |
| 354 | |
| 355 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 356 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_8x4x32_neon_i8mm_interface{ |
| 357 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_8x4x32_neon_i8mm, |
| 358 | }; |
| 359 | |
| 360 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 361 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_16x4x32_neon_i8mm_interface{ |
| 362 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_16x4x32_neon_i8mm, |
| 363 | }; |
| 364 | |
| 365 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 366 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8_neon_i8mm_interface{ |
| 367 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8_neon_i8mm, |
| 368 | }; |
| 369 | |
| 370 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 371 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8x32_neon_i8mm_interface{ |
| 372 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8x32_neon_i8mm, |
| 373 | }; |
| 374 | |
| 375 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 376 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4vlx4_1x4vl_sme2_dot_interface{ |
| 377 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4vlx4_1x4vl_sme2_dot, |
| 378 | }; |
| 379 | |
| 380 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 381 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 382 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa, |
| 383 | }; |
| 384 | |
| 385 | // matmul_clamp_f32_qai8dxp_qsi4cxp |
| 386 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa_interface{ |
| 387 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa, |
| 388 | }; |
| 389 | |
| 390 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4cxp4vlx4_1vlx4vl_sme_mopa_interface{ |
| 391 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx4_qsi4cxp4vlx4_1vlx4vl_sme_mopa, |
| 392 | }; |
| 393 | |
| 394 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot_interface{ |
| 395 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot, |
| 396 | }; |
| 397 | |
| 398 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme_dot_interface{ |
| 399 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme_dot, |
| 400 | }; |
| 401 | |
| 402 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod_interface{ |
| 403 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod, |
| 404 | }; |
| 405 | |
| 406 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp4x8_1x4x32_neon_dotprod_interface{ |
| 407 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi4cxp4x8_1x4x32_neon_dotprod, |
| 408 | }; |
| 409 | |
| 410 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp8x8_1x8x32_neon_dotprod_interface{ |
| 411 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi4cxp8x8_1x8x32_neon_dotprod, |
| 412 | }; |
| 413 | |
| 414 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x4_qsi4cxp8x4_8x8x32_neon_dotprod_interface{ |
| 415 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x4_qsi4cxp8x4_8x8x32_neon_dotprod, |
| 416 | }; |
| 417 | |
| 418 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x4_16x4x32_neon_dotprod_interface{ |
| 419 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x4_16x4x32_neon_dotprod, |
| 420 | }; |
| 421 | |
| 422 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_4x4x32_neon_i8mm_interface{ |
| 423 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_4x4x32_neon_i8mm, |
| 424 | }; |
| 425 | |
| 426 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_8x4x32_neon_i8mm_interface{ |
| 427 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_8x4x32_neon_i8mm, |
| 428 | }; |
| 429 | |
| 430 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_4x8x32_neon_i8mm_interface{ |
| 431 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_4x8x32_neon_i8mm, |
| 432 | }; |
| 433 | |
| 434 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_8x8x32_neon_i8mm_interface{ |
| 435 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_8x8x32_neon_i8mm, |
| 436 | }; |
| 437 | |
| 438 | // matmul_clamp_f32_qai8dxp_qsi8cxp |
| 439 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme_mopa_interface{ |
| 440 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme_mopa, |
| 441 | }; |
| 442 | |
| 443 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme_dot_interface{ |
| 444 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme_dot, |
| 445 | }; |
| 446 | |
| 447 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod_interface{ |
| 448 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod, |
| 449 | }; |
| 450 | |
| 451 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod_interface{ |
| 452 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod, |
| 453 | }; |
| 454 | |
| 455 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod_interface{ |
| 456 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod, |
| 457 | }; |
| 458 | |
| 459 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm_interface{ |
| 460 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm, |
| 461 | }; |
| 462 | |
| 463 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 464 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa, |
| 465 | }; |
| 466 | |
| 467 | inline constexpr MatMulFloatInterface kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot_interface{ |
| 468 | .run_matmul = kai_run_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot, |
| 469 | }; |
| 470 | |
| 471 | // matmul_clamp_f32_qsi8d32p_qsi4c32p |
| 472 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 473 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 474 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa, |
| 475 | }; |
| 476 | |
| 477 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 478 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme_mopa_interface{ |
| 479 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme_mopa, |
| 480 | }; |
| 481 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 482 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme2_sdot_interface{ |
| 483 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme2_sdot, |
| 484 | }; |
| 485 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 486 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme_dot_interface{ |
| 487 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme_dot, |
| 488 | }; |
| 489 | |
| 490 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 491 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4x4_1x4_neon_dotprod_interface{ |
| 492 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4x4_1x4_neon_dotprod, |
| 493 | }; |
| 494 | |
| 495 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 496 | kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p4x8_1x4x32_neon_dotprod_interface{ |
| 497 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p4x8_1x4x32_neon_dotprod, |
| 498 | }; |
| 499 | |
| 500 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 501 | kai_matmul_clamp_f32_qsi8d32p4x4_qsi4c32p4x4_16x4_neon_dotprod_interface{ |
| 502 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x4_qsi4c32p4x4_16x4_neon_dotprod, |
| 503 | }; |
| 504 | |
| 505 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 506 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_8x4x32_neon_i8mm_interface{ |
| 507 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_8x4x32_neon_i8mm, |
| 508 | }; |
| 509 | |
| 510 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 511 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_16x4_neon_i8mm_interface{ |
| 512 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_16x4_neon_i8mm, |
| 513 | }; |
| 514 | |
| 515 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 516 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p8x4_1x8_sve_dotprod_interface{ |
| 517 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p8x4_1x8_sve_dotprod, |
| 518 | }; |
| 519 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 520 | kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p8x8_1x8_sve_dotprod_interface{ |
| 521 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p8x8_1x8_sve_dotprod, |
| 522 | }; |
| 523 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 524 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p8x8_16x8_sve_i8mm_interface{ |
| 525 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p8x8_16x8_sve_i8mm, |
| 526 | }; |
| 527 | |
| 528 | // matmul_clamp_fp32_bf16p_bf16p |
| 529 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme2_mopa_interface{ |
| 530 | .run_matmul = kai_run_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme2_mopa, |
| 531 | }; |
| 532 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme_mopa_interface{ |
| 533 | .run_matmul = kai_run_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme_mopa, |
| 534 | }; |
| 535 | |
| 536 | // matmul_clamp_qai8_qai8_qsi8cxp |
| 537 | inline constexpr MatMulStaticQuantInterface kai_matmul_clamp_qai8_qai8_qsi8cxp2vlx4sb_1x16vl_sme2_dot_interface{ |
| 538 | .run_matmul = kai_run_matmul_clamp_qai8_qai8_qsi8cxp2vlx4sb_1x16vl_sme2_dot, |
| 539 | }; |
| 540 | |
| 541 | inline constexpr MatMulUkernelApiInterface kai_matmul_clamp_qai8_qai8_qsi8cxp4vsx4bi32sf32_1x32vs_sme2_dot_interface{ |
| 542 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 543 | .get_api = kai_matmul_clamp_qai8_qai8_qsi8cxp4vsx4bi32sf32_1x32vs_sme2_dot, |
| 544 | .flags = KAI_MATMUL_UKER_FLAGS_ARGS_CLAMP, |
| 545 | .args_flags = KAI_BENCHMARK_MATMUL_UKER_ARGS_SCALE_BIAS_GLOBAL, |
| 546 | .scale_bias_elem_size = sizeof(int32_t), |
| 547 | }; |
| 548 | |
| 549 | // matmul_clamp_qai8_qai8p_qsi8cxp |
| 550 | inline constexpr MatMulStaticQuantInterface kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxpsb2vlx4_2vlx2vl_sme2_mopa_interface{ |
| 551 | .run_matmul = kai_run_matmul_clamp_qai8_qai8p2vlx4_qsi8cxpsb2vlx4_2vlx2vl_sme2_mopa, |
| 552 | }; |
| 553 | |
| 554 | inline constexpr MatMulStaticQuantInterface kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxp2vlx4sb_2vlx2vl_sme_mopa_interface{ |
| 555 | .run_matmul = kai_run_matmul_clamp_qai8_qai8p2vlx4_qsi8cxp2vlx4sb_2vlx2vl_sme_mopa, |
| 556 | }; |
| 557 | |
| 558 | inline constexpr MatMulUkernelApiInterface |
| 559 | kai_matmul_clamp_qai8_qai8p4vsx4_qsi8cxp4vsx4bi32sf32_8vsx8vs_sme2_mopa_interface{ |
| 560 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 561 | .get_api = kai_matmul_clamp_qai8_qai8p4vsx4_qsi8cxp4vsx4bi32sf32_8vsx8vs_sme2_mopa, |
| 562 | .flags = KAI_MATMUL_UKER_FLAGS_ARGS_CLAMP, |
| 563 | .args_flags = KAI_BENCHMARK_MATMUL_UKER_ARGS_SCALE_BIAS_GLOBAL, |
| 564 | .scale_bias_elem_size = sizeof(int32_t), |
| 565 | }; |
| 566 | |
| 567 | // matmul_i32_u8p_u8p |
| 568 | inline constexpr MatMulUkernelApiInterface kai_matmul_i32_u8p4vsx4_u8p4vsx4_i32_i32_8vsx8vs_sme2_mopa_interface{ |
| 569 | .get_config = [] { return kai_matmul_uker_config{}; }, |
| 570 | .get_api = kai_matmul_i32_u8p4vsx4_u8p4vsx4_i32_i32_8vsx8vs_sme2_mopa, |
| 571 | .args_flags = KAI_BENCHMARK_MATMUL_UKER_ARGS_ACC_BIAS_M | KAI_BENCHMARK_MATMUL_UKER_ARGS_ACC_BIAS_N, |
| 572 | .acc_bias_elem_size = sizeof(int32_t), |
| 573 | }; |
| 574 | |
| 575 | // matmul_clamp_bf16_qai8dxp_qsi4c32p |
| 576 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 577 | kai_matmul_clamp_bf16_qai8dxp1x8_qsi4c32p4x8_1x4_neon_dotprod_interface{ |
| 578 | .run_matmul = kai_run_matmul_clamp_bf16_qai8dxp1x8_qsi4c32p4x8_1x4_neon_dotprod, |
| 579 | }; |
| 580 | |
| 581 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 582 | kai_matmul_clamp_bf16_qai8dxp4x8_qsi4c32p4x8_16x4_neon_i8mm_interface{ |
| 583 | .run_matmul = kai_run_matmul_clamp_bf16_qai8dxp4x8_qsi4c32p4x8_16x4_neon_i8mm, |
| 584 | }; |
| 585 | |
| 586 | // matmul_clamp_bf16_qai8dxp_qsi4cxp |
| 587 | inline constexpr MatMulBaseInterface kai_matmul_clamp_bf16_qai8dxp1x8_qsi4cxp8x8_1x8_neon_dotprod_interface{ |
| 588 | .run_matmul = kai_run_matmul_clamp_bf16_qai8dxp1x8_qsi4cxp8x8_1x8_neon_dotprod, |
| 589 | }; |
| 590 | |
| 591 | inline constexpr MatMulBaseInterface kai_matmul_clamp_bf16_qai8dxp4x8_qsi4cxp8x8_8x8_neon_i8mm_interface{ |
| 592 | .run_matmul = kai_run_matmul_clamp_bf16_qai8dxp4x8_qsi4cxp8x8_8x8_neon_i8mm, |
| 593 | }; |
| 594 | |
| 595 | // matmul_clamp_f16_qai8dxp_qsi4cxp |
| 596 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa_interface{ |
| 597 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa, |
| 598 | }; |
| 599 | |
| 600 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot_interface{ |
| 601 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot, |
| 602 | }; |
| 603 | |
| 604 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod_interface{ |
| 605 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod, |
| 606 | }; |
| 607 | |
| 608 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x8_qsi4cxp4x8_1x4_neon_dotprod_interface{ |
| 609 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x8_qsi4cxp4x8_1x4_neon_dotprod, |
| 610 | }; |
| 611 | |
| 612 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp4x4_qsi4cxp4x4_16x4_neon_dotprod_interface{ |
| 613 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp4x4_qsi4cxp4x4_16x4_neon_dotprod, |
| 614 | }; |
| 615 | |
| 616 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp4x8_qsi4cxp4x8_16x4_neon_i8mm_interface{ |
| 617 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp4x8_qsi4cxp4x8_16x4_neon_i8mm, |
| 618 | }; |
| 619 | |
| 620 | // matmul_clamp_f16_qai8dxp_qsi8cxp |
| 621 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 622 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa, |
| 623 | }; |
| 624 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot_interface{ |
| 625 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot, |
| 626 | }; |
| 627 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod_interface{ |
| 628 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod, |
| 629 | }; |
| 630 | |
| 631 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod_interface{ |
| 632 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod, |
| 633 | }; |
| 634 | |
| 635 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod_interface{ |
| 636 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod, |
| 637 | }; |
| 638 | |
| 639 | inline constexpr MatMulBaseInterface kai_matmul_clamp_f16_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm_interface{ |
| 640 | .run_matmul = kai_run_matmul_clamp_f16_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm, |
| 641 | }; |
| 642 | |
| 643 | // matmul_clamp_f16_qsi8d32p_qai4c32p |
| 644 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 645 | kai_matmul_clamp_f16_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 646 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa, |
| 647 | }; |
| 648 | |
| 649 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 650 | kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot_interface{ |
| 651 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot, |
| 652 | }; |
| 653 | |
| 654 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 655 | kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod_interface{ |
| 656 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod, |
| 657 | }; |
| 658 | |
| 659 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 660 | kai_matmul_clamp_f16_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod_interface{ |
| 661 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod, |
| 662 | }; |
| 663 | |
| 664 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 665 | kai_matmul_clamp_f16_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod_interface{ |
| 666 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod, |
| 667 | }; |
| 668 | |
| 669 | inline constexpr MatMulBlockwiseDynamicQuantGenericDstInterface |
| 670 | kai_matmul_clamp_f16_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm_interface{ |
| 671 | .run_matmul = kai_run_matmul_clamp_f16_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm, |
| 672 | }; |
| 673 | |
| 674 | // matmul_clamp_f32_qsi8d32p_qai4c32p |
| 675 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 676 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa_interface{ |
| 677 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa, |
| 678 | }; |
| 679 | |
| 680 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 681 | kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot_interface{ |
| 682 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot, |
| 683 | }; |
| 684 | |
| 685 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 686 | kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod_interface{ |
| 687 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod, |
| 688 | }; |
| 689 | |
| 690 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 691 | kai_matmul_clamp_f32_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod_interface{ |
| 692 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod, |
| 693 | }; |
| 694 | |
| 695 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 696 | kai_matmul_clamp_f32_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod_interface{ |
| 697 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod, |
| 698 | }; |
| 699 | |
| 700 | inline constexpr MatMulBlockwiseDynamicQuantInterface |
| 701 | kai_matmul_clamp_f32_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm_interface{ |
| 702 | .run_matmul = kai_run_matmul_clamp_f32_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm, |
| 703 | }; |
| 704 | |
| 705 | inline const std::array matmul_benchmarks{ |
| 706 | // matmul_clamp_f16_bf16p_bf16p |
| 707 | RegisterBenchmark( |
| 708 | "kai_matmul_clamp_f16_bf16p8x4_bf16p12x4b_8x12_neon_mmla", kai_benchmark_matmul<MatMulBaseInterface>, |
| 709 | kai_matmul_clamp_f16_bf16p8x4_bf16p12x4b_8x12_neon_mmla_interface, DataType::FP16, MatMulOp::GEMM, |
| 710 | test::cpu_has_bf16), |
| 711 | |
| 712 | // matmul_clamp_f16_f16_f16p |
| 713 | RegisterBenchmark( |
| 714 | "kai_matmul_clamp_f16_f16_f16p2vlx2b_1x8vl_sme_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 715 | kai_matmul_clamp_f16_f16_f16p2vlx2b_1x8vl_sme_mla_interface, DataType::FP16, MatMulOp::GEMV, test::cpu_has_sme), |
| 716 | RegisterBenchmark( |
| 717 | "kai_matmul_clamp_f16_f16_f16p2vlx2b_1x16vl_sme2_dot", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 718 | kai_matmul_clamp_f16_f16_f16p2vlx2b_1x16vl_sme2_dot_interface, DataType::FP16, MatMulOp::GEMV, |
| 719 | test::cpu_has_sme2), |
| 720 | RegisterBenchmark( |
| 721 | "kai_matmul_clamp_f16_f16_f16p16x1biasf16_6x16x8_neon_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 722 | kai_matmul_clamp_f16_f16_f16p16x1biasf16_6x16x8_neon_mla_interface, DataType::FP16, MatMulOp::GEMM, |
| 723 | test::cpu_has_fp16), |
| 724 | RegisterBenchmark( |
| 725 | "kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 726 | kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_interface, DataType::FP16, MatMulOp::GEMM, test::cpu_has_fp16), |
| 727 | RegisterBenchmark( |
| 728 | "kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_cortexa55", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 729 | kai_matmul_clamp_f16_f16_f16p32x1b_6x32_neon_mla_cortexa55_interface, DataType::FP16, MatMulOp::GEMM, |
| 730 | test::cpu_has_fp16), |
| 731 | RegisterBenchmark( |
| 732 | "kai_matmul_clamp_f16_f16_f16p16vsx2bf16_6x16vs_sve2p1_dot", kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 733 | kai_matmul_clamp_f16_f16_f16p16vsx2bf16_6x16vs_sve2p1_dot_interface, DataType::FP16, MatMulOp::GEMM, |
| 734 | test::cpu_check<test::cpu_has_sve2p1, test::cpu_has_fp16>), |
| 735 | |
| 736 | // matmul_clamp_f16_f16p_f16p |
| 737 | RegisterBenchmark( |
| 738 | "kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2_2vlx2vl_sme2_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 739 | kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2_2vlx2vl_sme2_mopa_interface, DataType::FP16, MatMulOp::GEMM, |
| 740 | test::cpu_has_sme2), |
| 741 | RegisterBenchmark( |
| 742 | "kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2b_2vlx2vl_sme_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 743 | kai_matmul_clamp_f16_f16p2vlx2_f16p2vlx2b_2vlx2vl_sme_mopa_interface, DataType::FP16, MatMulOp::GEMM, |
| 744 | test::cpu_has_sme), |
| 745 | |
| 746 | // matmul_clamp_f32_bf16p_bf16p |
| 747 | RegisterBenchmark( |
| 748 | "kai_matmul_clamp_f32_bf16p1x4_bf16p12x4b_1x36_neon_dot", kai_benchmark_matmul<MatMulBaseInterface>, |
| 749 | kai_matmul_clamp_f32_bf16p1x4_bf16p12x4b_1x36_neon_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 750 | test::cpu_has_dotprod), |
| 751 | RegisterBenchmark( |
| 752 | "kai_matmul_clamp_f32_bf16p8x4_bf16p12x4b_8x12_neon_mmla", kai_benchmark_matmul<MatMulBaseInterface>, |
| 753 | kai_matmul_clamp_f32_bf16p8x4_bf16p12x4b_8x12_neon_mmla_interface, DataType::FP32, MatMulOp::GEMM, |
| 754 | test::cpu_has_i8mm), |
| 755 | |
| 756 | // matmul_clamp_f32_f16p_qsi4c32p |
| 757 | RegisterBenchmark( |
| 758 | "kai_matmul_clamp_f32_f16p1vlx2_qsi4c32p4vlx2_1vlx4vl_sme2_mopa", |
| 759 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 760 | kai_matmul_clamp_f32_f16p1vlx2_qsi4c32p4vlx2_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 761 | test::cpu_has_sme2), |
| 762 | |
| 763 | // matmul_clamp_f32_f32_f32p |
| 764 | RegisterBenchmark( |
| 765 | "kai_matmul_clamp_f32_f32_f32p2vlx1b_1x16vl_sme2_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 766 | kai_matmul_clamp_f32_f32_f32p2vlx1b_1x16vl_sme2_mla_interface, DataType::FP32, MatMulOp::GEMV, |
| 767 | test::cpu_has_sme2), |
| 768 | RegisterBenchmark( |
| 769 | "kai_matmul_clamp_f32_f32_f32p2vlx1b_1x8vl_sme_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 770 | kai_matmul_clamp_f32_f32_f32p2vlx1b_1x8vl_sme_mla_interface, DataType::FP32, MatMulOp::GEMV, test::cpu_has_sme), |
| 771 | RegisterBenchmark( |
| 772 | "kai_matmul_clamp_f32_f32_f32p8x1biasf32_6x8x4_neon_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 773 | kai_matmul_clamp_f32_f32_f32p8x1biasf32_6x8x4_neon_mla_interface, DataType::FP32, MatMulOp::GEMM, |
| 774 | test::cpu_has_advsimd), |
| 775 | RegisterBenchmark( |
| 776 | "kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 777 | kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_interface, DataType::FP32, MatMulOp::GEMM, |
| 778 | test::cpu_has_advsimd), |
| 779 | RegisterBenchmark( |
| 780 | "kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_cortexa55", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 781 | kai_matmul_clamp_f32_f32_f32p16x1b_6x16_neon_mla_cortexa55_interface, DataType::FP32, MatMulOp::GEMM, |
| 782 | test::cpu_has_advsimd), |
| 783 | RegisterBenchmark( |
| 784 | "kai_matmul_clamp_f32_f32_f32p16vlx1b_1x16vl_sme2_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 785 | kai_matmul_clamp_f32_f32_f32p16vlx1b_1x16vl_sme2_mla_interface, DataType::FP32, MatMulOp::GEMV, |
| 786 | test::cpu_has_sme2), |
| 787 | RegisterBenchmark( |
| 788 | "kai_matmul_clamp_f32_f32_f32p4vlx1b_6x4vl_sve_mla", kai_benchmark_matmul<MatMulStridedLhsInterface>, |
| 789 | kai_matmul_clamp_f32_f32_f32p4vlx1b_6x4vl_sve_mla_interface, DataType::FP32, MatMulOp::GEMM, test::cpu_has_sve), |
| 790 | RegisterBenchmark( |
| 791 | "kai_matmul_clamp_f32_f32_f32p4vsx1bf32_1x32vs_sme2_mla", kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 792 | kai_matmul_clamp_f32_f32_f32p4vsx1bf32_1x32vs_sme2_mla_interface, DataType::FP32, MatMulOp::GEMV, |
| 793 | test::cpu_has_sme2), |
| 794 | |
| 795 | // matmul_clamp_f32_f32p_f32p |
| 796 | RegisterBenchmark( |
| 797 | "kai_matmul_clamp_f32_f32p4vsx1_f32p4vsx1b_8vsx8vs_elastic_sme2_mopa", |
| 798 | kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 799 | kai_matmul_clamp_f32_f32p4vsx1_f32p4vsx1b_8vsx8vs_elastic_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 800 | test::cpu_has_sme2), |
| 801 | RegisterBenchmark( |
| 802 | "kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1biasf32_sme2_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 803 | kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1biasf32_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 804 | test::cpu_has_sme2), |
| 805 | RegisterBenchmark( |
| 806 | "kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1b_2vlx2vl_sme_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 807 | kai_matmul_clamp_f32_f32p2vlx1_f32p2vlx1b_2vlx2vl_sme_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 808 | test::cpu_has_sme), |
| 809 | |
| 810 | // matmul_clamp_f32_i8p_i8p |
| 811 | RegisterBenchmark( |
| 812 | "kai_matmul_clamp_f32_u8p4vsx4_u8p4vsx4_i32_i32_f32_f32_8vsx8vs_sme2_mopa", |
| 813 | kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 814 | kai_matmul_clamp_f32_u8p4vsx4_u8p4vsx4_i32_i32_f32_f32_8vsx8vs_sme2_mopa_interface, DataType::FP32, |
| 815 | MatMulOp::GEMM, test::cpu_has_sme2), |
| 816 | |
| 817 | // matmul_clamp_f32_qai8dxp_qsu2cxp |
| 818 | RegisterBenchmark( |
| 819 | "kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4x4bf32sf32_1x4_neon_dotprod", |
| 820 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantLutInterface>, |
| 821 | kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4x4bf32sf32_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 822 | test::cpu_has_dotprod), |
| 823 | RegisterBenchmark( |
| 824 | "kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4vlx4_1x4vl_sme2_dot", |
| 825 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantLutInterface>, |
| 826 | kai_matmul_clamp_f32_qai8dxp1x4_qsu2cxp4vlx4_1x4vl_sme2_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 827 | test::cpu_has_sme2), |
| 828 | RegisterBenchmark( |
| 829 | "kai_matmul_clamp_f32_qai8dxp4x4_qsu2cxp4x4bf32sf32_8x4_neon_dotprod", |
| 830 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantLutInterface>, |
| 831 | kai_matmul_clamp_f32_qai8dxp4x4_qsu2cxp4x4bf32sf32_8x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 832 | test::cpu_has_dotprod), |
| 833 | RegisterBenchmark( |
| 834 | "kai_matmul_clamp_f32_qai8dxp1vlx4_qsu2cxp4vlx4_1vlx4vl_sme2_mopa", |
| 835 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantLutInterface>, |
| 836 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsu2cxp4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 837 | test::cpu_has_sme2), |
| 838 | |
| 839 | // matmul_clamp_f32_qai8dxp_qsi4c32p |
| 840 | RegisterBenchmark( |
| 841 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4x4_1x4_neon_dotprod", |
| 842 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 843 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4x4_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 844 | test::cpu_has_dotprod), |
| 845 | RegisterBenchmark( |
| 846 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p8x4_1x8_neon_dotprod", |
| 847 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 848 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p8x4_1x8_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 849 | test::cpu_has_dotprod), |
| 850 | RegisterBenchmark( |
| 851 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod", |
| 852 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 853 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p4x8_1x4x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 854 | test::cpu_has_dotprod), |
| 855 | RegisterBenchmark( |
| 856 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod", |
| 857 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 858 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 859 | test::cpu_has_dotprod), |
| 860 | RegisterBenchmark( |
| 861 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8_neon_dotprod", |
| 862 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 863 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4c32p8x8_1x8_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 864 | test::cpu_has_dotprod), |
| 865 | RegisterBenchmark( |
| 866 | "kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p4x4_16x4_neon_dotprod", |
| 867 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 868 | kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p4x4_16x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 869 | test::cpu_has_dotprod), |
| 870 | RegisterBenchmark( |
| 871 | "kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p8x4_4x8_neon_dotprod", |
| 872 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 873 | kai_matmul_clamp_f32_qai8dxp4x4_qsi4c32p8x4_4x8_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 874 | test::cpu_has_dotprod), |
| 875 | RegisterBenchmark( |
| 876 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_8x4x32_neon_i8mm", |
| 877 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 878 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_8x4x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 879 | test::cpu_has_i8mm), |
| 880 | RegisterBenchmark( |
| 881 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_16x4x32_neon_i8mm", |
| 882 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 883 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p4x8_16x4x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 884 | test::cpu_has_i8mm), |
| 885 | RegisterBenchmark( |
| 886 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8_neon_i8mm", |
| 887 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 888 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 889 | test::cpu_has_i8mm), |
| 890 | RegisterBenchmark( |
| 891 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8x32_neon_i8mm", |
| 892 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 893 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4c32p8x8_4x8x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 894 | test::cpu_has_i8mm), |
| 895 | RegisterBenchmark( |
| 896 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4vlx4_1x4vl_sme2_dot", |
| 897 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 898 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4c32p4vlx4_1x4vl_sme2_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 899 | test::cpu_has_sme2), |
| 900 | RegisterBenchmark( |
| 901 | "kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa", |
| 902 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 903 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 904 | test::cpu_has_sme2), |
| 905 | |
| 906 | // matmul_clamp_f32_qai8dxp_qsi4cxp |
| 907 | RegisterBenchmark( |
| 908 | "kai_matmul_clamp_f32_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa", kai_benchmark_matmul<MatMulFloatInterface>, |
| 909 | kai_matmul_clamp_f32_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 910 | test::cpu_has_sme2), |
| 911 | RegisterBenchmark( |
| 912 | "kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4cxp4vlx4_1vlx4vl_sme_mopa", kai_benchmark_matmul<MatMulFloatInterface>, |
| 913 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsi4cxp4vlx4_1vlx4vl_sme_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 914 | test::cpu_has_sme), |
| 915 | RegisterBenchmark( |
| 916 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot", kai_benchmark_matmul<MatMulFloatInterface>, |
| 917 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot_interface, DataType::FP32, MatMulOp::GEMV, |
| 918 | test::cpu_has_sme2), |
| 919 | RegisterBenchmark( |
| 920 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme_dot", kai_benchmark_matmul<MatMulFloatInterface>, |
| 921 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 922 | test::cpu_has_sme), |
| 923 | RegisterBenchmark( |
| 924 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 925 | kai_matmul_clamp_f32_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 926 | test::cpu_has_dotprod), |
| 927 | RegisterBenchmark( |
| 928 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp4x8_1x4x32_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 929 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp4x8_1x4x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 930 | test::cpu_has_dotprod), |
| 931 | RegisterBenchmark( |
| 932 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp8x8_1x8x32_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 933 | kai_matmul_clamp_f32_qai8dxp1x8_qsi4cxp8x8_1x8x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 934 | test::cpu_has_dotprod), |
| 935 | RegisterBenchmark( |
| 936 | "kai_matmul_clamp_f32_qai8dxp4x4_qsi4cxp8x4_8x8x32_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 937 | kai_matmul_clamp_f32_qai8dxp4x4_qsi4cxp8x4_8x8x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 938 | test::cpu_has_dotprod), |
| 939 | RegisterBenchmark( |
| 940 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x4_16x4x32_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 941 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x4_16x4x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 942 | test::cpu_has_dotprod), |
| 943 | RegisterBenchmark( |
| 944 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_4x4x32_neon_i8mm", kai_benchmark_matmul<MatMulFloatInterface>, |
| 945 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_4x4x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 946 | test::cpu_has_i8mm), |
| 947 | RegisterBenchmark( |
| 948 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_8x4x32_neon_i8mm", kai_benchmark_matmul<MatMulFloatInterface>, |
| 949 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp4x8_8x4x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 950 | test::cpu_has_i8mm), |
| 951 | RegisterBenchmark( |
| 952 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_4x8x32_neon_i8mm", kai_benchmark_matmul<MatMulFloatInterface>, |
| 953 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_4x8x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 954 | test::cpu_has_i8mm), |
| 955 | RegisterBenchmark( |
| 956 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_8x8x32_neon_i8mm", kai_benchmark_matmul<MatMulFloatInterface>, |
| 957 | kai_matmul_clamp_f32_qai8dxp4x8_qsi4cxp8x8_8x8x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 958 | test::cpu_has_i8mm), |
| 959 | |
| 960 | // matmul_clamp_f32_qai8dxp_qsi8cxp |
| 961 | RegisterBenchmark( |
| 962 | "kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme_mopa", kai_benchmark_matmul<MatMulFloatInterface>, |
| 963 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 964 | test::cpu_has_sme), |
| 965 | RegisterBenchmark( |
| 966 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme_dot", kai_benchmark_matmul<MatMulFloatInterface>, |
| 967 | kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 968 | test::cpu_has_sme), |
| 969 | RegisterBenchmark( |
| 970 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 971 | kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 972 | test::cpu_has_dotprod), |
| 973 | RegisterBenchmark( |
| 974 | "kai_matmul_clamp_f32_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 975 | kai_matmul_clamp_f32_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 976 | test::cpu_has_dotprod), |
| 977 | RegisterBenchmark( |
| 978 | "kai_matmul_clamp_f32_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod", kai_benchmark_matmul<MatMulFloatInterface>, |
| 979 | kai_matmul_clamp_f32_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 980 | test::cpu_has_dotprod), |
| 981 | RegisterBenchmark( |
| 982 | "kai_matmul_clamp_f32_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm", kai_benchmark_matmul<MatMulFloatInterface>, |
| 983 | kai_matmul_clamp_f32_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 984 | test::cpu_has_i8mm), |
| 985 | RegisterBenchmark( |
| 986 | "kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa", kai_benchmark_matmul<MatMulFloatInterface>, |
| 987 | kai_matmul_clamp_f32_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 988 | test::cpu_has_sme2), |
| 989 | RegisterBenchmark( |
| 990 | "kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot", kai_benchmark_matmul<MatMulFloatInterface>, |
| 991 | kai_matmul_clamp_f32_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 992 | test::cpu_has_sme2), |
| 993 | |
| 994 | // matmul_clamp_f32_qsi8d32p_qsi4c32p |
| 995 | RegisterBenchmark( |
| 996 | "kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa", |
| 997 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 998 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 999 | test::cpu_has_sme2), |
| 1000 | RegisterBenchmark( |
| 1001 | "kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme_mopa", |
| 1002 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1003 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qsi4c32p4vlx4_1vlx4vl_sme_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 1004 | test::cpu_has_sme), |
| 1005 | RegisterBenchmark( |
| 1006 | "kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme2_sdot", |
| 1007 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1008 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme2_sdot_interface, DataType::FP32, MatMulOp::GEMV, |
| 1009 | test::cpu_has_sme2), |
| 1010 | RegisterBenchmark( |
| 1011 | "kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme_dot", |
| 1012 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1013 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4vlx4_1x4vl_sme_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 1014 | test::cpu_has_sme), |
| 1015 | RegisterBenchmark( |
| 1016 | "kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4x4_1x4_neon_dotprod", |
| 1017 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1018 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p4x4_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1019 | test::cpu_has_dotprod), |
| 1020 | RegisterBenchmark( |
| 1021 | "kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p4x8_1x4x32_neon_dotprod", |
| 1022 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1023 | kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p4x8_1x4x32_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1024 | test::cpu_has_dotprod), |
| 1025 | RegisterBenchmark( |
| 1026 | "kai_matmul_clamp_f32_qsi8d32p4x4_qsi4c32p4x4_16x4_neon_dotprod", |
| 1027 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1028 | kai_matmul_clamp_f32_qsi8d32p4x4_qsi4c32p4x4_16x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 1029 | test::cpu_has_dotprod), |
| 1030 | RegisterBenchmark( |
| 1031 | "kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_8x4x32_neon_i8mm", |
| 1032 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1033 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_8x4x32_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 1034 | test::cpu_has_i8mm), |
| 1035 | RegisterBenchmark( |
| 1036 | "kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_16x4_neon_i8mm", |
| 1037 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1038 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p4x8_16x4_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 1039 | test::cpu_has_i8mm), |
| 1040 | RegisterBenchmark( |
| 1041 | "kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p8x4_1x8_sve_dotprod", |
| 1042 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1043 | kai_matmul_clamp_f32_qsi8d32p1x4_qsi4c32p8x4_1x8_sve_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1044 | (test::cpu_check<test::cpu_has_sve_vl256, test::cpu_has_dotprod>)), |
| 1045 | RegisterBenchmark( |
| 1046 | "kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p8x8_1x8_sve_dotprod", |
| 1047 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1048 | kai_matmul_clamp_f32_qsi8d32p1x8_qsi4c32p8x8_1x8_sve_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1049 | (test::cpu_check<test::cpu_has_sve_vl256, test::cpu_has_dotprod>)), |
| 1050 | RegisterBenchmark( |
| 1051 | "kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p8x8_16x8_sve_i8mm", |
| 1052 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1053 | kai_matmul_clamp_f32_qsi8d32p4x8_qsi4c32p8x8_16x8_sve_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 1054 | (test::cpu_check<test::cpu_has_sve_vl256, test::cpu_has_i8mm>)), |
| 1055 | |
| 1056 | // matmul_clamp_fp32_bf16p_bf16p |
| 1057 | RegisterBenchmark( |
| 1058 | "kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme2_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1059 | kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 1060 | test::cpu_has_sme2), |
| 1061 | RegisterBenchmark( |
| 1062 | "kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1063 | kai_matmul_clamp_f32_bf16p2vlx2_bf16p2vlx2_2vlx2vl_sme_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 1064 | test::cpu_has_sme), |
| 1065 | |
| 1066 | // matmul_clamp_qai8_qai8_qsi8cxp |
| 1067 | RegisterBenchmark( |
| 1068 | "kai_matmul_clamp_qai8_qai8_qsi8cxp2vlx4sb_1x16vl_sme2_dot", kai_benchmark_matmul<MatMulStaticQuantInterface>, |
| 1069 | kai_matmul_clamp_qai8_qai8_qsi8cxp2vlx4sb_1x16vl_sme2_dot_interface, DataType::QAI8, MatMulOp::GEMV, |
| 1070 | test::cpu_has_sme2), |
| 1071 | RegisterBenchmark( |
| 1072 | "kai_matmul_clamp_qai8_qai8_qsi8cxp4vsx4bi32sf32_1x32vs_sme2_dot", |
| 1073 | kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 1074 | kai_matmul_clamp_qai8_qai8_qsi8cxp4vsx4bi32sf32_1x32vs_sme2_dot_interface, DataType::QAI8, MatMulOp::GEMV, |
| 1075 | test::cpu_has_sme2), |
| 1076 | |
| 1077 | // matmul_clamp_qai8_qai8p_qsi8cxp |
| 1078 | RegisterBenchmark( |
| 1079 | "kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxpsb2vlx4_2vlx2vl_sme2_mopa", |
| 1080 | kai_benchmark_matmul<MatMulStaticQuantInterface>, |
| 1081 | kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxpsb2vlx4_2vlx2vl_sme2_mopa_interface, DataType::QAI8, MatMulOp::GEMM, |
| 1082 | test::cpu_has_sme2), |
| 1083 | RegisterBenchmark( |
| 1084 | "kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxp2vlx4sb_2vlx2vl_sme_mopa", |
| 1085 | kai_benchmark_matmul<MatMulStaticQuantInterface>, |
| 1086 | kai_matmul_clamp_qai8_qai8p2vlx4_qsi8cxp2vlx4sb_2vlx2vl_sme_mopa_interface, DataType::QAI8, MatMulOp::GEMM, |
| 1087 | test::cpu_has_sme), |
| 1088 | RegisterBenchmark( |
| 1089 | "kai_matmul_clamp_qai8_qai8p4vsx4_qsi8cxp4vsx4bi32sf32_8vsx8vs_sme2_mopa", |
| 1090 | kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 1091 | kai_matmul_clamp_qai8_qai8p4vsx4_qsi8cxp4vsx4bi32sf32_8vsx8vs_sme2_mopa_interface, DataType::QAI8, |
| 1092 | MatMulOp::GEMM, test::cpu_has_sme2), |
| 1093 | |
| 1094 | // matmul_i32_u8p_u8p |
| 1095 | RegisterBenchmark( |
| 1096 | "kai_matmul_i32_u8p4vsx4_u8p4vsx4_i32_i32_8vsx8vs_sme2_mopa", kai_benchmark_matmul<MatMulUkernelApiInterface>, |
| 1097 | kai_matmul_i32_u8p4vsx4_u8p4vsx4_i32_i32_8vsx8vs_sme2_mopa_interface, DataType::I32, MatMulOp::GEMM, |
| 1098 | test::cpu_has_sme2), |
| 1099 | |
| 1100 | // matmul_clamp_bf16_qai8dxp_qsi4c32p |
| 1101 | RegisterBenchmark( |
| 1102 | "kai_matmul_clamp_bf16_qai8dxp1x8_qsi4c32p4x8_1x4_neon_dotprod", |
| 1103 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1104 | kai_matmul_clamp_bf16_qai8dxp1x8_qsi4c32p4x8_1x4_neon_dotprod_interface, DataType::BF16, MatMulOp::GEMV, |
| 1105 | test::cpu_has_dotprod_and_bf16), |
| 1106 | RegisterBenchmark( |
| 1107 | "kai_matmul_clamp_bf16_qai8dxp4x8_qsi4c32p4x8_16x4_neon_i8mm", |
| 1108 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1109 | kai_matmul_clamp_bf16_qai8dxp4x8_qsi4c32p4x8_16x4_neon_i8mm_interface, DataType::BF16, MatMulOp::GEMM, |
| 1110 | test::cpu_has_i8mm_and_bf16), |
| 1111 | |
| 1112 | // matmul_clamp_bf16_qai8dxp_qsi4cxp |
| 1113 | RegisterBenchmark( |
| 1114 | "kai_matmul_clamp_bf16_qai8dxp1x8_qsi4cxp8x8_1x8_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1115 | kai_matmul_clamp_bf16_qai8dxp1x8_qsi4cxp8x8_1x8_neon_dotprod_interface, DataType::BF16, MatMulOp::GEMV, |
| 1116 | test::cpu_has_dotprod_and_bf16), |
| 1117 | RegisterBenchmark( |
| 1118 | "kai_matmul_clamp_bf16_qai8dxp4x8_qsi4cxp8x8_8x8_neon_i8mm", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1119 | kai_matmul_clamp_bf16_qai8dxp4x8_qsi4cxp8x8_8x8_neon_i8mm_interface, DataType::BF16, MatMulOp::GEMM, |
| 1120 | test::cpu_has_i8mm_and_bf16), |
| 1121 | |
| 1122 | // matmul_clamp_f16_qai8dxp_qsi4cxp |
| 1123 | RegisterBenchmark( |
| 1124 | "kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1125 | kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4vlx4_1x4vl_sme2_sdot_interface, DataType::FP16, MatMulOp::GEMV, |
| 1126 | test::cpu_has_sme2), |
| 1127 | RegisterBenchmark( |
| 1128 | "kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1129 | kai_matmul_clamp_f16_qai8dxp1x4_qsi4cxp4x4_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1130 | test::cpu_has_dotprod_and_fp16), |
| 1131 | RegisterBenchmark( |
| 1132 | "kai_matmul_clamp_f16_qai8dxp1x8_qsi4cxp4x8_1x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1133 | kai_matmul_clamp_f16_qai8dxp1x8_qsi4cxp4x8_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1134 | test::cpu_has_dotprod_and_fp16), |
| 1135 | RegisterBenchmark( |
| 1136 | "kai_matmul_clamp_f16_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1137 | kai_matmul_clamp_f16_qai8dxp1vlx8_qsi4cxp4vlx8_1vlx4vl_sme2_mopa_interface, DataType::FP16, MatMulOp::GEMM, |
| 1138 | test::cpu_has_sme2), |
| 1139 | RegisterBenchmark( |
| 1140 | "kai_matmul_clamp_f16_qai8dxp4x4_qsi4cxp4x4_16x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1141 | kai_matmul_clamp_f16_qai8dxp4x4_qsi4cxp4x4_16x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMM, |
| 1142 | test::cpu_has_dotprod_and_fp16), |
| 1143 | RegisterBenchmark( |
| 1144 | "kai_matmul_clamp_f16_qai8dxp4x8_qsi4cxp4x8_16x4_neon_i8mm", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1145 | kai_matmul_clamp_f16_qai8dxp4x8_qsi4cxp4x8_16x4_neon_i8mm_interface, DataType::FP16, MatMulOp::GEMM, |
| 1146 | test::cpu_has_i8mm_and_fp16), |
| 1147 | |
| 1148 | // matmul_clamp_f16_qai8dxp_qsi8cxp |
| 1149 | RegisterBenchmark( |
| 1150 | "kai_matmul_clamp_f16_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1151 | kai_matmul_clamp_f16_qai8dxp1vlx4_qsi8cxp4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP16, MatMulOp::GEMM, |
| 1152 | test::cpu_has_sme2), |
| 1153 | RegisterBenchmark( |
| 1154 | "kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1155 | kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4vlx4_1x4vl_sme2_dot_interface, DataType::FP16, MatMulOp::GEMV, |
| 1156 | test::cpu_has_sme2), |
| 1157 | RegisterBenchmark( |
| 1158 | "kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1159 | kai_matmul_clamp_f16_qai8dxp1x4_qsi8cxp4x4_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1160 | test::cpu_has_dotprod_and_fp16), |
| 1161 | RegisterBenchmark( |
| 1162 | "kai_matmul_clamp_f16_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1163 | kai_matmul_clamp_f16_qai8dxp1x8_qsi8cxp4x8_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1164 | test::cpu_has_dotprod_and_fp16), |
| 1165 | RegisterBenchmark( |
| 1166 | "kai_matmul_clamp_f16_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1167 | kai_matmul_clamp_f16_qai8dxp4x4_qsi8cxp4x4_16x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMM, |
| 1168 | test::cpu_has_dotprod_and_fp16), |
| 1169 | RegisterBenchmark( |
| 1170 | "kai_matmul_clamp_f16_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm", kai_benchmark_matmul<MatMulBaseInterface>, |
| 1171 | kai_matmul_clamp_f16_qai8dxp4x8_qsi8cxp4x8_16x4_neon_i8mm_interface, DataType::FP16, MatMulOp::GEMM, |
| 1172 | test::cpu_has_i8mm_and_fp16), |
| 1173 | |
| 1174 | // matmul_clamp_f16_qsi8d32p_qai4c32p |
| 1175 | RegisterBenchmark( |
| 1176 | "kai_matmul_clamp_f16_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa", |
| 1177 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1178 | kai_matmul_clamp_f16_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP16, MatMulOp::GEMM, |
| 1179 | test::cpu_has_sme2), |
| 1180 | RegisterBenchmark( |
| 1181 | "kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot", |
| 1182 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1183 | kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot_interface, DataType::FP16, MatMulOp::GEMV, |
| 1184 | test::cpu_has_sme2), |
| 1185 | RegisterBenchmark( |
| 1186 | "kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod", |
| 1187 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1188 | kai_matmul_clamp_f16_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1189 | test::cpu_has_dotprod_and_fp16), |
| 1190 | RegisterBenchmark( |
| 1191 | "kai_matmul_clamp_f16_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod", |
| 1192 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1193 | kai_matmul_clamp_f16_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMV, |
| 1194 | test::cpu_has_dotprod_and_fp16), |
| 1195 | RegisterBenchmark( |
| 1196 | "kai_matmul_clamp_f16_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod", |
| 1197 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1198 | kai_matmul_clamp_f16_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod_interface, DataType::FP16, MatMulOp::GEMM, |
| 1199 | test::cpu_has_dotprod_and_fp16), |
| 1200 | RegisterBenchmark( |
| 1201 | "kai_matmul_clamp_f16_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm", |
| 1202 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantGenericDstInterface>, |
| 1203 | kai_matmul_clamp_f16_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm_interface, DataType::FP16, MatMulOp::GEMM, |
| 1204 | test::cpu_has_i8mm_and_fp16), |
| 1205 | |
| 1206 | // matmul_clamp_f32_qsi8d32p_qai4c32p |
| 1207 | RegisterBenchmark( |
| 1208 | "kai_matmul_clamp_f32_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa", |
| 1209 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1210 | kai_matmul_clamp_f32_qsi8d32p1vlx4_qai4c32p4vlx4_1vlx4vl_sme2_mopa_interface, DataType::FP32, MatMulOp::GEMM, |
| 1211 | test::cpu_has_sme2), |
| 1212 | RegisterBenchmark( |
| 1213 | "kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot", |
| 1214 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1215 | kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4vlx4_1x4vl_sme2_dot_interface, DataType::FP32, MatMulOp::GEMV, |
| 1216 | test::cpu_has_sme2), |
| 1217 | RegisterBenchmark( |
| 1218 | "kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod", |
| 1219 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1220 | kai_matmul_clamp_f32_qsi8d32p1x4_qai4c32p4x4_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1221 | test::cpu_has_dotprod), |
| 1222 | RegisterBenchmark( |
| 1223 | "kai_matmul_clamp_f32_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod", |
| 1224 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1225 | kai_matmul_clamp_f32_qsi8d32p1x8_qai4c32p4x8_1x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMV, |
| 1226 | test::cpu_has_dotprod), |
| 1227 | RegisterBenchmark( |
| 1228 | "kai_matmul_clamp_f32_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod", |
| 1229 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1230 | kai_matmul_clamp_f32_qsi8d32p4x4_qai4c32p4x4_8x4_neon_dotprod_interface, DataType::FP32, MatMulOp::GEMM, |
| 1231 | test::cpu_has_dotprod), |
| 1232 | RegisterBenchmark( |
| 1233 | "kai_matmul_clamp_f32_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm", |
| 1234 | kai_benchmark_matmul<MatMulBlockwiseDynamicQuantInterface>, |
| 1235 | kai_matmul_clamp_f32_qsi8d32p4x8_qai4c32p4x8_8x4_neon_i8mm_interface, DataType::FP32, MatMulOp::GEMM, |
| 1236 | test::cpu_has_i8mm), |
| 1237 | |
| 1238 | }; |
| 1239 | |
| 1240 | void RegisterMatMulBenchmarks(const MatMulShape& shape, const size_t bl) { |
| 1241 | for (const auto& benchmark : matmul_benchmarks) { |
| 1242 | benchmark |
| 1243 | ->Args( |
| 1244 | {static_cast<int64_t>(shape.m), static_cast<int64_t>(shape.n), static_cast<int64_t>(shape.k), |
| 1245 | static_cast<int64_t>(bl)}) |
| 1246 | ->ArgNames({"m", "n", "k", "bl"}); |
| 1247 | } |
| 1248 | } |
| 1249 | } // namespace kai::benchmark |