Skip to content

llama: fix integer type consistency in split helpers#18894

Merged
ggerganov merged 3 commits intoggml-org:masterfrom
MaheshJakkala:fix-integer-types-split-clean
Jan 25, 2026
Merged

llama: fix integer type consistency in split helpers#18894
ggerganov merged 3 commits intoggml-org:masterfrom
MaheshJakkala:fix-integer-types-split-clean

Conversation

@MaheshJakkala
Copy link
Copy Markdown
Contributor

This PR fixes integer type inconsistencies in llama_split_path
and llama_split_prefix.

Changes:

  • Replace API-facing int with int32_t
  • Avoid narrowing conversions from size_t
  • Make signedness and intent explicit

Motivation:

  • Aligns with prior integer consistency changes in llama.h
  • Prevents truncation and signed/unsigned mismatches
  • Improves safety for downstream bindings

Notes:

  • Rebased on latest master
  • No server / CMake / workflow changes
  • No behavior or API changes intended

@MaheshJakkala
Copy link
Copy Markdown
Contributor Author

MaheshJakkala commented Jan 17, 2026

Thanks for reviewing!

FYI: This PR supersedes #18798, which I closed after rebasing cleanly on master as suggested.

Happy to make any changes if needed.

@MaheshJakkala
Copy link
Copy Markdown
Contributor Author

Gentle ping in case this got buried in the queue.
This is a clean rebase of #18798 with the same logic.
Happy to adjust or split further if preferred.

@ggerganov ggerganov merged commit 24bc238 into ggml-org:master Jan 25, 2026
74 of 78 checks passed
shaofeiqi pushed a commit to qualcomm/llama.cpp that referenced this pull request Feb 6, 2026
* llama: fix integer type consistency in split helpers

* llama: apply minor style fixes

* llama: remove trailing whitespace
Seunghhon pushed a commit to Seunghhon/llama.cpp that referenced this pull request Apr 26, 2026
* llama: fix integer type consistency in split helpers

* llama: apply minor style fixes

* llama: remove trailing whitespace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants