Stream: t-compiler

Topic: make incremental respect -Ccodegen-units compiler-team#245

pnkfelix (Feb 05 2020 at 16:26, on Zulip):


pnkfelix (Feb 05 2020 at 16:26, on Zulip):

hey @mw regarding this change proposal

pnkfelix (Feb 05 2020 at 16:27, on Zulip):

did you notice any impact when bootstrapping rustc itself with incremental turned on?

pnkfelix (Feb 05 2020 at 16:27, on Zulip):

or wait, we don't set -Ccodegen-units anyway in the default config.toml , do we?

pnkfelix (Feb 05 2020 at 16:28, on Zulip):

oh but the point still stands nonetheless, even without an explicit setting...

simulacrum (Feb 05 2020 at 18:18, on Zulip):

@pnkfelix we do not set it explicitly, and the config.toml.example lies about the default (it's just the "regular" compiler default, so 16 w/o incremental and 2*modules it sounds like with)

pnkfelix (Feb 05 2020 at 18:19, on Zulip):

Right. So with this change, it will go from being 2*modules to 256 when incremental is on, right?

simulacrum (Feb 05 2020 at 18:21, on Zulip):

Well, 2*modules I think but capped at 256?

pnkfelix (Feb 05 2020 at 18:57, on Zulip):

okay yes; the main point is that the max (of 16) was not respected before, and now the new max (of 256) will be respected. Does that sound right?

simulacrum (Feb 05 2020 at 19:00, on Zulip):

Yes. I personally am not sure if @mw has done much experimentation around the exact number.

mw (Feb 06 2020 at 10:18, on Zulip): has a number of perf runs with different default values. 256 seemed to be a good compromise between granularity and overhead.

mw (Feb 06 2020 at 10:20, on Zulip):

I did not do any measurements on bootstrap time with this. I expect that librustc exceeds the default and would profit from the change.

simulacrum (Feb 06 2020 at 13:01, on Zulip):

Sounds good.

mw (Feb 06 2020 at 13:05, on Zulip):

Also, the default can be tweaked in the future. The more important change is that the user now has control over something that could not be influenced before.

Last update: Feb 25 2020 at 04:15UTC