Skip to content
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

Rollup of 7 pull requests #135509

Closed
wants to merge 21 commits into from

Conversation

matthiaskrgr
Copy link
Member

Successful merges:

r? @ghost
@rustbot modify labels: rollup

Create a similar rollup

Flakebi and others added 21 commits January 2, 2025 22:42
It was reverted in commit f6b21e9 due
to inactivity in the amdgpu target.

Rename the original enum value from `AmdGpuKernel` to `AmdgpuKernel`,
which is more consistent with `amdgpu-kernel`.
A clone-like function in a function that takes as an argument the type
that it returns.

However, functions that return a type variable are not counted as
clone-line. Because we're not unifying the whole function at once,
a function like `U -> T` would otherwise be counted as "clone-like"
because the generics will just unify with anything when done seperatly.

Co-authored-by: Michael Howell <[email protected]>
gpu-kernel translates to ptx_kernel or amdgpu_kernel, depending on the
target.
Make sure to scrape region constraints from deeply normalizing type outlives assumptions in borrowck

Otherwise we're just randomly registering these region relations into the infcx which isn't good

r? lcnr
…gjubilee

Add gpu-kernel calling convention

The amdgpu-kernel calling convention was reverted in commit f6b21e9 (rust-lang#120495 and rust-lang/rust-analyzer#16463) due to inactivity in the amdgpu target.

Introduce a `gpu-kernel` calling convention that translates to `ptx_kernel` or `amdgpu_kernel`, depending on the target that rust compiles for.

Tracking issue: rust-lang#135467
amdgpu target tracking issue: rust-lang#135024
…atch, r=BoxyUwU

Improve `DispatchFromDyn` and `CoerceUnsized` impl validation

* Disallow arbitrary 1-ZST fields in `DispatchFromDyn` -- only `PhantomData`, and 1-ZSTs that mention no params (which is needed to support, e.g., the `Global` alloctor in `Box<T, U = Global>`).
* Don't allow coercing between non-ZSTs to ZSTs (since the previous check wasn't actually checking the field tys were the same before checking the layout...)
* Normalize the field before checking it's `PhantomData`.

Fixes rust-lang#135215
Fixes rust-lang#135214
Fixes rust-lang#135220

r? ``@BoxyUwU`` or reassign
…rrors, r=oli-obk

Consider more erroneous layouts as `LayoutError::ReferencesError` to suppress spurious errors

Fixes rust-lang#135208

r? oli-obk
…-sort-134935, r=notriddle

for purely return-type based searches, deprioritize clone-like functions

closes rust-lang#134935
…r=lcnr

Make sure we can produce `ConstArgHasWrongType` errors for valtree consts

I forgot about `ty::ConstKind::Value` in rust-lang#134771.

The error message here could use some work -- both in the new trait solver and the old trait solver. But unrelated to the issue here.

Fixes rust-lang#135361 -- this was only ICEing in coherence because coherence uses the new trait solver, but I don't think the minimization is worth committing compared to the test I added.

r? ``@lcnr`` or ``@BoxyUwU``
…const, r=RalfJung

Do not consider traits that have unsatisfied const conditions to be conditionally const

This will improve error messages as we continue to constify traits, since we don't want to start calling things "conditionally const" if they aren't implemented with a const impl anyways.

The only case that this affects today is `Deref` since that's one of the only constified traits in the standard library :)

r? RalfJung
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver) rollup A PR which is a rollup labels Jan 14, 2025
@matthiaskrgr
Copy link
Member Author

@bors r+ rollup=never p=5

@bors
Copy link
Contributor

bors commented Jan 14, 2025

📌 Commit d0fb971 has been approved by matthiaskrgr

It is now in the queue for this repository.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 14, 2025
@bors
Copy link
Contributor

bors commented Jan 15, 2025

⌛ Testing commit d0fb971 with merge d5e900b...

bors added a commit to rust-lang-ci/rust that referenced this pull request Jan 15, 2025
…iaskrgr

Rollup of 7 pull requests

Successful merges:

 - rust-lang#134940 (Make sure to scrape region constraints from deeply normalizing type outlives assumptions in borrowck)
 - rust-lang#135047 (Add gpu-kernel calling convention)
 - rust-lang#135228 (Improve `DispatchFromDyn` and `CoerceUnsized` impl validation)
 - rust-lang#135264 (Consider more erroneous layouts as `LayoutError::ReferencesError` to suppress spurious errors)
 - rust-lang#135302 (for purely return-type based searches, deprioritize clone-like functions)
 - rust-lang#135380 (Make sure we can produce `ConstArgHasWrongType` errors for valtree consts)
 - rust-lang#135425 (Do not consider traits that have unsatisfied const conditions to be conditionally const)

r? `@ghost`
`@rustbot` modify labels: rollup
@rust-log-analyzer
Copy link
Collaborator

The job aarch64-apple failed! Check out the build log: (web) (plain)

Click to see the possible cause of the failure (guessed by this bot)
test [ui] tests/ui/self/conflicting_inner.rs#default ... ok
test [ui] tests/ui/self/conflicting_inner.rs#feature ... ok
test [ui] tests/ui/self/conflicting_inner2.rs#default ... ok
test [ui] tests/ui/self/builtin-superkinds-self-type.rs ... ok
test [ui] tests/ui/self/dispatch-from-dyn-zst-transmute-zst-nonzst.rs ... ok
test [ui] tests/ui/self/dispatch-from-dyn-zst-transmute.rs ... ok
test [ui] tests/ui/self/dyn-compatibility-sized-self-by-value-self.rs ... ok
test [ui] tests/ui/self/dyn-compatibility-sized-self-generic-method.rs ... ok
test [ui] tests/ui/self/elision/alias-async.rs ... ok
test [ui] tests/ui/self/elision/alias.rs ... ok

@bors
Copy link
Contributor

bors commented Jan 15, 2025

💔 Test failed - checks-actions

@bors bors added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. labels Jan 15, 2025
@matthiaskrgr matthiaskrgr deleted the rollup-4ua3iix branch January 25, 2025 09:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
rollup A PR which is a rollup S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. WG-trait-system-refactor The Rustc Trait System Refactor Initiative (-Znext-solver)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants