Skip to content

Commit 819a5b1

Browse files
fix row padding
1 parent 62e94d0 commit 819a5b1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

ggml.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11391,8 +11391,8 @@ static void ggml_compute_forward_mul_mat(
1139111391
if (params->type == GGML_TASK_INIT) {
1139211392
if (src1->type != vec_dot_type) {
1139311393
char * wdata = params->wdata;
11394-
const size_t row_size = ggml_type_size(vec_dot_type)*(ne10 + ggml_blck_size(vec_dot_type) - 1)
11395-
/ ggml_blck_size(vec_dot_type);
11394+
const size_t row_size = ggml_type_size(vec_dot_type)*((ne10 + ggml_blck_size(vec_dot_type) - 1)
11395+
/ ggml_blck_size(vec_dot_type));
1139611396

1139711397
for (int64_t i13 = 0; i13 < ne13; ++i13) {
1139811398
for (int64_t i12 = 0; i12 < ne12; ++i12) {
@@ -11412,8 +11412,8 @@ static void ggml_compute_forward_mul_mat(
1141211412
}
1141311413

1141411414
const void * wdata = (src1->type == vec_dot_type) ? src1->data : params->wdata;
11415-
const size_t row_size = ggml_type_size(vec_dot_type)*(ne10 + ggml_blck_size(vec_dot_type) - 1)
11416-
/ ggml_blck_size(vec_dot_type);
11415+
const size_t row_size = ggml_type_size(vec_dot_type)*((ne10 + ggml_blck_size(vec_dot_type) - 1)
11416+
/ ggml_blck_size(vec_dot_type));
1141711417

1141811418
const int64_t nr0 = ne01; // src0 rows
1141911419
const int64_t nr1 = ne11*ne12*ne13; // src1 rows

0 commit comments

Comments
 (0)