openwrt/package/libs
Eneas U de Queiroz 975036f6f9
openssl: avoid OPENSSL_SMALL_FOOTPRINT, no-asm
Building openssl with OPENSSL_SMALL_FOOTPRINT yelds only from 1% to 3%
decrease in size, dropping performance from 2% to 91%, depending on the
target and algorithm.

For example, using AES256-GCM with 1456-bytes operations, X86_64 appears
to be the least affected with 2% performance penalty and 1% reduction in
size; mips drops performance by 13%, size by 3%;  Arm drops 29% in
performance, 2% in size.

On aarch64, it slows down ghash so much that I consider it broken
(-91%).  SMALL_FOOTPRINT will reduce AES256-GCM performance by 88%, and
size by only 1%.  It makes an AES-capable CPU run AES128-GCM at 35% of
the speed of Chacha20-Poly1305:

Block-size=1456 bytes   AES256-GCM   AES128-GCM  ChaCha20-Poly1305
SMALL_FOOTPRINT           62014.44     65063.23          177090.50
regular                  504220.08    565630.28          182706.16

OpenSSL 1.1.1 numbers are about the same, so this should have been
noticed a long time ago.

This creates an option to use OPENSSL_SMALL_FOOTPRINT, but it is turned
off by default unless SMALL_FLASH or LOW_MEMORY_FOOTPRINT is used.

Compiling with -O3 instead of -Os, for comparison, will increase size by
about 14-15%, with no measureable effect on AES256-GCM performance, and
about 2% increase in Chacha20-Poly1305 performance on Aarch64.

There are no Arm devices with the small flash feature, so drop the
conditional default.  The package is built on phase2, so even if we
include an Arm device with small flash later, a no-asm library would
have to be built from source anyway.

Signed-off-by: Eneas U de Queiroz <cotequeiroz@gmail.com>
2023-04-05 08:24:49 -03:00
..
argp-standalone treewide: opt-out of tree-wide LTO usage 2023-03-21 18:28:23 +01:00
elfutils treewide: replace PKG_USE_MIPS16:=0 with PKG_BUILD_FLAGS:=no-mips16 2023-03-21 18:28:22 +01:00
gettext-full gettext-full: update to 0.21.1 2022-10-22 21:10:34 +02:00
gmp treewide: replace PKG_USE_MIPS16:=0 with PKG_BUILD_FLAGS:=no-mips16 2023-03-21 18:28:22 +01:00
jansson treewide: add support for "lto" in PKG_BUILD_FLAGS 2023-03-21 18:28:22 +01:00
libaudit treewide: replace PKG_USE_MIPS16:=0 with PKG_BUILD_FLAGS:=no-mips16 2023-03-21 18:28:22 +01:00
libbsd libbsd: fix libpath to not use host path 2022-12-26 13:36:41 +01:00
libcap libcap: update to 2.67 2023-02-25 00:14:38 +01:00
libevent2 treewide: add support for "lto" in PKG_BUILD_FLAGS 2023-03-21 18:28:22 +01:00
libiconv-full libiconv-full: add host build 2022-07-17 14:21:03 +02:00
libjson-c libjson-c: disable libbsd 2022-07-04 20:37:41 +02:00
libmd libmd: add library providing message digest functions 2022-09-11 01:30:11 +02:00
libmnl libmnl: add PKG_CPE_ID 2022-09-06 16:36:44 +01:00
libnetfilter-conntrack libnetfilter-conntrack: backport patch fixing compilation with 5.15 2022-03-05 21:05:45 +01:00
libnfnetlink libnfnetlink: add PKG_CPE_ID 2022-09-06 16:36:45 +01:00
libnftnl treewide: add support for "lto" in PKG_BUILD_FLAGS 2023-03-21 18:28:22 +01:00
libnl treewide: add support for "gc-sections" in PKG_BUILD_FLAGS 2023-03-21 18:28:22 +01:00
libnl-tiny libnl-tiny: update to the latest version 2023-04-02 02:25:16 +02:00
libpcap libpcap: update to 1.10.3 2023-01-17 23:16:02 +01:00
libselinux libselinux: add PKG_CPE_ID 2022-09-06 16:36:48 +01:00
libsemanage libsemanage: update to version 3.3 2021-10-28 22:15:02 +01:00
libsepol libsepol: add PKG_CPE_ID 2022-09-06 16:36:48 +01:00
libtool libtool: update to 2.4.7 2022-07-10 19:07:47 +02:00
libtraceevent libtraceevent: update to 1.7.2 2023-04-01 22:02:24 +02:00
libtracefs libtracefs: update to 1.6.4 2023-01-13 22:02:20 +01:00
libubox libubox: update to the latest version 2022-10-14 13:12:23 +02:00
libunwind libunwind: update to 1.6.2 2022-09-07 04:22:40 +01:00
libusb packages: libusb: add package 'fxload' (from libusb examples) 2022-09-17 00:44:08 +01:00
mbedtls treewide: opt-out of tree-wide LTO usage 2023-03-21 18:28:23 +01:00
musl-fts musl-fts: remove shared libraries from host 2022-03-27 14:38:13 +02:00
ncurses ncurses: add alacritty terminfo 2023-02-26 01:12:02 +01:00
nettle treewide: replace PKG_USE_MIPS16:=0 with PKG_BUILD_FLAGS:=no-mips16 2023-03-21 18:28:22 +01:00
openssl openssl: avoid OPENSSL_SMALL_FOOTPRINT, no-asm 2023-04-05 08:24:49 -03:00
pcre pcre: pass -fPIC under host as well 2022-04-16 14:02:11 +02:00
popt popt: update to 1.19 2022-10-02 20:22:54 +02:00
readline readline: update to 8.2 2022-10-23 18:16:22 +02:00
sysfsutils sysfsutils: Define START early in file 2022-09-26 17:58:32 +01:00
toolchain toolchain: reproducible libstdcpp 2022-04-01 12:54:58 +01:00
uclient uclient: update to Git version 2021-05-14 2021-05-14 23:40:42 +02:00
ustream-ssl ustream-ssl: update to Git version 2023-02-25 2023-02-25 18:37:26 +01:00
wolfssl treewide: add support for "lto" in PKG_BUILD_FLAGS 2023-03-21 18:28:22 +01:00
zlib zlib: update to 1.2.13 2022-11-13 20:47:57 +01:00