MCPcopy Create free account
hub / github.com/Tiiny-AI/PowerInfer / ggml_are_same_layout

Function ggml_are_same_layout

ggml-alloc.c:402–415  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

400}
401
402static bool ggml_are_same_layout(const struct ggml_tensor * a, const struct ggml_tensor * b) {
403 if (a->type != b->type) {
404 return false;
405 }
406 for (int i = 0; i < GGML_MAX_DIMS; i++) {
407 if (a->ne[i] != b->ne[i]) {
408 return false;
409 }
410 if (a->nb[i] != b->nb[i]) {
411 return false;
412 }
413 }
414 return true;
415}
416
417static bool ggml_op_can_inplace(enum ggml_op op) {
418 switch (op) {

Callers 1

allocate_nodeFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected