ggml-alloc: >= when checking for out-of-bounds
Co-authored-by: slaren <slarengh@gmail.com>
This commit is contained in:
parent
1b7f2c6dab
commit
b810424edf
1 changed files with 1 additions and 1 deletions
|
@ -397,7 +397,7 @@ static void allocate_node(struct ggml_allocr * alloc, struct ggml_tensor * node)
|
||||||
|
|
||||||
// if the node's data is external, then we cannot re-use it
|
// if the node's data is external, then we cannot re-use it
|
||||||
if ((char *) parent->data < (char *) alloc->data ||
|
if ((char *) parent->data < (char *) alloc->data ||
|
||||||
(char *) parent->data > ((char *) alloc->data + alloc->size)) {
|
(char *) parent->data >= ((char *) alloc->data + alloc->size)) {
|
||||||
AT_PRINTF("not reusing parent %s for %s as %p is external\n", parent->name, node->name, parent->data);
|
AT_PRINTF("not reusing parent %s for %s as %p is external\n", parent->name, node->name, parent->data);
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue