Rollup of 16 pull requests#158953
Closed
GuillaumeGomez wants to merge 47 commits into
Closed
Conversation
None of the existing tests captured a case where non-terminal binds appeared differently ordered than their definition in their rule, so I wrote a test for it. The existing macro parsing code is quite resilient to this kind of mis-ordering; it took quite a convoluted macro to trigger a case where the ordering is incorrect today. I've documented the parse tree (based on my own mental model) that the convoluted macro causes.
The order of `bb_mps` and `next_mps` depends on arbitrary implementation choices, e.g. the order in which `$(a)? b` causes `a b` and `b` to be explored. To stop depending on these implementation details, this commit sorts `bb_mps` and `next_mps` by `mp.idx` (corresponding to the position in the rule) before presenting error messages. This makes it easier to refactor the macro parsing implementation.
Signed-off-by: Xiangfei Ding <dingxiangfei2009@protonmail.ch>
Storage is still required even if the local is moved out and immediately moved in again. Signed-off-by: Xiangfei Ding <dingxiangfei2009@protonmail.ch>
A recent change in InstSimplify is able to skip the `and` in this codegen, which is strictly an improvement. We accept the new version on newer LLVM and the old verison on older ones using the revisions system. The change in array-cmp.rs appears to have come from the same revision, so I gave it the same treatment. It's weirder to me though, because it merely changes the order of the phi operands which if I understand right doesn't actually matter.
Signed-off-by: Amirhossein Akhlaghpour <m9.akhlaghpoor@gmail.com>
Same as rust-lang/rust/147495, just keeping it up-to-date.
in `is_call_from_compiler_builtins_to_upstream_monomorphization`, suggested by Saethlin
We'll do this using `-Zforce-intrinsic-fallback` in the main repo going forward
A number of float operations from libm have intrinsics for optimization, but it is also okay to just call the libm functions directly. Add a fallback for these cases, including converting to/from another float size where needed, so the backends don't need to override these. We do not add a fallback body for intrinsics that have a softfloat implementation (e.g. sqrt, fma), because it would make them harder to constify later.
Emscripten targets wasm32 but provides a working POSIX fd layer, including fcntl(F_DUPFD_CLOEXEC) and dup2(), so it should use the real implementations rather than the wasm32 UNSUPPORTED_PLATFORM stubs: - try_clone_to_owned now uses fcntl(F_DUPFD_CLOEXEC) instead of returning UNSUPPORTED_PLATFORM - replace_stdio_fd now uses dup2() instead of the wasm32 fallback
CString::clone_into reuses the target's allocation by moving the buffer into a Vec and growing it. If that growth's allocation fails and the alloc error hook unwinds, the target has to be left as a valid CString, but nothing covered that path. Add a test in library/alloctests that fails the reallocation under a panicking alloc error hook and checks the target stays valid. The failing allocator is only honored under Miri - a global allocator in a library test doesn't intercept libstd's allocation in a normal build - so the unwind assertion is gated on cfg!(miri); the test still runs and passes as a regular test.
…thercote
Make the ordering of non-terminal binds in ambiguity error messages deterministic
My next PR will rework macro parsing to use a DFS approach instead of a BFS. It will change the order in which the parsing space is explored, and while this does not change the behavior of parsing in success cases, it did cause changes to some error messages; in particular, when an ambiguity error occurs, it would sometimes report non-terminal binds in a different order (e.g. in ```error: local ambiguity when calling macro `foo`: multiple parsing options: built-in NTs ident ('i') or ident ('j').```). I realized that the current macro parsing code does not enforce a particular order for those binds, so this PR 1) adds a test case for strange bind orderings and 2) makes the bind ordering deterministic (in line with the ordering of those binds in the macro definition, which was how binds tended to be ordered anyway).
Ideally reviewed commit-by-commit.
r? @nnethercote
…n-try-from, r=nnethercote add codegen test for range length bound propagation Closes rust-lang#114242
…est, r=jieyouxu Update `browser-ui-test` version to `0.24.1` Fixes rust-lang#157747. It includes GuillaumeGomez/browser-UI-test#749. Hopefully this flaky issue won't be anymore. r? @jieyouxu
…jhpratt std: support real fd methods on Emscripten Emscripten targets wasm32 but provides a working POSIX fd layer, including `fcntl(F_DUPFD_CLOEXEC)` and `dup2()`, so it should use the real implementations rather than the wasm32 `UNSUPPORTED_PLATFORM` stubs: - `try_clone_to_owned` now uses `fcntl(F_DUPFD_CLOEXEC)` instead of returning `UNSUPPORTED_PLATFORM` - `replace_stdio_fd` now uses `dup2()` instead of the `wasm32` fallback
Member
Author
|
@bors r+ p=5 rollup=never |
Contributor
Contributor
|
Trying commonly failed jobs |
This comment has been minimized.
This comment has been minimized.
rust-bors Bot
pushed a commit
that referenced
this pull request
Jul 8, 2026
Rollup of 16 pull requests try-job: dist-various-1 try-job: test-various try-job: x86_64-gnu-aux try-job: x86_64-gnu-llvm-21-3 try-job: x86_64-msvc-1 try-job: aarch64-apple try-job: x86_64-mingw-1 try-job: i686-msvc-2
Contributor
|
Replaced with #158958 to include high priority pr |
Contributor
|
This pull request was unapproved due to being closed. |
Contributor
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Successful merges:
b_offsetinsideBackendRepr::ScalarPair#158666 (Carry theb_offsetinsideBackendRepr::ScalarPair)-Zforce-intrinsic-fallback#158927 (add core test run with-Zforce-intrinsic-fallback)VecDeque::retain_backfromtruncate_front#151379 (StabilizeVecDeque::retain_backfromtruncate_front)browser-ui-testversion to0.24.1#158913 (Updatebrowser-ui-testversion to0.24.1)r? @ghost
Create a similar rollup