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

Verify signature of start lang item #105963

Closed
bjorn3 opened this issue Dec 20, 2022 · 2 comments · Fixed by #106092
Closed

Verify signature of start lang item #105963

bjorn3 opened this issue Dec 20, 2022 · 2 comments · Fixed by #106092
Assignees
Labels
A-cranelift Things relevant to the [future] cranelift backend A-lang-item Area: Language items T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.

Comments

@bjorn3
Copy link
Member

bjorn3 commented Dec 20, 2022

In https://github.com/bjorn3/rustc_codegen_cranelift/issues/1329 it was found if the signature of the start lang item is wrong, rustc with the LLVM backend will silently compile it despite the ABI mismatch. Cg_clif crashes entirely. To avoid both issues rustc should validate the signature.

@bjorn3 bjorn3 added T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. A-lang-item Area: Language items labels Dec 20, 2022
@bjorn3 bjorn3 added the A-cranelift Things relevant to the [future] cranelift backend label Dec 20, 2022
@asquared31415
Copy link
Contributor

@rustbot claim

I have attempted to do this in the past (and never ended up finishing it), but I was not aware of the mentioned sigpipe: u8 argument. Where would I find information on that?

@bjorn3
Copy link
Member Author

bjorn3 commented Dec 20, 2022

#97802 is the PR that added it.

compiler-errors added a commit to compiler-errors/rust that referenced this issue Jan 9, 2023
…ks, r=davidtwco

Add checks for the signature of the `start` lang item

Closes rust-lang#105963
@bors bors closed this as completed in 4a04f25 Jan 13, 2023
flip1995 pushed a commit to flip1995/rust that referenced this issue Jan 27, 2023
…, r=davidtwco

Add checks for the signature of the `start` lang item

Closes rust-lang#105963
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-cranelift Things relevant to the [future] cranelift backend A-lang-item Area: Language items T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants