Re: [PATCH v7 2/3] netfilter: x_tables: Merge xt_*.c files which has same name.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jan 06, 2025 at 12:31:56AM +0100, egyszeregy@xxxxxxxxxxx wrote:
> From: Benjamin Szőke <egyszeregy@xxxxxxxxxxx>
> 
> Merge xt_*.c source files, which has same upper and
> lower case name format. Combining these modules should
> provide some decent code size and memory savings.
> 
> Merge licenses, codes and adjuste Kconfig and Makefile
> for backwards-compatibility.
> 
> test-build:
> $ mkdir build
> $ wget -O ./build/.config https://pastebin.com/raw/teShg1sp
> $ make O=./build/ ARCH=x86 -j 16
> 
> x86_64-before:
> text    data     bss     dec     hex filename
>  716     432       0    1148     47c xt_dscp.o
> 1142     432       0    1574     626 xt_DSCP.o
>  593     224       0     817     331 xt_hl.o
>  934     224       0    1158     486 xt_HL.o
> 1099     120       0    1219     4c3 xt_rateest.o
> 2126     365       4    2495     9bf xt_RATEEST.o
>  747     224       0     971     3cb xt_tcpmss.o
> 2824     352       0    3176     c68 xt_TCPMSS.o
> total data: 2373
> 
> x86_64-after:
> text    data     bss     dec     hex filename
> 1709     848       0    2557     9fd xt_dscp.o
> 1352     448       0    1800     708 xt_hl.o
> 3075     481       4    3560     de8 xt_rateest.o
> 3423     576       0    3999     f9f xt_tcpmss.o
> total data: 2353

So you have saved 20 bytes in the data segment. A 0.8% reduction. If i
was developing this patchset, when i see this number, i would
immediately think, why am i bothering? It is not worth the effort for
the gains i'm getting. I'm also at risk of breaking the ABI and
userspace code, and 0.8% does not justify that risk.

This is why we ask for benchmarks. Benchmarks help to justify a
change. So far, there is no good justification for this.

    Andrew

---
pw-bot: cr






[Index of Archives]     [Netfitler Users]     [Berkeley Packet Filter]     [LARTC]     [Bugtraq]     [Yosemite Forum]

  Powered by Linux