Adjust int types in format strings (#2009)

* tweak format sting types
This may not be all of them, but it's the ones which warn on OpenBSD

* complete the changes needed to fix the format string specifers

* avoid using inttypes, directly cast to size_t (u64 usually) instead

---------

Co-authored-by: Concedo <39025047+LostRuins@users.noreply.github.com>
This commit is contained in:
JustCommitRandomness
2026-03-06 11:06:18 +00:00
committed by GitHub
parent e36d7b6464
commit 2fbc3b2ae5
13 changed files with 37 additions and 37 deletions
+3 -3
View File
@@ -367,8 +367,8 @@ struct rwkv_v2_context * rwkv_v2_init_from_file(const char * file_path, uint32_t
// Verify order of dimensions
struct ggml_v2_tensor * emb = model->emb;
RWKV_V2_ASSERT_NULL(emb->n_dims == 2, "Unexpected dimension count of embedding matrix %d", emb->n_dims);
RWKV_V2_ASSERT_NULL(emb->ne[0] == model->n_embed, "Unexpected dimension of embedding matrix %ld", emb->ne[0]);
RWKV_V2_ASSERT_NULL(emb->ne[1] == model->n_vocab, "Unexpected dimension of embedding matrix %ld", emb->ne[1]);
RWKV_V2_ASSERT_NULL(emb->ne[0] == model->n_embed, "Unexpected dimension of embedding matrix %zu", (size_t)emb->ne[0]);
RWKV_V2_ASSERT_NULL(emb->ne[1] == model->n_vocab, "Unexpected dimension of embedding matrix %zu", (size_t)emb->ne[1]);
int32_t n_embed = model->n_embed;
int32_t n_layer = model->n_layer;
@@ -862,4 +862,4 @@ const char * rwkv_v2_get_system_info_string(void) {
s += "VSX = " + std::to_string(ggml_v2_cpu_has_vsx()) + " | ";
return s.c_str();
}
}