alwaysinline expands to __attribute__((always_inline)).
This does not force gcc to inline the function. Instead, it allows gcc to
inline the function when complied without optimisations. (Normally, inline
functions are only inlined when compiled with optimisations.)[0]
alwaysinline was only used for bulk_insert_str, and it seems to be using it
in an attempt to force the function to be inlined. That won't work.
Furthermore, bulk_insert_str wasn't even declared inline, causing warnings.
Remove alwaysinline and replace with inline.
Remove the #defines, as they're no longer used.
[0] https://gcc.gnu.org/onlinedocs/gcc-4.7.2/gcc/Function-Attributes.html
Signed-off-by: Daniel Axtens <dja@axtens.net>
#ifndef NOT_TWEAK_COMPILER
-alwaysinline local void
+local inline void
bulk_insert_str(deflate_state *s, Pos startpos, uInt count) {
uInt idx;
for (idx = 0; idx < count; idx++) {
But it provides __inline instead, so use that. */
#if defined(_MSC_VER) && !defined(inline)
# define inline __inline
-#endif
-
-#if defined(_MSC_VER)
-# define alwaysinline __forceinline
-#else
-# define alwaysinline __attribute__ ((always_inline))
#endif
/* common defaults */