Skip to content

Commit ec8d049

Browse files
Alex Kitchensmark-i-m
authored andcommitted
Rename trans to codegen
This commit is a followup of changes from [b63d7e2b1c4019e40051036bcb1fd5f254a8f6e2](rust-lang/rust@b63d7e2#diff-b433c87466d984aa7eeded378ea6c392) in the Rust source to rename trans to codegen.
1 parent 7bf9416 commit ec8d049

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

src/SUMMARY.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@
5353
- [Constant evaluation](./const-eval.md)
5454
- [miri const evaluator](./miri.md)
5555
- [Parameter Environments](./param_env.md)
56-
- [Generating LLVM IR](./trans.md)
56+
- [Generating LLVM IR](./codegen.md)
5757
- [Emitting Diagnostics](./diag.md)
5858

5959
---

src/appendix/glossary.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ IR | Intermediate Representation. A general term in compil
3535
local crate | the crate currently being compiled.
3636
LTO | Link-Time Optimizations. A set of optimizations offered by LLVM that occur just before the final binary is linked. These include optmizations like removing functions that are never used in the final program, for example. _ThinLTO_ is a variant of LTO that aims to be a bit more scalable and efficient, but possibly sacrifices some optimizations. You may also read issues in the Rust repo about "FatLTO", which is the loving nickname given to non-Thin LTO. LLVM documentation: [here][lto] and [here][thinlto]
3737
[LLVM] | (actually not an acronym :P) an open-source compiler backend. It accepts LLVM IR and outputs native binaries. Various languages (e.g. Rust) can then implement a compiler front-end that output LLVM IR and use LLVM to compile to all the platforms LLVM supports.
38-
MIR | the Mid-level IR that is created after type-checking for use by borrowck and trans ([see more](./mir/index.html))
38+
MIR | the Mid-level IR that is created after type-checking for use by borrowck and codegen ([see more](./mir/index.html))
3939
miri | an interpreter for MIR used for constant evaluation ([see more](./miri.html))
4040
normalize | a general term for converting to a more canonical form, but in the case of rustc typically refers to [associated type normalization](./traits/associated-types.html#normalize)
4141
newtype | a "newtype" is a wrapper around some other type (e.g., `struct Foo(T)` is a "newtype" for `T`). This is commonly used in Rust to give a stronger type for indices.
@@ -61,7 +61,7 @@ tcx | the "typing context", main data structure of the comp
6161
trait reference | the name of a trait along with a suitable set of input type/lifetimes ([see more](./traits/goals-and-clauses.html#trait-ref))
6262
token | the smallest unit of parsing. Tokens are produced after lexing ([see more](the-parser.html)).
6363
[TLS] | Thread-Local Storage. Variables may be defined so that each thread has its own copy (rather than all threads sharing the variable). This has some interactions with LLVM. Not all platforms support TLS.
64-
trans | the code to translate MIR into LLVM IR.
64+
codegen | the code to translate MIR into LLVM IR.
6565
trait reference | a trait and values for its type parameters ([see more](ty.html)).
6666
ty | the internal representation of a type ([see more](ty.html)).
6767
UFCS | Universal Function Call Syntax. An unambiguous syntax for calling a method ([see more](type-checking.html)).
File renamed without changes.

src/high-level-overview.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ standard library and the compiler. This document, of course, focuses
88
on the latter.
99

1010
Rustc consists of a number of crates, including `syntax`,
11-
`rustc`, `rustc_back`, `rustc_trans`, `rustc_driver`, and
11+
`rustc`, `rustc_back`, `rustc_codegen`, `rustc_driver`, and
1212
many more. The source for each crate can be found in a directory
1313
like `src/libXXX`, where `XXX` is the crate name.
1414

@@ -25,7 +25,7 @@ The dependency structure of these crates is roughly a diamond:
2525
/ | \
2626
/ | \
2727
/ v \
28-
rustc_trans rustc_borrowck ... rustc_metadata
28+
rustc_codegen rustc_borrowck ... rustc_metadata
2929
\ | /
3030
\ | /
3131
\ | /

0 commit comments

Comments
 (0)