AOSC-Archive / autobuild3

AOSC OS package maintenance toolkit (version 3)
https://aosc.io
GNU General Public License v2.0
24 stars 17 forks source link

Retro: use -Os instead of -O2 #113

Open Artoria2e5 opened 4 years ago

Artoria2e5 commented 4 years ago

my laptop screen is dead and i cant be arsed to type on a phone or i would be sending a PR already

anyway apple does this extensively with clang, and I don't expect the performance to be terrible since we could be saving instruction cache

hell we could use -Oz on clang. who cares about auto vectorization on a pentium.

MingcongBai commented 4 years ago

I would, but honestly, on Pentium MMX, Pentium, and even 486 - I don't look forward to this prospect...

Icenowy commented 4 years ago

@MingcongBai as I know, when memory is the bottleneck, the memory saved by -Os is precious and will really make performance better.

MingcongBai commented 4 years ago

@MingcongBai as I know, when memory is the bottleneck, the memory saved by -Os is precious and will really make performance better.

Might be worth a try, this is usually the issue with our target devices. But honestly, mostly with i486.

MingcongBai commented 4 years ago

However, I should note that with our i486's 508MiB installed size, over 200MiB goes to /usr/share.