rust-lang / rust-lang/rust

Tracking Issue for `optimize_for_size` standard library feature

Open
#125,612 20 comments 11 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

C-tracking-issue I-heavy T-libs
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

View all comments

https://github.com/rust-lang/rust/pull/125011 has added a optimize_for_size feature to the standard library, which is designed for special casing some algorithms in core/alloc/std to provide an implementation that tries to minimize its effect on binary size.

To use this feature, the standard library has to be compiled using -Zbuild-std:

$ cargo +nightly build -Z build-std -Z build-std-features="optimize_for_size" ...

Optimizations that leverage this flag:

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

This is a tracking issue for the standard library's optimize_for_size feature; start by reading the linked pull requests and the -Zbuild-std and -Zbuild-std-features command shown in the issue. There is no individual file, test, or unclaimed change specified; completion consists of the relevant optimization work being identified and reflected in the checklist.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.