Skip to content

Commit 7931209

Browse files
committed
Mention RalfJung's view of stages
1 parent 0449ebd commit 7931209

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/building/bootstrapping.md

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,15 @@ If this used `run-stage` instead, you'd need `x.py build --stage 1` to build
8787
a regular program, but `x.py build --stage 2 src/librustc_driver` to build a
8888
custom driver.
8989

90+
### Are there other ways to think about stages?
91+
92+
Yes! The above explanation focuses on what `rustc` is being _referred_ to -
93+
it describes `build --stage 1 src/rustc` as `build-stage` 1 and `run-stage 2`.
94+
However, another way to think about it is that `--stage 1` refers to
95+
the compiler _being run_, so `build --stage 1 src/rustc` means to _run_
96+
`stage1/rustc` on the `src/rustc` crate. This can be slightly more confusing
97+
at first, but leads to a more consistent view of 'stage'.
98+
9099
## Complications of bootstrapping
91100

92101
Since the build system uses the current beta compiler to build the stage-1

0 commit comments

Comments
 (0)