Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
d255962
Auto merge of #147392 - tshepang:rdg-sync, r=tshepang
bors Oct 6, 2025
02c7c42
Rollup merge of #146874 - Enselic:multiple-adt-versions, r=jieyouxu
Zalathar Oct 6, 2025
b49485d
Rollup merge of #147237 - yotamofek:pr/rustdoc/highlight/optimize-end…
Zalathar Oct 6, 2025
541164f
Auto merge of #147397 - Zalathar:rollup-mioe9m4, r=Zalathar
bors Oct 6, 2025
80266a7
Auto merge of #144477 - cjgillot:gvn-index, r=dianqk
bors Oct 6, 2025
34839e1
Auto merge of #147099 - cjgillot:split-nop-landing, r=lcnr
bors Oct 7, 2025
4b2448d
Auto merge of #145608 - Darksonn:derefmut-pin-fix, r=lcnr
bors Oct 7, 2025
306e213
Auto merge of #147423 - nnethercote:DepNodeColor-tweaks, r=cjgillot
bors Oct 8, 2025
9bd6516
Auto merge of #143227 - tshepang:asm-label-operand, r=Amanieu
bors Oct 9, 2025
4e52541
Auto merge of #147124 - a1phyr:improve_finish_grow, r=Mark-Simulacrum
bors Oct 11, 2025
fc3da91
update movepath docs
beepster4096 Oct 10, 2025
6c47a42
Auto merge of #146096 - adwinwhite:handle_normalization_overflow_in_m…
bors Oct 13, 2025
89afab6
Auto merge of #147353 - the8472:nondrop-array-iter, r=scottmcm
bors Oct 14, 2025
3f75b40
Auto merge of #146221 - camsteffen:ast-boxes, r=cjgillot
bors Oct 16, 2025
8219fc1
Auto merge of #147508 - nnethercote:TaskDeps-improvements, r=saethlin
bors Oct 17, 2025
ac94a0a
Auto merge of #146913 - camsteffen:refactor-lint-syntax, r=fee1-dead
bors Oct 18, 2025
a53aa39
Rollup merge of #147575 - beepster4096:movesubpath, r=oli-obk
matthiaskrgr Oct 19, 2025
b7c71cc
Rollup merge of #147864 - fee1-dead-contrib:consttraitparse, r=fmease
matthiaskrgr Oct 19, 2025
cc7632e
Rollup merge of #147868 - cjgillot:patch-local, r=saethlin
matthiaskrgr Oct 19, 2025
16cf6e2
Rollup merge of #147873 - RalfJung:deduce_param_attrs, r=tmiasko
matthiaskrgr Oct 19, 2025
9e3b484
Auto merge of #147884 - matthiaskrgr:rollup-pjqcccz, r=matthiaskrgr
bors Oct 19, 2025
1393995
update autodiff docs in the dev guide
ZuseZ4 Oct 19, 2025
db31cae
Auto merge of #147812 - RalfJung:more-minicore, r=jieyouxu
bors Oct 19, 2025
db4a6df
Auto merge of #142696 - ZuseZ4:offload-device1, r=oli-obk
bors Oct 20, 2025
04b8bbc
Rollup merge of #147734 - fmease:tighten-relaxed, r=lcnr
Zalathar Oct 20, 2025
de39eda
Rollup merge of #147888 - ZuseZ4:autodiff-with-download-ci, r=jieyouxu
Zalathar Oct 20, 2025
d395121
Rollup merge of #147898 - Zalathar:aux-props, r=jieyouxu
Zalathar Oct 20, 2025
a7e7502
Rollup merge of #147903 - Zalathar:edition, r=jieyouxu
Zalathar Oct 20, 2025
e9b0a1e
Auto merge of #147906 - Zalathar:rollup-2wik61l, r=Zalathar
bors Oct 20, 2025
3dfd68a
Rollup merge of #147577 - JohnTitor:issue-147312, r=davidtwco
matthiaskrgr Oct 20, 2025
5f1c16f
Rollup merge of #147785 - relaxcn:emitter_sugg_line, r=petrochenkov
matthiaskrgr Oct 20, 2025
db4d6e0
Rollup merge of #147814 - hkBst:btree-4, r=joboet
matthiaskrgr Oct 20, 2025
518aa74
Rollup merge of #147843 - bjorn3:tidy_licenses, r=clubby789
matthiaskrgr Oct 20, 2025
da574cb
Auto merge of #147913 - matthiaskrgr:rollup-lmm3dsh, r=matthiaskrgr
bors Oct 20, 2025
a32194b
Prepare for merging from rust-lang/rust
invalid-email-address Oct 20, 2025
1a9a858
Merge ref '4068bafedd8b' from rust-lang/rust
invalid-email-address Oct 20, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion rust-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
4fa824bb78318a3cba8c7339d5754b4909922547
4068bafedd8ba724e332a5221c06a6fa531a30d2
2 changes: 1 addition & 1 deletion src/autodiff/debugging.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ The actual numbers will depend on your code.

## 2) Check your llvm-ir reproducer

