From: Evan Hunt Date: Thu, 26 Oct 2017 04:42:56 +0000 (-0700) Subject: [master] enable ISC_BUFFER_USEINLINE to be overridden X-Git-Tag: v9.12.0b2~57 X-Git-Url: http://git.ipfire.org/gitweb/?a=commitdiff_plain;h=5c76f3664c5e8115604afea14d3bb98ae434c22b;p=thirdparty%2Fbind9.git [master] enable ISC_BUFFER_USEINLINE to be overridden --- diff --git a/OPTIONS b/OPTIONS index bf36debecb2..21afbec59db 100644 --- a/OPTIONS +++ b/OPTIONS @@ -22,4 +22,7 @@ Setting Description Increase the maximum number of configurable -DNS_RPZ_MAX_ZONES=64 response policy zones from 32 to 64; this is the highest possible setting + Disable the use of inline functions to implement +-DISC_BUFFER_USEINLINE=0 the isc_buffer API: this reduces performance but + may be useful when debugging diff --git a/OPTIONS.md b/OPTIONS.md index fabf1adf9dc..0dda7dea85f 100644 --- a/OPTIONS.md +++ b/OPTIONS.md @@ -21,3 +21,4 @@ Some of these settings are: |`-DCHECK_LOCAL=0`|Don't check out-of-zone addresses in `named-checkzone`| |`-DNS_RUN_PID_DIR=0`|Create default PID files in `${localstatedir}/run` rather than `${localstatedir}/run/named/`| |`-DNS_RPZ_MAX_ZONES=64`|Increase the maximum number of configurable response policy zones from 32 to 64; this is the highest possible setting| +|`-DISC_BUFFER_USEINLINE=0`|Disable the use of inline functions to implement the `isc_buffer` API: this reduces performance but may be useful when debugging | diff --git a/lib/isc/include/isc/buffer.h b/lib/isc/include/isc/buffer.h index 5f8ad17819c..a02e0955fb0 100644 --- a/lib/isc/include/isc/buffer.h +++ b/lib/isc/include/isc/buffer.h @@ -104,10 +104,12 @@ #include /*! - * To make many functions be inline macros (via \#define) define this. - * If it is undefined, a function will be used. + * To make many functions be inline macros (via \#define) define this to 1. + * To use continue to use them as functions define this to 0. */ +#ifndef ISC_BUFFER_USEINLINE #define ISC_BUFFER_USEINLINE 1 +#endif ISC_LANG_BEGINDECLS @@ -1007,7 +1009,7 @@ ISC_LANG_ENDDECLS _cp[3] = (unsigned char)_val2; \ } while (0) -#if defined(ISC_BUFFER_USEINLINE) +#if ISC_BUFFER_USEINLINE #define isc_buffer_init ISC__BUFFER_INIT #define isc_buffer_initnull ISC__BUFFER_INITNULL #define isc_buffer_invalidate ISC__BUFFER_INVALIDATE