-
Notifications
You must be signed in to change notification settings - Fork 13.3k
redesign stage 0 std #119899
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
redesign stage 0 std #119899
Conversation
This comment has been minimized.
This comment has been minimized.
9fcee5c
to
066ce06
Compare
This comment has been minimized.
This comment has been minimized.
066ce06
to
472c50c
Compare
This comment has been minimized.
This comment has been minimized.
ce81474
to
b688ffa
Compare
This comment has been minimized.
This comment has been minimized.
5f1747d
to
00e59f0
Compare
This PR modifies If appropriate, please update |
@rustbot ready r? bootstrap |
00e59f0
to
8ac271c
Compare
@rustbot author (currently stage 2 std is copied from stage 1 and this behaviour should change with the beta std change) |
This comment has been minimized.
This comment has been minimized.
@bors try |
redesign stage 0 std ### Summary This PR changes how bootstrap builds the stage 1 compiler by switching to precompiled stage 0 standard library instead of building the in-tree one. The goal was to update bootstrap to use the beta standard library at stage 0 rather than compiling it from source (see the motivation at rust-lang/compiler-team#619). Previously, to build a stage 1 compiler bootstrap followed this path: ``` download stage0 compiler -> build in-tree std -> compile stage1 compiler with in-tree std ``` With this PR, the new path is: ``` download stage0 compiler -> compile stage1 compiler with precompiled stage0 std ``` This also means that `cfg(bootstrap)`/`cfg(not(bootstrap))` is no longer needed for library development. ### Building "library" Since stage0 `std` is no longer in-tree `x build/test/check library --stage 0` is now no-op. The minimum supported stage to build `std` is now 1. For the same reason, default stage values in the library profile is no longer 0. Because building the in-tree library now requires a stage1 compiler, I highly recommend library developers to enable `download-rustc` to speed up compilation time. <hr> If you encounter a bug or unexpected results please open a topic in the [#t-infra/bootstrap](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap) Zulip channel or create a [bootstrap issue](https://github.com/rust-lang/rust/issues/new?template=bootstrap.md). (Review thread: https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Review.20thread.3A.20stage.200.20redesign.20PR/with/508271433) ~~Blocked on rust-lang#122709 try-job: dist-x86_64-linux
Signed-off-by: onur-ozkan <work@onurozkan.dev>
9f756b7
to
a0030fb
Compare
I strongly believe a0030fb will fix the filesystem issue (hopefully without introducing new bugs). I'll wait for the current try run to finish for testing it. |
I'm not actually sure if we even need to specify |
I think it's cool to keep that option, and yeah, it wouldn't fix that problem. |
This comment has been minimized.
This comment has been minimized.
Signed-off-by: onur-ozkan <work@onurozkan.dev>
a0030fb
to
d6f178a
Compare
The job Click to see the possible cause of the failure (guessed by this bot)
|
@bors try |
redesign stage 0 std ### Summary This PR changes how bootstrap builds the stage 1 compiler by switching to precompiled stage 0 standard library instead of building the in-tree one. The goal was to update bootstrap to use the beta standard library at stage 0 rather than compiling it from source (see the motivation at rust-lang/compiler-team#619). Previously, to build a stage 1 compiler bootstrap followed this path: ``` download stage0 compiler -> build in-tree std -> compile stage1 compiler with in-tree std ``` With this PR, the new path is: ``` download stage0 compiler -> compile stage1 compiler with precompiled stage0 std ``` This also means that `cfg(bootstrap)`/`cfg(not(bootstrap))` is no longer needed for library development. ### Building "library" Since stage0 `std` is no longer in-tree `x build/test/check library --stage 0` is now no-op. The minimum supported stage to build `std` is now 1. For the same reason, default stage values in the library profile is no longer 0. Because building the in-tree library now requires a stage1 compiler, I highly recommend library developers to enable `download-rustc` to speed up compilation time. <hr> If you encounter a bug or unexpected results please open a topic in the [#t-infra/bootstrap](https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap) Zulip channel or create a [bootstrap issue](https://github.com/rust-lang/rust/issues/new?template=bootstrap.md). (Review thread: https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Review.20thread.3A.20stage.200.20redesign.20PR/with/508271433) ~~Blocked on rust-lang#122709 try-job: dist-x86_64-linux
☀️ Try build successful - checks-actions |
It worked, nice :) @rustbot ready |
std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
Rollup merge of rust-lang#139107 - joboet:safe_cmath, r=ibraheemdev std: make `cmath` functions safe The floating point intrinsics are more difficult, I'll probably wait until rust-lang#119899 has merged before making them safe as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just learned about compiletest-use-stage0-libtest
. Does this PR make true
the default value for that? It seems like there's no good reason to even still support false
for that option, or is there?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems like there's no good reason to even still support false for that option, or is there?
true
might make sense as a default (since libtest programmatic API changes relatively unfrequently), but if someone is working on a libtest
(programmatic API) change that can require changing compiletest
, in which case the contributor would probably want to use false
so that they can test their changes for compiletest too.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I just learned about
compiletest-use-stage0-libtest
. Does this PR maketrue
the default value for that? It seems like there's no good reason to even still supportfalse
for that option, or is there?
The default value for that option is already true
and false
is useful to detect breaking changes from libtest to compiletest. Currently we run x check compiletest
with compiletest-use-stage0-libtest=false
on couple of CI runners to prevent that.
The default value for that option is already true
Ah, that part was not clear to me, thanks. :)
(Sorry for not replying in-thread, github reply-by-mail does not support that.)
|
Summary
This PR changes how bootstrap builds the stage 1 compiler by switching to precompiled stage 0 standard library instead of building the in-tree one. The goal was to update bootstrap to use the beta standard library at stage 0 rather than compiling it from source (see the motivation at rust-lang/compiler-team#619).
Previously, to build a stage 1 compiler bootstrap followed this path:
With this PR, the new path is:
This also means that
cfg(bootstrap)
/cfg(not(bootstrap))
is no longer needed for library development.Building "library"
Since stage0
std
is no longer in-treex build/test/check library --stage 0
is now no-op. The minimum supported stage to buildstd
is now 1. For the same reason, default stage values in the library profile is no longer 0.Because building the in-tree library now requires a stage1 compiler, I highly recommend library developers to enable
download-rustc
to speed up compilation time.If you encounter a bug or unexpected results please open a topic in the #t-infra/bootstrap Zulip channel or create a bootstrap issue.
(Review thread: https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Review.20thread.3A.20stage.200.20redesign.20PR/with/508271433)
Blocked on #122709try-job: dist-x86_64-linux