Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2719,7 +2719,7 @@ func.def inline @ggml_q6k_f32_vector4(%weight: buffer, %weight_row_byte_base: of
func.return %values : vector<4xf32>
}

func.def inline @ggml_q6k_row64_tile_lane_f32_vector4(%weight: buffer, %tile: index, %row_lane0: index, %q6_group: index, %packet: index) -> (vector<4xf32>) {
func.def inline @ggml_q6k_row64_tile_lane_f32_vector4(%weight: buffer, %tile: index, %row_lane: index, %q6_group: index, %packet: index) -> (vector<4xf32>) {
%c2 = index.constant 2 : index
%c4 = index.constant 4 : index
%tile_bytes = index.constant 13440 : offset
Expand All @@ -2731,7 +2731,6 @@ func.def inline @ggml_q6k_row64_tile_lane_f32_vector4(%weight: buffer, %tile: in
%c32_f32v = vector.constant 32.0 : vector<4xf32>
%bounded_group = index.assume %q6_group [range(%q6_group, 0, 7)] : index
%bounded_packet = index.assume %packet [range(%packet, 0, 7)] : index
%row_lane = index.assume %row_lane0 [range(%row_lane0, 0, 63)] : index
%tile_base = index.scale %tile, %tile_bytes : index, offset -> offset
%scale_byte_base = index.add %tile_base, %scale_byte_add : offset
%raw_byte_base = index.add %tile_base, %raw_byte_add : offset
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -232,7 +232,9 @@ func.def inline @ggml_matmul_tiled_input_f32_dequant_accumulate_f32(%full_token_
scf.yield %half : vector<4xf16>
} else {
%q6_or_generic = scf.if %weight_is_q6_row64 -> (vector<4xf16>) {
%wide = func.call @ggml_q6k_row64_tile_lane_f32_vector4(%weight_noalias, %row64_tile, %local_row, %quant_group, %load_packet) : (buffer, index, index, index, index) -> (vector<4xf32>)
// Keep this hint local to prefill to preserve vector decode code generation.
%row_lane = index.assume %local_row [range(%local_row, 0, 63)] : index
%wide = func.call @ggml_q6k_row64_tile_lane_f32_vector4(%weight_noalias, %row64_tile, %row_lane, %quant_group, %load_packet) : (buffer, index, index, index, index) -> (vector<4xf32>)
%half = vector.fptrunc %wide : vector<4xf32> to vector<4xf16>
scf.yield %half : vector<4xf16>
} else {
Expand Down
Loading