char-fork/llama.cpp
git clone https://git.t4t.associates/char-fork/llama.cpp
af237f302
char/aliceai-t5-moe
1#pragma once 2 3#define GGML_COMMON_DECL_CPP 4#include "ggml-common.h" 5 6#include "traits.h" 7#include "ggml.h" 8 9// GGML internal header 10 11ggml_backend_buffer_type_t ggml_backend_cpu_repack_buffer_type (void ); 12 13template < int K > constexpr int QK_0 () { 14if constexpr (K == 4 ) { 15return QK4_0 ; 16 } 17if constexpr (K == 8 ) { 18return QK8_0 ; 19 } 20return -1 ; 21} 22 23template < int K ,int N > struct block { 24ggml_half d [N ];// deltas for N qK_0 blocks 25int8_t qs [(QK_0 < K > () * N * K ) / 8 ]; // quants for N qK_0 blocks 26}; 27 28// control size 29static_assert ( sizeof (block < 4 , 4 > ) == 4 * sizeof (ggml_half) + QK8_0 * 2 , "wrong block<4,4> size/padding" ); 30static_assert ( sizeof (block < 4 , 8 > ) == 8 * sizeof (ggml_half) + QK8_0 * 4 , "wrong block<4,8> size/padding" ); 31static_assert ( sizeof (block < 4 , 16 > ) == 16 * sizeof (ggml_half) + QK8_0 * 8 , "wrong block<4,16> size/padding" ); 32static_assert ( sizeof (block < 8 , 4 > ) == 4 * sizeof (ggml_half) + QK8_0 * 4 , "wrong block<8,4> size/padding" ); 33static_assert ( sizeof (block < 8 , 8 > ) == 8 * sizeof (ggml_half) + QK8_0 * 8 , "wrong block<8,8> size/padding" ); 34static_assert ( sizeof (block < 8 , 16 > ) == 16 * sizeof (ggml_half) + QK8_0 * 16 , "wrong block<8,16> size/padding" ); 35 36using block_q4_0x4 = block < 4 , 4 > ; 37using block_q4_0x8 = block < 4 , 8 > ; 38using block_q4_0x16 = block < 4 , 16 > ; 39using block_q8_0x4 = block < 8 , 4 > ; 40using block_q8_0x8 = block < 8 , 8 > ; 41using block_q8_0x16 = block < 8 , 16 > ; 42 43struct block_q4_Kx8 { 44ggml_half d [ 8 ]; // super-block scale for quantized scales 45ggml_half dmin [ 8 ]; // super-block scale for quantized mins 46uint8_t scales [ 96 ]; // scales and mins, quantized with 6 bits 47uint8_t qs [ 1024 ]; // 4--bit quants 48}; 49 50static_assert ( sizeof (block_q4_Kx8) == sizeof (ggml_half) * 16 + K_SCALE_SIZE * 8 + QK_K * 4 , "wrong q4_K block size/padding" ); 51struct block_q4_Kx16 { 52ggml_half d [ 16 ]; // super-block scale for quantized scales 53ggml_half dmin [ 16 ]; // super-block scale for quantized mins 54uint8_t scales [ 192 ]; // scales and mins, quantized with 6 bits 55uint8_t qs [ 2048 ]; // 4--bit quants 56}; 57 58static_assert ( sizeof (block_q4_Kx16) == sizeof (ggml_half) * 32 + K_SCALE_SIZE * 16 + QK_K * 8 , "wrong q4_K block size/padding" ); 59struct block_q2_Kx8 { 60ggml_half d [ 8 ]; // super-block scale for quantized scales 61ggml_half dmin [ 8 ]; // super-block scale for quantized mins 62uint8_t scales [ 128 ]; // scales and mins, quantized with 4 bits 63uint8_t qs [ 512 ]; // 2--bit quants 64}; 65 66static_assert ( sizeof (block_q2_Kx8) == sizeof (ggml_half) * 16 + QK_K / 2 + QK_K * 2 , "wrong q2_K block size/padding" ); 67struct block_q2_Kx16 { 68ggml_half d [ 16 ]; // Super-block scale for quantized scales 69ggml_half dmin [ 16 ]; // Super-block scale for quantized mins 70uint8_t scales [ 256 ]; // Sub-block scales (16 cols * 16 sub-blocks) 71uint8_t qs [ 1024 ]; // Data (16 cols * 64 bytes per block) 72}; 73static_assert ( sizeof (block_q2_Kx16) == sizeof (ggml_half) * 32 + QK_K + QK_K * 4 , "wrong q2_K block size/padding" ); 74 75struct block_q5_Kx8 { 76ggml_half d [ 8 ]; // super-block scale for quantized scales 77ggml_half dmin [ 8 ]; // super-block scale for quantized mins 78uint8_t scales [ 96 ]; // scales and mins, quantized with 6 bits 79uint8_t qh [ QK_K * 8 / 8 ]; // high bits of 5-bit quants 80uint8_t qs [ QK_K * 8 / 2 ]; // low bits of 5-bit quants (in groups of 4) 81}; 82 83static_assert ( sizeof (block_q5_Kx8) == sizeof (ggml_half) * 16 + K_SCALE_SIZE * 8 + QK_K * 5 , 84"wrong q5_K block size/padding" ); 85 86struct block_q6_Kx8 { 87ggml_half d [ 8 ]; 88int8_t scales [ QK_K / 16 * 8 ]; 89uint8_t ql [ QK_K / 2 * 8 ]; // low bits of 6-bit quants (groups of 2) 90uint8_t qh [ QK_K / 4 * 8 ]; // high bits of 6-bit quants (groups of 4) 91}; 92 93static_assert ( sizeof (block_q6_Kx8) == sizeof (ggml_half) * 8 + QK_K / 16 * 8 + 3 * QK_K / 4 * 8 , 94"wrong q6_K block size/padding" ); 95 96struct block_q8_Kx4 { 97float d [ 4 ]; // delta 98int8_t qs [ QK_K * 4 ]; // quants 99int16_t bsums [ QK_K / 4 ]; // sum of quants in groups of 16 100}; 101 102static_assert ( sizeof (block_q8_Kx4) == sizeof ( float ) * 4 + QK_K * 4 + ( QK_K / 4 ) * sizeof ( int16_t ), "wrong q8_K block size/padding" ); 103 104struct block_iq4_nlx4 { 105ggml_half d [ 4 ]; // deltas for 4 iq4_nl blocks 106uint8_t qs [ QK4_NL * 2 ]; // nibbles / quants for 4 iq4_nl blocks 107}; 108 109static_assert ( sizeof (block_iq4_nlx4) == 4 * sizeof (ggml_half) + QK4_NL * 2 , "wrong iq4_nlx4 block size/padding" ); 110 111struct block_iq4_nlx8 { 112ggml_half d [ 8 ]; // deltas for 8 iq4_nl blocks 113uint8_t qs [ QK4_NL * 4 ]; // nibbles / quants for 8 iq4_nl blocks 114}; 115 116static_assert ( sizeof (block_iq4_nlx8) == 8 * sizeof (ggml_half) + QK4_NL * 4 , "wrong iq4_nlx8 block size/padding" ); 117 118struct block_iq4_nlx16 { 119ggml_half d [ 16 ]; // deltas for 16 iq4_nl blocks 120uint8_t qs [ QK4_NL * 8 ]; // nibbles / quants for 16 iq4_nl blocks 121}; 122 123static_assert ( sizeof (block_iq4_nlx16) == 16 * sizeof (ggml_half) + QK4_NL * 8 , "wrong iq4_nlx16 block size/padding" ); 124struct block_mxfp4x4 { 125uint8_t e [ 4 ]; 126uint8_t qs [ QK_MXFP4 * 2 ]; 127}; 128static_assert ( sizeof (block_mxfp4x4) == 4 + QK_MXFP4 * 2 , "wrong mxfp4x4 block size/padding" ); 129 130struct block_mxfp4x8 { 131uint8_t e [ 8 ]; 132uint8_t qs [ QK_MXFP4 * 4 ]; 133}; 134static_assert ( sizeof (block_mxfp4x8) == 8 + QK_MXFP4 * 4 , "wrong mxfp4x8 block size/padding" ); 135 136#if defined(__cplusplus) 137extern "C" { 138#endif 139 140void ggml_quantize_mat_q8_0_4x4 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 141void ggml_quantize_mat_q8_0_4x8 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 142void ggml_quantize_mat_q8_K_4x4 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 143void ggml_quantize_mat_q8_K_4x8 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 144void ggml_gemv_q4_0_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 145void ggml_gemv_q4_0_4x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 146void ggml_gemv_q4_0_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 147void ggml_gemv_q2_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 148void ggml_gemv_q4_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 149void ggml_gemv_q4_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 150void ggml_gemv_q5_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 151void ggml_gemv_q5_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 152void ggml_gemv_q6_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 153void ggml_gemv_q6_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 154void ggml_gemv_iq4_nl_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 155void ggml_gemv_iq4_nl_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 156void ggml_gemv_mxfp4_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 157void ggml_gemv_mxfp4_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 158void ggml_gemv_q8_0_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 159void ggml_gemv_q8_0_4x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 160void ggml_gemm_q4_0_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 161void ggml_gemm_q4_0_4x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 162void ggml_gemm_q4_0_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 163void ggml_gemm_q2_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 164void ggml_gemm_q4_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 165void ggml_gemm_q4_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 166void ggml_gemm_q5_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 167void ggml_gemm_q5_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 168void ggml_gemm_q6_K_8x4_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 169void ggml_gemm_q6_K_8x8_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 170void ggml_gemm_iq4_nl_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 171void ggml_gemm_iq4_nl_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 172void ggml_gemm_mxfp4_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 173void ggml_gemm_mxfp4_8x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 174void ggml_gemm_q8_0_4x4_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 175void ggml_gemm_q8_0_4x8_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 176#if defined __riscv_zvfh 177void ggml_quantize_mat_q8_0_4x1 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 178void ggml_quantize_mat_q8_K_4x1 ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 179void ggml_gemv_q4_0_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 180void ggml_gemv_q4_K_16x1_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 181void ggml_gemv_iq4_nl_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 182void ggml_gemv_q8_0_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 183void ggml_gemv_q2_K_16x1_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 184void ggml_gemm_q4_0_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 185void ggml_gemm_q4_K_16x1_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 186void ggml_gemm_iq4_nl_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 187void ggml_gemm_q8_0_16x1_q8_0 ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 188void ggml_gemm_q2_K_16x1_q8_K ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 189#endif 190 191// Native implementations 192void ggml_quantize_mat_q8_0_4x4_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 193void ggml_quantize_mat_q8_0_4x8_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 194void ggml_quantize_mat_q8_K_4x4_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 195void ggml_quantize_mat_q8_K_4x8_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 196void ggml_gemv_q4_0_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 197void ggml_gemv_q4_0_4x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 198void ggml_gemv_q4_0_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 199void ggml_gemv_q2_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 200void ggml_gemv_q4_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 201void ggml_gemv_q4_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 202void ggml_gemv_q5_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 203void ggml_gemv_q5_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 204void ggml_gemv_q6_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 205void ggml_gemv_q6_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 206void ggml_gemv_iq4_nl_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 207void ggml_gemv_iq4_nl_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 208void ggml_gemv_mxfp4_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 209void ggml_gemv_mxfp4_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 210void ggml_gemv_q8_0_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 211void ggml_gemv_q8_0_4x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 212void ggml_gemm_q4_0_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 213void ggml_gemm_q4_0_4x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 214void ggml_gemm_q4_0_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 215void ggml_gemm_q2_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 216void ggml_gemm_q4_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 217void ggml_gemm_q4_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 218void ggml_gemm_q5_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 219void ggml_gemm_q5_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 220void ggml_gemm_q6_K_8x4_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 221void ggml_gemm_q6_K_8x8_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 222void ggml_gemm_iq4_nl_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 223void ggml_gemm_iq4_nl_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 224void ggml_gemm_mxfp4_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 225void ggml_gemm_mxfp4_8x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 226void ggml_gemm_q8_0_4x4_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 227void ggml_gemm_q8_0_4x8_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 228#if defined __riscv_zvfh 229void ggml_quantize_mat_q8_0_4x1_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 230void ggml_quantize_mat_q8_K_4x1_generic ( const float * GGML_RESTRICT x, void * GGML_RESTRICT vy, int64_t k); 231void ggml_gemv_q4_0_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 232void ggml_gemv_q4_K_16x1_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 233void ggml_gemv_q8_0_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 234void ggml_gemv_q2_K_16x1_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 235void ggml_gemv_iq4_nl_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 236void ggml_gemm_q4_0_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 237void ggml_gemm_q4_K_16x1_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 238void ggml_gemm_q8_0_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 239void ggml_gemm_q2_K_16x1_q8_K_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 240void ggml_gemm_iq4_nl_16x1_q8_0_generic ( int n, float * GGML_RESTRICT s, size_t bs, const void * GGML_RESTRICT vx, const void * GGML_RESTRICT vy, int nr, int nc); 241#endif 242 243#if defined(__cplusplus) 244} // extern "C" 245#endif