To confirm that your previous step worked, we will use llvm's `opt` tool. find your path to the opt binary, with a path similar to `<some_dir>/rust/build/<x86/arm/...-target-triple>/build/bin/opt`. also find `llvmenzyme-19.<so/dll/dylib>` path, similar to `/rust/build/target-triple/enzyme/build/enzyme/llvmenzyme-19`. Please keep in mind that llvm frequently updates it's llvm backend, so the version number might be higher (20, 21, ...). Once you have both, run the following command:
To confirm that your previous step worked, we will use llvm's `opt` tool. Find your path to the opt binary, with a path similar to `<some_dir>/rust/build/<x86/arm/...-target-triple>/ci-llvm/bin/opt`. If you build LLVM from source, you'll likely need to replace `ci-llvm` with `build`. Also find `llvmenzyme-21.<so/dll/dylib>` path, similar to `/rust/build/target-triple/enzyme/build/enzyme/llvmenzyme-21`. Please keep in mind that llvm frequently updates it's llvm backend, so the version number might be higher (20, 21, ...). Once you have both, run the following command:

```sh
<path/to/opt> out.ll -load-pass-plugin=/path/to/build/<target-triple>/stage1/lib/libEnzyme-21.so -passes="enzyme" -enzyme-strict-aliasing=0 -s
Expand Down
6 changes: 3 additions & 3 deletions src/autodiff/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ First you need to clone and configure the Rust repository:
```bash
git clone [email protected]:rust-lang/rust
cd rust
./configure --enable-llvm-link-shared --enable-llvm-plugins --enable-llvm-enzyme --release-channel=nightly --enable-llvm-assertions --enable-clang --enable-lld --enable-option-checking --enable-ninja --disable-docs
./configure --release-channel=nightly --enable-llvm-enzyme --enable-llvm-assertions --enable-option-checking --disable-docs --set llvm.download-ci-llvm=true
```

Afterwards you can build rustc using:
Expand Down Expand Up @@ -47,7 +47,7 @@ Then build rustc in a slightly altered way:
```bash
git clone https://github.com/rust-lang/rust
cd rust
./configure --enable-llvm-link-shared --enable-llvm-plugins --enable-llvm-enzyme --release-channel=nightly --enable-llvm-assertions --enable-clang --enable-lld --enable-option-checking --enable-ninja --disable-docs
./configure --release-channel=nightly --enable-llvm-enzyme --enable-llvm-assertions --enable-option-checking --disable-docs --set llvm.download-ci-llvm=true
./x dist
```
We then copy the tarball to our host. The dockerid is the newest entry under `docker ps -a`.
Expand Down Expand Up @@ -84,5 +84,5 @@ cd build
cmake .. -G Ninja -DLLVM_DIR=<YourLocalPath>/llvm-project/build/lib/cmake/llvm/ -DLLVM_EXTERNAL_LIT=<YourLocalPath>/llvm-project/llvm/utils/lit/lit.py -DCMAKE_BUILD_TYPE=Release -DCMAKE_EXPORT_COMPILE_COMMANDS=YES -DBUILD_SHARED_LIBS=ON
ninja
```
This will build Enzyme, and you can find it in `Enzyme/enzyme/build/lib/<LLD/Clang/LLVM>Enzyme.so`. (Endings might differ based on your OS).
This will build Enzyme, and you can find it in `Enzyme/enzyme/build/lib/<LLD/Clang/LLVM/lib>Enzyme.so`. (Endings might differ based on your OS).

14 changes: 12 additions & 2 deletions src/borrow_check/moves_and_initialization/move_paths.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,6 @@ We don't actually create a move-path for **every** [`Place`] that gets
used. In particular, if it is illegal to move from a [`Place`], then
there is no need for a [`MovePathIndex`]. Some examples:

- You cannot move from a static variable, so we do not create a [`MovePathIndex`]
for static variables.
- You cannot move an individual element of an array, so if we have e.g. `foo: [String; 3]`,
there would be no move-path for `foo[1]`.
- You cannot move from inside of a borrowed reference, so if we have e.g. `foo: &String`,
Expand All @@ -82,6 +80,18 @@ initialized (which lowers overhead).

[`move_path_for`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_dataflow/move_paths/builder/struct.MoveDataBuilder.html#method.move_path_for

## Projections

Instead of using [`PlaceElem`], projections in move paths are stored as [`MoveSubPath`]s.
Projections that can't be moved out of and projections that can be skipped are not represented.

Subslice projections of arrays (produced by slice patterns) are special; they're turned into
multiple [`ConstantIndex`] subpaths, one for each element in the subslice.

[`PlaceElem`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_middle/mir/type.PlaceElem.html
[`MoveSubPath`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_dataflow/move_paths/enum.MoveSubPath.html
[`ConstantIndex`]: https://doc.rust-lang.org/nightly/nightly-rustc/rustc_mir_dataflow/move_paths/enum.MoveSubPath.html#variant.ConstantIndex

## Looking up a move-path

If you have a [`Place`] and you would like to convert it to a [`MovePathIndex`], you
Expand Down