| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
|
|
There is no safety contract and I don't think any of them can actually
cause UB in more ways than passing malicious source code to rustc can.
While LtoModuleCodegen::optimize says that the returned ModuleCodegen
points into the LTO module, the LTO module has already been dropped by
the time this function returns, so if the returned ModuleCodegen indeed
points into the LTO module, we would have seen crashes on every LTO
compilation, which we don't. As such the comment is outdated.
|
|
|
|
|
|
It is only relevant when using cg_ssa for driving compilation.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Now that we have work queue limits on triagebot, I'm happy to share some
of the review load.
|
|
Rollup of 7 pull requests
Successful merges:
- rust-lang/rust#140369 (Add data_ptr method to Mutex and RwLock)
- rust-lang/rust#140697 (Split `autodiff` into `autodiff_forward` and `autodiff_reverse`)
- rust-lang/rust#141404 (Improve intrinsic handling in cg_ssa)
- rust-lang/rust#141411 (rustdoc: linking to a local proc macro no longer warns)
- rust-lang/rust#141548 (consider glob imports in cfg suggestion)
- rust-lang/rust#141627 (Drop-build cleanups)
- rust-lang/rust#141670 (Fix ICE in tokenstream with contracts from parser recovery)
r? `@ghost`
`@rustbot` modify labels: rollup
|
|
|
|
|
|
r=nnethercote
Fix ICE in tokenstream with contracts from parser recovery
Fixes rust-lang/rust#140683
After two times of parsing error, the `recover_stmt_` constructs an error ast, then when we expand macors, the invalid tokenstream triggered ICE because of mismatched delims.
Expected `{` and get other tokens is an obvious error message, too much effort on recovery may introduce noise.
r? ```@nnethercote```
|
|
Drop-build cleanups
Some cleanups I made while trying to speed up the program in rust-lang/rust#134404.
r? ```@matthewjasper```
|
|
consider glob imports in cfg suggestion
Fixes rust-lang/rust#141256
r? ```@petrochenkov```
|
|
r=GuillaumeGomez
rustdoc: linking to a local proc macro no longer warns
fixes https://github.com/rust-lang/rust/issues/91274
tried to keep the fix general in case we ever have any other kind of item that occupies
multiple namespaces simultaniously.
|
|
Improve intrinsic handling in cg_ssa
* Move all intrinsic handling code to the start of `codegen_call_terminator`.
* Push some intrinsic handling code into `codegen_intrinsic_call`.
* Don't depend on FnAbi for intrinsics.
|
|
Split `autodiff` into `autodiff_forward` and `autodiff_reverse`
This PR splits `#[autodiff]` macro so `#[autodiff(df, Reverse, args)]` would become `#[autodiff_reverse(df, args)]` and `#[autodiff(df, Forward, args)]` would become `#[autodiff_forwad(df, args)]`.
|
|
Add data_ptr method to Mutex and RwLock
Implementation of https://github.com/rust-lang/rust/issues/140368 / https://github.com/rust-lang/libs-team/issues/531.
I tried to write a useful safety section about when it is safe to read or write through the returned pointers, but couldn't come up with something nice. Hoping this PR is still useful without that. I'm happy to add any doc strings other people come up with if needed before merge, of course.
Unresolved questions:
- Return a `LockResult` or not?
- Return `*mut T` like existing APIs (`Cell::as_ptr` / `MaybeUninit::as[_mut]_ptr` / `Vec::as_ptr` / ...) or be more precise and return `NonNull<T>`?
|
|
ci: move tests from x86_64-gnu-llvm-19 job to aarch64
|
|
|
|
|
|
|
|
|
|
|
|
This fixes the build on GCC 15
|
|
|
|
|
|
|
|
Would otherwise fail on:
```
thread 'fs::tests::test_eq_windows_file_type' panicked at library/std/src/test_helpers.rs:53:20:
called `Result::unwrap()` on an `Err` value: Os { code: 5, kind: PermissionDenied, message: "Access is denied." }
```
This came from the read-only attribute set on the test file. In order to
fix this, instead of simply disabling the test, the attribute is reset
before the test's end so it may still run successfully.
Signed-off-by: Paul Mabileau <paul.mabileau@harfanglab.fr>
|
|
|
|
feat: Desugar assist for `let pat = expr?;` -> `let else`
|
|
|
|
ci: move dist-x86_64-linux job to codebuild
|
|
fix: Handle included files better in IDE layer
|
|
fix: Fix inference of `AsyncFnX` return type
|
|
This does not fully fix things, but it introduces a function that can be used to fix occurences.
When using `to_def` functionality, the input node needs to come from the macro expanded include, not the real file that was included.
This does unfortunately add more caller burden, but there is not really a way around it.
|
|
|
|
feat: Render padding information when hovering on structs
|
|
There is an LLVM bug with lowering of basic `f16` operations that mean a
round trip via `__extendhfsf2` and `__truncsfhf2` may happen for simple
`abs` calls or bitcasts [1]. This is problematic because the round trip
quiets signaling NaNs. For most operations this is acceptable, but it is
causing `total_cmp` tests to fail unless optimizations are enabled.
Disable `total_cmp` tests involving signaling NaNs until this issue is
resolved.
Fixes: https://github.com/rust-lang/rustc_codegen_cranelift/issues/1578
Fixes: https://github.com/rust-lang/rust/issues/141503
[1]: https://github.com/llvm/llvm-project/issues/104915
|
|
|
|
|
|
Disable libunwind cross-architecture unwinding
Building with _LIBUNWIND_IS_NATIVE_ONLY disables code for cross-architecture unwinding It also enables some additional code that handles PAC-specific unwind info it helps compiling with the -mbranch-protection=pac or -mbranch-protection=standard flags
This fixes build with clang/musl on aarch64
|
|
So they match the order of the parts in the source code, e.g.:
```
struct Foo<T, U> { t: T, u: U }
<-><----> <------------>
/ | \
ident generics variant_data
```
|
|
fix: Fix IDE layer not resolving some macro calls
|