From 7f1012ff7c8b8762c247698cb6f84963674d1f55 Mon Sep 17 00:00:00 2001 From: Ryan Libby Date: Mon, 3 Jun 2024 11:35:28 -0700 Subject: [PATCH] pctrie: predict successful allocation Reviewed by: dougm Sponsored by: Dell EMC Isilon Differential Revision: https://reviews.freebsd.org/D45407 --- sys/sys/pctrie.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/sys/pctrie.h b/sys/sys/pctrie.h index eec74610587..38b29789959 100644 --- a/sys/sys/pctrie.h +++ b/sys/sys/pctrie.h @@ -84,7 +84,7 @@ name##_PCTRIE_INSERT(struct pctrie *ptree, struct type *ptr) \ if (parentp == NULL) \ return (0); \ parent = allocfn(ptree); \ - if (parent == NULL) \ + if (__predict_false(parent == NULL)) \ return (ENOMEM); \ pctrie_insert_node(parentp, parent, val); \ return (0); \