From 93f0f21a4c1b3565c82ab22be91e7c49833e4aca Mon Sep 17 00:00:00 2001 From: Leonid Yuriev Date: Fri, 12 Mar 2021 12:35:01 +0300 Subject: [PATCH] mdbx-tools: minor speedup `mdbx_load` by adding `__hot/__inline` for internal functions. Change-Id: Iee7d2562dbe184475f01ab9a7f9aae11549d7294 --- src/mdbx_load.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mdbx_load.c b/src/mdbx_load.c index ebf892ee..e0536ccc 100644 --- a/src/mdbx_load.c +++ b/src/mdbx_load.c @@ -375,7 +375,7 @@ static int badend(void) { return errno ? errno : MDBX_ENODATA; } -static int unhex(unsigned char *c2) { +static __inline int unhex(unsigned char *c2) { int x, c; x = *c2++ & 0x4f; if (x & 0x40) @@ -388,7 +388,7 @@ static int unhex(unsigned char *c2) { return c; } -static int readline(MDBX_val *out, MDBX_val *buf) { +__hot static int readline(MDBX_val *out, MDBX_val *buf) { unsigned char *c1, *c2, *end; size_t len, l2; int c;