Rust 1.44.0 vs 1.47.0 library size huge difference


I'm building the same library with v1.44.0 and v1.47.0 and I notice a huge difference in .so size 3.4MB vs 9.3MB.

How can I find out what is causing so much difference?


Can you also try to compile using v1.45.0 and v1.46.0? That will help narrow the regression range down a bit.

It is 4.9MB with 1.46.0, not sure yet about 1.45.0.


The only think I can find in the release notes that may be related is the update to LLVM 11 in 1.47.0. What project do you see this difference for? I may be able to investigate it myself locally.

If the library is open source, you could link it to get some help with bisecting the exact point of size increase.

My library is private, but you can check library. You will need to add crate-type = ["cdylib"] in Cargo.toml to generate a .so file.

With 1.44.0 the size is 1.1MB, with 1.47.0 it is 6.6MB :man_shrugging: