[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd2] branch master updated (a71f9db -> c46a09d)
From: |
Admin |
Subject: |
[libmicrohttpd2] branch master updated (a71f9db -> c46a09d) |
Date: |
Sat, 14 Jun 2025 19:15:15 +0200 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a change to branch master
in repository libmicrohttpd2.
from a71f9db perf_replies: added response sizes 8 MiB and 101 MiB
new fa37ebd perf_replies: fixed pseudo-random sequence generation
new 993b448 perf_replies: fixed parameter check
new 14eac1f perf_replies: corrected messages
new f480f02 perf_replies: corrected response filler
new 6037d05 mhd_sys_options: added workaround for some broken W32
compilers
new 864f86d mhd_sys_options: fixed formatting
new b733b69 perf_replies: minor readability improvement
new c46a09d configure: added more release linker flags
The 8 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
configure.ac | 3 ++-
src/incl_priv/mhd_sys_options.h | 13 ++++++++++---
src/tools/perf_replies.c | 28 ++++++++++++++--------------
3 files changed, 26 insertions(+), 18 deletions(-)
diff --git a/configure.ac b/configure.ac
index 4718c5c..91393ab 100644
--- a/configure.ac
+++ b/configure.ac
@@ -564,7 +564,8 @@ AS_CASE([${enable_build_type}],[release|release-*],
)
CFLAGS="${CFLAGS_ac} ${user_CFLAGS}"
LDFLAGS="${user_LDFLAGS}"
- MHD_CHECK_ADD_CC_LDFLAGS([-Wl,-O1], [LDFLAGS_ac])
+ MHD_FIND_ADD_CC_LDFLAG([LDFLAGS_ac], [-Wl,-O2], [-Wl,-O1])
+ MHD_CHECK_ADD_CC_LDFLAGS([-Wl,--as-needed], [LDFLAGS_ac])
AS_VAR_IF([enable_build_type],["release-hardened"],
[:],
[MHD_CHECK_ADD_CC_LDFLAGS([-Wl,--gc-sections -Wl,--icf=all],
[LDFLAGS_ac])]
diff --git a/src/incl_priv/mhd_sys_options.h b/src/incl_priv/mhd_sys_options.h
index a2b0fd4..d79f526 100644
--- a/src/incl_priv/mhd_sys_options.h
+++ b/src/incl_priv/mhd_sys_options.h
@@ -40,6 +40,13 @@
# endif
#endif
+#ifdef _WIN64
+/* workaround for some broken compilers */
+# ifndef _WIN32
+# define _WIN32 1
+# endif
+#endif
+
#include "mhd_config.h"
/**
@@ -221,7 +228,7 @@
#endif
#ifdef HAVE_ATTR_FUNC_ASSUME_ALIGNED
-# define mhd_FN_RET_ALIGNED(align) __attribute__((assume_aligned(align)))
+# define mhd_FN_RET_ALIGNED(align) __attribute__((assume_aligned (align)))
#else
# define mhd_FN_RET_ALIGNED(align) /* empty */
#endif
@@ -231,7 +238,7 @@
* Indicates that returned pointer points to object with the size specified
* by parameter number @a param_num.
*/
-# define mhd_FN_RET_SIZED(param_num) __attribute__((alloc_size(param_num)))
+# define mhd_FN_RET_SIZED(param_num) __attribute__((alloc_size (param_num)))
#else
/**
* Indicates that returned pointer points to object with the size specified
@@ -260,7 +267,7 @@
* another function @a destructor.
*/
# define mhd_FN_OBJ_CONSTRUCTOR(destructor) \
- __attribute__((malloc(destructor)))
+ __attribute__((malloc (destructor)))
#else
/**
* Indicates that function creates the object that mast be destructed by
diff --git a/src/tools/perf_replies.c b/src/tools/perf_replies.c
index 2d1a7bd..e045b99 100644
--- a/src/tools/perf_replies.c
+++ b/src/tools/perf_replies.c
@@ -320,13 +320,13 @@ show_help (void)
printf ("Usage: %s [OPTIONS] [PORT_NUMBER]\n", self_name);
printf ("Start MHD2-based web-server optimised for fast replies.\n");
printf ("\n");
- printf ("Threads options (mutually exclusive):\n");
+ printf ("Threading options (mutually exclusive):\n");
printf (" -A, --all-cpus use all available CPU cores (for \n"
" testing with remote client)\n");
printf (" -t NUM, --threads=NUM use NUM threads\n");
#if 0 /* disabled code */
printf (" -P, --thread-per-conn use thread-per-connection mode,\n"
- " the number of threads are limited
only\n"
+ " the number of threads is limited only\n"
" by the number of connection\n");
#endif /* disabled code */
printf ("\n");
@@ -369,7 +369,7 @@ show_help (void)
if ((MHD_NO == mhdl_info.v_types_sockets_polling.func_select) &&
(MHD_NO == mhdl_info.v_types_sockets_polling.func_poll) &&
(MHD_NO == mhdl_info.v_types_sockets_polling.tech_epoll))
- fprintf (stderr, "No internal sockets polling function available!\n");
+ fprintf (stderr, "No internal sockets polling function is available!\n");
}
@@ -1344,7 +1344,7 @@ static int
check_param__select (void)
{
union MHD_LibInfoFixedData mhdl_info;
- if (! tool_params.poll)
+ if (! tool_params.select)
return ! 0;
(void) MHD_lib_get_info_fixed (MHD_LIB_INFO_FIXED_TYPES_SOCKETS_POLLING,
&mhdl_info);
@@ -1438,8 +1438,8 @@ mini_rnd (void)
{
/* Simple xoshiro256+ implementation */
static uint_fast64_t s[4] = {
- 0x76e15d3efefdcbbfuLL, 0xc5004e441c522fb3uLL,
- 0x77710069854ee241uLL, 0x39109bb02acbe635uLL
+ 0xE220A8397B1DCDAFuLL, 0x6E789E6AA1B965F4uLL,
+ 0x06C45D188009454FuLL, 0xF88BB8A8724C81ECuLL
}; /* Good enough for static initialisation */
const uint_fast64_t ret = (s[0] + s[3]) & 0xFFFFFFFFFFFFFFFFuLL;
@@ -1450,7 +1450,7 @@ mini_rnd (void)
s[1] ^= s[2];
s[0] ^= s[3];
s[2] ^= t;
- s[3] = ((s[3] << 45u) | (s[3] << (64u - 45u))) & 0xFFFFFFFFFFFFFFFFuLL;
+ s[3] = ((s[3] << 45u) | (s[3] >> (64u - 45u))) & 0xFFFFFFFFFFFFFFFFuLL;
return ret;
}
@@ -1487,7 +1487,7 @@ init_response_body_data (void)
size_t filler_pos;
static const char body_header[] =
"<html>\n"
- "<head>\n<title>Sample page title</title>\n<head>\n"
+ "<head>\n<title>Sample page title</title>\n</head>\n"
"<body>\n";
static const char body_filler[] =
"The quick brown fox jumps over the lazy dog.<br>\n";
@@ -1531,7 +1531,7 @@ init_response_body_data (void)
body_dyn[pos + 4] = (char) (unsigned char) (rnd_data >> 32);
body_dyn[pos + 5] = (char) (unsigned char) (rnd_data >> 40);
body_dyn[pos + 6] = (char) (unsigned char) (rnd_data >> 48);
- body_dyn[pos + 7] = (char) (unsigned char) (rnd_data >> 54);
+ body_dyn[pos + 7] = (char) (unsigned char) (rnd_data >> 56);
}
rnd_data = mini_rnd ();
for ((void) pos; pos < body_dyn_size; ++pos)
@@ -1638,7 +1638,7 @@ init_data (void)
return 0; /* Success */
/* Cleanup */
- while (--i < num_resps)
+ while (i-- != 0)
MHD_response_destroy (resps[i]);
free (resps);
resps = NULL;
@@ -1801,12 +1801,12 @@ print_perf_warnings (void)
newline_needed |= ! 0;
#endif /* _DEBUG */
#if defined(__GNUC__) && ! defined (__OPTIMIZE__)
- fprintf (stderr, "WARNING: The tools is compiled without compiler "
+ fprintf (stderr, "WARNING: This tool is compiled without compiler "
"optimisations enabled, the performance is suboptimal.\n");
newline_needed |= ! 0;
#endif /* __GNUC__ && ! __OPTIMIZE__ */
#if defined(__GNUC__) && defined (__OPTIMIZE_SIZE__)
- fprintf (stderr, "WARNING: The tools is compiled with size-optimisations, "
+ fprintf (stderr, "WARNING: This tool is compiled with size-optimisations, "
"the performance is suboptimal.\n");
newline_needed |= ! 0;
#endif /* __GNUC__ && ! __OPTIMIZE__ */
@@ -1818,7 +1818,7 @@ print_perf_warnings (void)
if (MHD_NO == mhdl_info.v_is_non_debug_bool)
{
fprintf (stderr, "WARNING: The libmicrohttpd2 library is compiled with "
- "debug asserts enabled, the performance is suboptimal.\n");
+ "debug asserts enabled, performance is suboptimal.\n");
newline_needed |= ! 0;
}
}
@@ -1850,7 +1850,7 @@ get_mhd_poll_func_name (struct MHD_Daemon *d)
default:
break;
}
- return "[unkonwn]";
+ return "[unknown]";
}
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.
- [libmicrohttpd2] branch master updated (a71f9db -> c46a09d),
Admin <=
- [libmicrohttpd2] 02/08: perf_replies: fixed parameter check, Admin, 2025/06/14
- [libmicrohttpd2] 01/08: perf_replies: fixed pseudo-random sequence generation, Admin, 2025/06/14
- [libmicrohttpd2] 04/08: perf_replies: corrected response filler, Admin, 2025/06/14
- [libmicrohttpd2] 03/08: perf_replies: corrected messages, Admin, 2025/06/14
- [libmicrohttpd2] 05/08: mhd_sys_options: added workaround for some broken W32 compilers, Admin, 2025/06/14
- [libmicrohttpd2] 06/08: mhd_sys_options: fixed formatting, Admin, 2025/06/14
- [libmicrohttpd2] 08/08: configure: added more release linker flags, Admin, 2025/06/14
- [libmicrohttpd2] 07/08: perf_replies: minor readability improvement, Admin, 2025/06/14