ggml : set output of view src (llama/25729)

* llama-graph: set_outputs to t->view_src

* change set_output to GGML_ASSERT about views not being outputs

* sampler : avoid views in outputs

* cont : fix dist sampler

* cont : consistent logits handling

* ggml : set output of view src

* graph : simplify set_outputs()

* cont : cleanup

Co-authored-by: Gaurav Garg <gaugarg@nvidia.com>

---------

Co-authored-by: Georgi Gerganov <ggerganov@gmail.com>
Co-authored-by: Gaurav Garg <gaugarg@nvidia.com>
This commit is contained in:
Aman Gupta 2026-07-28 21:23:24 +08:00 committed by Georgi Gerganov
parent cb8a0ad83c
commit 98dc176072
No known key found for this signature in database
GPG Key ID: 449E073F9DC10735
1 changed files with 3 additions and 1 deletions

View File

@ -7854,7 +7854,9 @@ void ggml_set_input(struct ggml_tensor * tensor) {
}
void ggml_set_output(struct ggml_tensor * tensor) {
tensor->flags |= GGML_TENSOR_FLAG_OUTPUT;
for (struct ggml_tensor * cur = tensor; cur != NULL; cur = cur->view_src) {
cur->flags |= GGML_TENSOR_FLAG_OUTPUT;
}
}
void ggml_set_param(struct ggml_tensor * tensor) {