Skip to content

Commit f05fdf9

Browse files
author
FMayran
committed
fix compiler warning in llama_ubatch struct construction
1 parent 5f91c45 commit f05fdf9

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/llama-batch.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -224,6 +224,7 @@ bool llama_batch_allocr::init(
224224
/*.seq_idx =*/ this->seq_idx.data(),
225225
/*.output =*/ batch.logits,
226226
/*.data =*/ {},
227+
/*.kv_position_of_token=*/ {},
227228
};
228229

229230
ubatch_print(ubatch, debug);
@@ -399,6 +400,7 @@ llama_ubatch llama_batch_allocr::ubatch_reserve(uint32_t n_seq_tokens, uint32_t
399400
/*.seq_idx =*/ udata->seq_idx.data(),
400401
/*.output =*/ udata->output.data(),
401402
/*.data =*/ std::move(udata),
403+
/*.kv_position_of_token=*/ {},
402404
};
403405

404406
return res;
@@ -720,6 +722,7 @@ llama_ubatch llama_batch_allocr::ubatch_add(const std::vector<int32_t> & idxs, u
720722
/*.seq_idx =*/ udata->seq_idx.data(),
721723
/*.output =*/ udata->output.data(),
722724
/*.data =*/ std::move(udata),
725+
/*.kv_position_of_token=*/ {},
723726
};
724727

725728
if (debug > 0) {

0 commit comments

Comments
 (0)