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

Rollup of 4 pull requests #75549

Merged
merged 8 commits into from
Aug 15, 2020
Merged

Rollup of 4 pull requests #75549

merged 8 commits into from
Aug 15, 2020

Conversation

tmandry
Copy link
Member

@tmandry tmandry commented Aug 15, 2020

Successful merges:

Failed merges:

r? @ghost

tmiasko and others added 8 commits August 13, 2020 14:51
Configure CMAKE_SYSTEM_NAME when cross-compiling in `configure_cmake`,
to tell CMake about target system. Previously this was done only for
LLVM step and now applies more generally to steps using cmake.
…imulacrum

Set CMAKE_SYSTEM_NAME when cross-compiling

Configure CMAKE_SYSTEM_NAME when cross-compiling in `configure_cmake`,
to tell CMake about target system. Previously this was done only for
LLVM step and now applies more generally to steps using cmake.

Helps with rust-lang#74576.
merge `as_local_hir_id` with `local_def_id_to_hir_id`

`as_local_hir_id` was defined as just calling `local_def_id_to_hir_id` and I think that having two different ways to call the same method is somewhat confusing.

Don't really care about which of these 2 methods we want to keep.

Does this require an MCP, considering that these methods are fairly frequently used?
Recover gracefully from `struct` parse errors

Currently the parser tries to recover from finding a keyword where a field name was expected, but this causes extra knock down parse errors that are completely irrelevant. Instead, bail out early in the parsing of the field and consume the remaining tokens in the block. This can reduce output significantly.

_Improvements based on the narrative in https://fasterthanli.me/articles/i-am-a-java-csharp-c-or-cplusplus-dev-time-to-do-some-rust_
…ckler

std/sys/unix/time: make it easier for LLVM to optimize `Instant` subtraction.

This PR is the minimal change necessary to get LLVM to optimize `if self.t.tv_nsec >= other.t.tv_nsec` to branchless instructions (at least on x86_64), inspired by @m-ou-se's own attempts at optimizing `Instant` subtraction.

I stumbled over this by looking at the total number of instructions executed by `rustc -Z self-profile`, and found that after disabling ASLR, the largest source of non-determinism remaining was from this `if` taking one branch or the other, depending on the values involved.

The reason this code is even called so many times to make a difference, is that `measureme` (the `-Z self-profile` implementation) currently uses `Instant::elapsed` for its event timestamps (of which there can be millions).

I doubt it's critical to land this, although perhaps it could slightly improve some forms of benchmarking.
@tmandry
Copy link
Member Author

tmandry commented Aug 15, 2020

@bors r+ p=5 rollup=never
@rustbot modify labels: +rollup

@bors
Copy link
Contributor

bors commented Aug 15, 2020

📌 Commit 29a9462 has been approved by tmandry

@rustbot rustbot added the rollup A PR which is a rollup label Aug 15, 2020
@bors bors added the S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. label Aug 15, 2020
@bors
Copy link
Contributor

bors commented Aug 15, 2020

⌛ Testing commit 29a9462 with merge 45060c2...

@bors
Copy link
Contributor

bors commented Aug 15, 2020

☀️ Test successful - checks-actions, checks-azure
Approved by: tmandry
Pushing 45060c2 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Aug 15, 2020
@bors bors merged commit 45060c2 into rust-lang:master Aug 15, 2020
@tmandry tmandry deleted the rollup-sxjwa0w branch August 15, 2020 05:49
@cuviper cuviper added this to the 1.47.0 milestone May 2, 2024
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. rollup A PR which is a rollup 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.

8 participants