From d8206a939c6965d10afaa75ad8d7fe17d589ae58 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Tue, 12 Sep 2023 09:10:41 +0200 Subject: [PATCH] Reduce struct isc__nm_uvreq size from 1560 to 560 bytes The uv_req union member of struct isc__nm_uvreq contained libuv request types that we don't use. Turns out that uv_getnameinfo_t is 1000 bytes big and unnecessarily enlarged the whole structure. Remove all the unused members from the uv_req union. --- lib/isc/netmgr/netmgr-int.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/lib/isc/netmgr/netmgr-int.h b/lib/isc/netmgr/netmgr-int.h index a99153a8f2..3ee138405c 100644 --- a/lib/isc/netmgr/netmgr-int.h +++ b/lib/isc/netmgr/netmgr-int.h @@ -391,16 +391,11 @@ struct isc__nm_uvreq { int connect_tries; /* connect retries */ union { - uv_handle_t handle; uv_req_t req; - uv_getaddrinfo_t getaddrinfo; - uv_getnameinfo_t getnameinfo; - uv_shutdown_t shutdown; + uv_handle_t handle; uv_write_t write; uv_connect_t connect; uv_udp_send_t udp_send; - uv_fs_t fs; - uv_work_t work; } uv_req; ISC_LINK(isc__nm_uvreq_t) link; };