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

Cleanup and document -C code-model #72248

Merged
merged 2 commits into from
May 18, 2020
Merged

Conversation

petrochenkov
Copy link
Contributor

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label May 15, 2020
@rust-highfive

This comment has been minimized.

Copy link
Member

@Amanieu Amanieu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r=me


Supported values for this option are:

<!-- - `tiny` - Tiny code model. -->
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason why we don't expose the tiny code model to users? AFAIK it's only available on AArch64 where it assumes all symbols are within 1MB of each other.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As I understand, it was simply introduced to LLVM later than the code-model option had been implemented in rustc.

I'll make a separate PR exposing it, I didn't want to do it in a "cleanup and document" PR.

@petrochenkov
Copy link
Contributor Author

@bors r=Amanieu

@bors
Copy link
Contributor

bors commented May 16, 2020

📌 Commit 59187f9 has been approved by Amanieu

@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 16, 2020
RalfJung added a commit to RalfJung/rust that referenced this pull request May 17, 2020
@bors
Copy link
Contributor

bors commented May 17, 2020

⌛ Testing commit 59187f9 with merge 5f47281...

@bors
Copy link
Contributor

bors commented May 18, 2020

☀️ Test successful - checks-azure
Approved by: Amanieu
Pushing 5f47281 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label May 18, 2020
@bors bors merged commit 5f47281 into rust-lang:master May 18, 2020
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request May 20, 2020
llvm: Expose tiny code model to users

This model is relevant to embedded AArch64 targets and was added to LLVM relatively recently (https://reviews.llvm.org/D49673, mid 2018), so rustc frontend didn't provide access to it with `-C code-model`. The gcc analogue is [`-mcmodel=tiny`](https://gcc.gnu.org/onlinedocs/gcc/AArch64-Options.html).
(This is one of the options that are passed directly to LLVM without being interpreted by rustc.)

Follow up to rust-lang#72248.
RalfJung added a commit to RalfJung/rust that referenced this pull request May 21, 2020
llvm: Expose tiny code model to users

This model is relevant to embedded AArch64 targets and was added to LLVM relatively recently (https://reviews.llvm.org/D49673, mid 2018), so rustc frontend didn't provide access to it with `-C code-model`. The gcc analogue is [`-mcmodel=tiny`](https://gcc.gnu.org/onlinedocs/gcc/AArch64-Options.html).
(This is one of the options that are passed directly to LLVM without being interpreted by rustc.)

Follow up to rust-lang#72248.
RalfJung added a commit to RalfJung/rust that referenced this pull request May 21, 2020
llvm: Expose tiny code model to users

This model is relevant to embedded AArch64 targets and was added to LLVM relatively recently (https://reviews.llvm.org/D49673, mid 2018), so rustc frontend didn't provide access to it with `-C code-model`. The gcc analogue is [`-mcmodel=tiny`](https://gcc.gnu.org/onlinedocs/gcc/AArch64-Options.html).
(This is one of the options that are passed directly to LLVM without being interpreted by rustc.)

Follow up to rust-lang#72248.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants