-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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 #115469
Rollup of 7 pull requests #115469
Conversation
On native builds `llvm-config` picks up `zlib` and this gets pased into the rust build tools, but on cross builds `llvm-config` is explicitly ignored as it contains information for the host system and cannot be trusted to be accurate for the target system. Both DragonFly and Solaris contain `zlib` in the base system, so this is both a safe assumption and required for a successful cross build unless `zlib` support is disabled in LLVM. This is more or less in the same vein as rust-lang#75713 and rust-lang#75655.
As far as I know, this is always true already, but it's not in the text of the Option module docs, so I figured I'd bring this up to FCP it.
…olid::is_interrupted`
…-libz, r=cuviper rustc_llvm: Link to `zlib` on dragonfly and solaris On native builds `llvm-config` picks up `zlib` and this gets pased into the rust build tools, but on cross builds `llvm-config` is explicitly ignored as it contains information for the host system and cannot be trusted to be accurate for the target system. Both DragonFly and Solaris contain `zlib` in the base system, so this is both a safe assumption and required for a successful cross build unless `zlib` support is disabled in LLVM. This is more or less in the same vein as rust-lang#75713 and rust-lang#75655.
Add alignment to the NPO guarantee This PR [changes](rust-lang#114845 (comment)) "same size" to "same size and alignment" in the option module's null pointer optimization docs in <https://doc.rust-lang.org/std/option/#representation>. As far as I know, this has been true for a long time in the actual rustc implementation, but it's not in the text of those docs, so I figured I'd bring this up to FCP it. I also see no particular reason that we'd ever *want* to have higher alignment on these. In many of the cases it's impossible, as the minimum alignment is already the size of the type, but even if we *could* do things like on 32-bit we could say that `NonZeroU64` is 4-align but `Option<NonZeroU64>` is 8-align, I just don't see any value in doing that, so feel completely fine closing this door for the few things on which the NPO is already guaranteed. These are basically all primitives, and should end up with the same size & alignment as those primitives. (There's no layout guarantee for something like `Option<[u8; 3]>`, where it'd be at least plausible to consider raising the alignment from 1 to 4 on, say, some hypothetical target that doesn't have efficient unaligned 4-byte load/stores. And even if we ever did start to offer some kind of guarantee around such a type, I doubt we'd put it under the "null pointer" optimization header.) Screenshots for the new examples: ![image](https://github.com/rust-lang/rust/assets/18526288/a7dbff42-50b4-462e-9e27-00d511b58763) ![image](https://github.com/rust-lang/rust/assets/18526288/dfd55288-80fb-419a-bc11-26198c27f9f9)
…upted, r=cuviper kmc-solid: Fix `is_interrupted` Follow-up to rust-lang#115228. Fixes a build error in [`*-kmc-solid_*`](https://doc.rust-lang.org/nightly/rustc/platform-support/kmc-solid.html) Tier 3 targets. ``` error[E0603]: function `is_interrupted` is private --> library\std\src\sys\solid\mod.rs:77:12 | 77 | error::is_interrupted(code) | ^^^^^^^^^^^^^^ private function | note: the function `is_interrupted` is defined here --> library\std\src\sys\solid\error.rs:35:1 | 35 | fn is_interrupted(er: abi::ER) -> bool { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ```
feat(std): Stabilize 'os_str_bytes' feature Closes rust-lang#111544
Create a SMIR visitor r? ``@spastorino`` Doesn't have tests or examples yet, but I think we could land it and implement it for the rest of the types.
…ChrisDenton Const-stabilize `is_ascii` Resolves rust-lang#111090 FCP completed in rust-lang#111090 (comment)
…spastorino Add spastorino on vacation
@bors r+ rollup=never p=7 |
☀️ Test successful - checks-actions |
📌 Perf builds for each rolled up PR:
previous master: 1fb6947abc In the case of a perf regression, run the following command for each PR you suspect might be the cause: |
Finished benchmarking commit (ad8f601): comparison URL. Overall result: no relevant changes - no action needed@rustbot label: -perf-regression Instruction countThis benchmark run did not return any relevant results for this metric. Max RSS (memory usage)ResultsThis is a less reliable metric that may be of interest but was not used to determine the overall result at the top of this comment.
CyclesThis benchmark run did not return any relevant results for this metric. Binary sizeThis benchmark run did not return any relevant results for this metric. Bootstrap: 627.894s -> 628.825s (0.15%) |
Successful merges:
zlib
on dragonfly and solaris #114349 (rustc_llvm: Link tozlib
on dragonfly and solaris)is_interrupted
#115427 (kmc-solid: Fixis_interrupted
)is_ascii
#115449 (Const-stabilizeis_ascii
)r? @ghost
@rustbot modify labels: rollup
Create a similar rollup