File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -322,6 +322,22 @@ comprehensive documentation in the excellent [`min-sized-rust`] repository.
322322The following build configuration options are designed primarily to minimize
323323compile times.
324324
325+ ### Disable debuginfo generation
326+
327+ If you want to improve the compile times of ` dev ` (unoptimized) builds and
328+ you're not using a debugger, consider disabling debuginfo. It can improve
329+ incremental rebuild times by 2-3x.
330+
331+ You can do that by putting this in your ` Cargo.toml ` file:
332+ ``` toml
333+ [profile .dev ]
334+ debug = false
335+ ```
336+
337+ Note that this means that stack traces will not contain line information.
338+ If you want to keep useful stack traces, but do not require full information
339+ for the debugger, you can use ` debug = "line-tables-only" ` instead.
340+
325341### Linking
326342
327343A big part of compile time is actually linking time, particularly when
You can’t perform that action at this time.
0 commit comments