mirror of
				https://github.com/ggml-org/llama.cpp.git
				synced 2025-10-31 08:51:55 +00:00 
			
		
		
		
	sync : ggml (#6351)
* sync : ggml ggml-ci * cuda : move GGML_CUDA_DMMV constants to dmmv.cuh --------- Co-authored-by: slaren <slarengh@gmail.com>
This commit is contained in:
		| @@ -705,8 +705,13 @@ bool ggml_gallocr_reserve_n(ggml_gallocr_t galloc, struct ggml_cgraph * graph, c | ||||
|         struct ggml_tensor * leaf = graph->leafs[i]; | ||||
|         struct hash_node * hn = ggml_gallocr_hash_get(galloc, leaf); | ||||
|         galloc->leaf_allocs[i].buffer_id = hn->buffer_id; | ||||
|         galloc->leaf_allocs[i].leaf.offset = hn->offset; | ||||
|         galloc->leaf_allocs[i].leaf.size_max = ggml_backend_buft_get_alloc_size(galloc->bufts[hn->buffer_id], leaf); | ||||
|         if (leaf->view_src || leaf->data) { | ||||
|             galloc->leaf_allocs[i].leaf.offset = SIZE_MAX; | ||||
|             galloc->leaf_allocs[i].leaf.size_max = 0; | ||||
|         } else { | ||||
|             galloc->leaf_allocs[i].leaf.offset = hn->offset; | ||||
|             galloc->leaf_allocs[i].leaf.size_max = ggml_backend_buft_get_alloc_size(galloc->bufts[hn->buffer_id], leaf); | ||||
|         } | ||||
|     } | ||||
|  | ||||
|     // reallocate buffers if needed | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Georgi Gerganov
					Georgi Gerganov