Description
I'd expect build --release
to apply all optimisations, and one of them would be file size.
I tried two programs, a trivial "hello rust" and a trivial "hello panic". Both of their sizes were 3.8M which is pretty crazy for something that is supposed to be optimised... So I tried strip --strip-all
ing the executables.
Hello rust went to 372K
Hello panic went to 364K
That's a pretty huge change... The only difference in functionality I found is that RUST_BACKTRACE=1
shows a lot of <unknown>
s on strip
ed files which is to be expected, but I think that's not a real issue because the whole point of --release
is that it's not supposed to be debugged, there is the normal build
for that...
For now I will be strip --strip-all
ing all of my released executables but I really don't see a reason why build --release
doesn't do it. I'd be happy to be enlightened if I missed anything though!
Metadata
Metadata
Assignees
Labels
Type
Projects
Status