rust-lang / rust-lang/rustc_codegen_gcc
Binary size when compiling with rustc_codegen_gcc
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 1.2k
- Forks
- 105
- Avg merge
- 8h 20m
- Merged PRs (30d)
- 14
Description
I tried compiling the default "Hello, world!" program with rustc_codegen_gcc, and noticed the resulting binary has a size of ~20MB, opposed to the default rustc ~3MB binary. I don't know if it has something to do with optimization, or static libraries.
I also tried building the binary with --release, and got an ICE due to LTO not being implemented. Are these two things related?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the default and --release "Hello, world!" builds with rustc_codegen_gcc and compare their binary sizes with default rustc. Start by investigating optimization, static libraries, and the reported LTO ICE; done means determining whether the size difference and missing LTO are related and documenting or fixing the cause.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- compilers
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100