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

Miri call ABI check: ensure type size+align stay the same #97395

Merged
merged 1 commit into from
May 31, 2022

Conversation

RalfJung
Copy link
Member

We should almost certainly not accept calls where caller and callee disagree on the size or alignment of the type.

The checks we do almost imply that, except that ScalarPair types can have repr(align) and thus differ in size/align even when they are pairs of the same primitive type.

r? @oli-obk

@rustbot rustbot added the T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. label May 25, 2022
@rust-highfive
Copy link
Collaborator

Some changes occured to the CTFE / Miri engine

cc @rust-lang/miri

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 25, 2022
@rust-log-analyzer

This comment was marked as resolved.

@RalfJung

This comment was marked as resolved.

@oli-obk
Copy link
Contributor

oli-obk commented May 30, 2022

@bors r+ rollup

@bors
Copy link
Contributor

bors commented May 30, 2022

📌 Commit d7a2d9a has been approved by oli-obk

@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 May 30, 2022
compiler-errors added a commit to compiler-errors/rust that referenced this pull request May 30, 2022
Miri call ABI check: ensure type size+align stay the same

We should almost certainly not accept calls where caller and callee disagree on the size or alignment of the type.

The checks we do *almost* imply that, except that `ScalarPair` types can have `repr(align)` and thus differ in size/align even when they are pairs of the same primitive type.

r? `@oli-obk`
bors added a commit to rust-lang-ci/rust that referenced this pull request May 31, 2022
…piler-errors

Rollup of 6 pull requests

Successful merges:

 - rust-lang#89685 (refactor: VecDeques Iter fields to private)
 - rust-lang#97172 (Optimize the diagnostic generation for `extern unsafe`)
 - rust-lang#97395 (Miri call ABI check: ensure type size+align stay the same)
 - rust-lang#97431 (don't do `Sized` and other return type checks on RPIT's real type)
 - rust-lang#97555 (Source code page: line number click adds `NaN`)
 - rust-lang#97558 (Fix typos in comment)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit 12ba87b into rust-lang:master May 31, 2022
@rustbot rustbot added this to the 1.63.0 milestone May 31, 2022
@RalfJung RalfJung deleted the call-abi branch June 2, 2022 11:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants