Stream: t-compiler/help

Topic: Debug info in stage 0 compiler?

osa1 (Nov 27 2019 at 14:59, on Zulip):

Is there a way to build stage 0 with debug info so that in backtraces I'll see line numbers? I have debug = true and debug_level = 2 in my config.toml but I still don't have any line numbers in my backtraces.

Wesley Wiser (Nov 27 2019 at 15:11, on Zulip):

The stage 0 compiler is the beta channel compiler that it downloaded to bootstrap so changing debug = true won't give you line numbers for backtraces because when it was built on the CI server, it wasn't built with debug symbols. If you continue the bootstrap to stage 1, then the compiler will be built with your debug settings.

See for more info

osa1 (Nov 27 2019 at 15:14, on Zulip):

Ahh, OK, in that sense it's not useful for me at all. I thought stage 0 is compiler built from source using the downloaded rustc.

Wesley Wiser (Nov 27 2019 at 15:16, on Zulip):

Nah, that's the stage1 compiler. stage0 just builds std

osa1 (Nov 27 2019 at 15:17, on Zulip):

:+1: thanks.

Wesley Wiser (Nov 27 2019 at 15:17, on Zulip):

Not sure what you're trying to do but you can build a compiler locally with debug symbols and tell rustbuild to use that instead of the beta compiler

Last update: Sep 18 2020 at 21:15UTC