about summary refs log tree commit diff
path: root/src
AgeCommit message (Collapse)AuthorLines
2019-07-10Regression test for issue 30786.Felix S. Klock II-0/+140
2019-07-10Auto merge of #62555 - Centril:rollup-ti46adx, r=Centrilbors-180/+551
Rollup of 5 pull requests Successful merges: - #61853 (Emit warning when trying to use PGO in conjunction with unwinding on …) - #62278 (Add Iterator::partition_in_place() and is_partitioned()) - #62283 (Target::arch can take more than listed options) - #62393 (Fix pretty-printing of `$crate` (take 4)) - #62474 (Prepare for LLVM 9 update) Failed merges: r? @ghost
2019-07-10Rollup merge of #62474 - nikic:update-llvm, r=alexcrichtonMazdak Farrokhzad-85/+160
Prepare for LLVM 9 update Main changes: * In preparation for opaque pointer types, the `byval` attribute now takes a type. As such, the argument type needs to be threaded through to the function/callsite attribute application logic. * On ARM the `+fp-only-sp` and `+d16` features have become `-fp64` and `-d32`. I've switched the target definitions to use the new names, but also added bidirectional emulation so either can be used on any LLVM version for backwards compatibility. * The datalayout can now specify function pointer alignment. In particular on ARM `Fi8` is specified, which means that function pointer alignment is independent of function alignment. I've added this to our datalayouts to match LLVM (which is something we check) and strip the fnptr alignment for older LLVM versions. * The fmul/fadd reductions now always respect the accumulator (including for unordered reductions), so we should pass the identity instead of undef. Open issues: * https://reviews.llvm.org/D62106 causes linker errors with ld.bdf due to https://sourceware.org/bugzilla/show_bug.cgi?id=24784. To avoid this I've enabled `RelaxELFRelocations`, which results in a GOTPCRELX relocation for `__tls_get_addr` and avoids the issue. However, this is likely not acceptable because relax relocations are not supported by older linker versions. We may need an LLVM option to keep using PLT for `__tls_get_addr` despite `RtLibUseGOT`. The corresponding llvm-project PR is https://github.com/rust-lang/llvm-project/pull/19. r? @ghost
2019-07-10Rollup merge of #62393 - petrochenkov:notto-disu, r=Mark-SimulacrumMazdak Farrokhzad-89/+247
Fix pretty-printing of `$crate` (take 4) Pretty-print `$crate` as `crate` or `crate_name` in unstructured tokens like `a $crate c` in `foo!(a $crate c)`, but only if those tokens are printed as a part of AST pretty-printing, rather than as a standalone token stream. Fixes https://github.com/rust-lang/rust/issues/62325 Previous iterations - https://github.com/rust-lang/rust/pull/56647, https://github.com/rust-lang/rust/pull/57155, https://github.com/rust-lang/rust/pull/57915.
2019-07-10Rollup merge of #62283 - fintelia:patch-5, r=Mark-SimulacrumMazdak Farrokhzad-2/+2
Target::arch can take more than listed options A list of options in a comment like this is almost guaranteed to become out of date: right now it is missing "riscv32" and "riscv64" and perhaps other architectures as well.
2019-07-10Rollup merge of #62278 - cuviper:iter-partition, r=alexcrichtonMazdak Farrokhzad-0/+138
Add Iterator::partition_in_place() and is_partitioned() `partition_in_place()` swaps `&mut T` items in-place to satisfy the predicate, so all `true` items precede all `false` items. This requires a `DoubleEndedIterator` so we can search from front and back for items that need swapping. `is_partitioned()` checks whether the predicate is already satisfied.
2019-07-10Rollup merge of #61853 - EricRahm:use_warning, r=varkorMazdak Farrokhzad-4/+4
Emit warning when trying to use PGO in conjunction with unwinding on … …Windows. This reduces the error introduced for #61002 to just a warning.
2019-07-10Auto merge of #62548 - ehuss:update-cargo, r=alexcrichtonbors-0/+0
Update cargo Update cargo 12 commits in 4c1fa54d10f58d69ac9ff55be68e1b1c25ecb816..677a180f4c8ca1dcef594f68dd0e63e4f08621f5 2019-06-24 11:24:18 +0000 to 2019-07-08 13:43:02 +0000 - Update dependencies (rust-lang/cargo#7106) - Fix overwriting .d file for binary with dSYM on apple targets. (rust-lang/cargo#7057) - Update changelog. (rust-lang/cargo#7102) - Revert "Fix 'getting started' internal links" (rust-lang/cargo#7099) - Bump to 0.39.0 (rust-lang/cargo#7100) - Update dependency.rs (rust-lang/cargo#7098) - Typo (rust-lang/cargo#7097) - Fix 'getting started' internal links (rust-lang/cargo#7093) - Fix misleading comment in testsuite (rust-lang/cargo#7090) - improve uncommitted changes cargo-package message (rust-lang/cargo#7083) - Clean environment when git-fetch-with-cli is used. (rust-lang/cargo#7082) - Fix exponentiality in depend_on_deps_of_deps. (rust-lang/cargo#7062)
2019-07-09Update cargoEric Huss-0/+0
2019-07-09Tracking issue 62544 for iter_is_partitionedJosh Stone-1/+1
2019-07-09Tracking issue 62543 for iter_partition_in_placeJosh Stone-1/+1
2019-07-09Auto merge of #62542 - Centril:rollup-5mpb8tu, r=Centrilbors-756/+1192
Rollup of 9 pull requests Successful merges: - #62417 (Fix ICEs when `Self` is used in type aliases) - #62450 (Raise the default recursion limit to 128) - #62470 (Prevent shrinking of "crate select" element on Firefox) - #62515 (cli: make help output for -l and -L consistent) - #62520 (Regression test for issue 42574.) - #62526 (normalize use of backticks in compiler messages for libsyntax/feature_gate.rs) - #62527 (clarify that debug_assert does not completely omits the code) - #62535 (ci: Configure $CI_JOB_NAME correctly) - #62541 (Add spastorino for rustc-guide toolstate) Failed merges: r? @ghost
2019-07-09Emit warning when trying to use PGO in conjunction with unwinding on Windows.Eric Rahm-4/+4
2019-07-09Adjust codegen tests for DISPFlagMainSubprogramNikita Popov-2/+2
2019-07-09Fix float add/mul reduction codegenNikita Popov-2/+9
The accumulator is now respected for unordered reductions.
2019-07-09Strip function pointer alignment for older LLVM versionsNikita Popov-6/+17
2019-07-09Add function pointer alignment to ARM/Thumb data layoutNikita Popov-32/+32
2019-07-09Use new feature names in target feature listsNikita Popov-12/+12
2019-07-09Translate target features for LLVM 9Nikita Popov-0/+24
2019-07-09Pass type to byval attributesNikita Popov-30/+60
2019-07-09Pass GUIDPreservedSymbols to thinLTOResolvePrevailingInIndex()Nikita Popov-1/+4
2019-07-09Add a test case with `$crate` from other crateVadim Petrochenkov-0/+66
2019-07-09Unit test Iterator::partition_in_place and is_partitionedJosh Stone-0/+38
2019-07-09Return the true count from partition_in_placeJosh Stone-6/+35
2019-07-09Rename partition_mut to partition_in_placeJosh Stone-8/+8
2019-07-09Capitalize example commentJosh Stone-1/+1
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-07-09Add Iterator::partition_mut() and is_partitioned()Josh Stone-0/+71
`partition_mut()` swaps `&mut T` items in-place to satisfy the predicate, so all `true` items precede all `false` items. This requires a `DoubleEndedIterator` so we can search from front and back for items that need swapping. `is_partitioned()` checks whether the predicate is already satisfied.
2019-07-09Resolve `$crate` in all hygienic contexts for pretty-pringingVadim Petrochenkov-59/+47
Stop visiting AST to discover those contexts, just iterate through hygiene data instead
2019-07-09Pretty-print `$crate` as `crate`/`::my_crate` in tokensVadim Petrochenkov-55/+70
...but only if those tokens are printed from inside of AST pretty-printing.
2019-07-09Add a test for `$crate` inside macro invocationVadim Petrochenkov-0/+89
2019-07-09Rollup merge of #62541 - mark-i-m:patch-1, r=CentrilMazdak Farrokhzad-1/+1
Add spastorino for rustc-guide toolstate cc @spastorino r? @Centril
2019-07-09Rollup merge of #62527 - matklad:debug-assert, r=CentrilMazdak Farrokhzad-6/+6
clarify that debug_assert does not completely omits the code TIL that debug_assert is implemented using `if cfg!(debug_assertions)` rather than `#[cfg(debug_assertions)]`. This means one can not use API gated with `#[cfg(debug_assertions)]` in `debug_assert` family of macros.
2019-07-09Rollup merge of #62526 - ↵Mazdak Farrokhzad-693/+693
fakenine:normalize_use_of_backticks_compiler_messages_p4, r=Centril normalize use of backticks in compiler messages for libsyntax/feature_gate.rs https://github.com/rust-lang/rust/issues/60532
2019-07-09Rollup merge of #62520 - pnkfelix:add-test-for-42574, r=alexcrichtonMazdak Farrokhzad-0/+39
Regression test for issue 42574. Cc #42574. I'm not going to say this *closes* that issue yet, for two reasons: 1. I am still confused about some aspects of the behavior we are observing that bug 2. The "fix" to the diagnostic relies on full NLL (`#![feature(nll)]`); migration mode still has a subpar diagnostic.
2019-07-09Rollup merge of #62515 - tshepang:consistent, r=CentrilMazdak Farrokhzad-3/+2
cli: make help output for -l and -L consistent
2019-07-09Rollup merge of #62470 - dima74:patch-1, r=GuillaumeGomezMazdak Farrokhzad-0/+1
Prevent shrinking of "crate select" element on Firefox This fixes #60368
2019-07-09Rollup merge of #62450 - nagisa:reclimit, r=pnkfelixMazdak Farrokhzad-29/+389
Raise the default recursion limit to 128 The previous limit of 64 is being (just) barely hit by genuine code out there, which is causing issues like https://github.com/rust-lang/rust/issues/62059 to rear their end. Ideally, we wouldn’t have such arbitrary limits at all, but while we do, it makes a lot of sense to just raise this limit whenever genuine use-cases end up hitting it. r? @pnkfelix Fixes https://github.com/rust-lang/rust/issues/62059
2019-07-09Rollup merge of #62417 - alexreg:fix-self-in-type-alias, r=pnkfelixMazdak Farrokhzad-24/+61
Fix ICEs when `Self` is used in type aliases I think it is right just to disallow this at resolution stage rather than let typeck produce a cyclic error. This is in line with previous behaviour. There was probably no need at all for the change that introduced this bug in #57428, so I've simply reversed it. Fixes #62263, #62364, #62305. r? @eddyb
2019-07-09Add spastorino for rustc-guide toolstateWho? Me?!-1/+1
2019-07-09Auto merge of #62221 - jonas-schievink:normalize-impl-trait, r=nikomatsakisbors-0/+220
Normalize projections appearing in `impl Trait` Fixes #60414 This does not try to do the same for `existential type`s (which have the same bug), since that always seems to lead to cycle errors.
2019-07-09Apply suggestions from code reviewAleksey Kladov-3/+3
Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
2019-07-09Auto merge of #62233 - matthewjasper:exit-arm-scopes, r=pnkfelixbors-17/+43
Exit arm scopes Due to a bug in the HIR CFG construction, borrows for arm scopes were incorrectly leaking into other arms. This PR also includes some drive-by improvements to `-Zunpretty=hir,identified` that would have been helpful while investigating this. Closes #62107
2019-07-09clarify that debug_assert does not completely omits the codeAleksey Kladov-6/+6
TIL that debug_assert is implemented using `if cfg!(debug_assertions)` rather than `#[cfg(debug_assertions)]`. This means one can not use API gated with `#[cfg(debug_assertions)]` in `debug_assert` family of macros.
2019-07-09normalize use of backticks in compiler messages for libsyntax/feature_gateSamy Kacimi-693/+693
https://github.com/rust-lang/rust/issues/60532
2019-07-09rewrite the test to workaround #51525Niko Matsakis-2/+8
2019-07-09Regression test for issue 42574.Felix S. Klock II-0/+39
2019-07-09Auto merge of #62463 - Disasm:riscv-lto, r=alexcrichtonbors-0/+0
Update LLVM: apply patch necessary for ThinLTO on RISC-V This patch allows [using inlined assembly operations](https://github.com/rust-embedded/cortex-m/issues/139) on stable Rust with the help of ThinLTO.
2019-07-09Auto merge of #62460 - RalfJung:llvm-null, r=eddybbors-5/+12
Handle null from LLVMRustGetSectionName As part of https://github.com/rust-lang/rust/pull/58783 and https://github.com/rust-lang/rust/pull/62103, this incorrect use of a NULL pointer was found in the interface to LLVM. That PR is stuck with some linker issues, but there is no reason the soundness fix should have to wait for that.
2019-07-09Rollup merge of #62494 - sinkuu:unused_deps, r=alexcrichtonMazdak Farrokhzad-3/+0
Remove unused dependencies
2019-07-09Rollup merge of #62403 - SimonSapin:concat, r=alexcrichtonMazdak Farrokhzad-74/+76
Replace SliceConcatExt trait with inherent methods and SliceConcat helper trait Before this change `SliceConcatExt` was an unstable extension trait with stable methods. It was in the libstd prelude, so that its methods could be used on the stable channel. This replaces it with inherent methods, which can be used without any addition to the prelude. Since the methods are stable and very generic (with for example a return type that depends on the types of parameters), an helper trait is still needed. But now that trait does not need to be in scope for the methods to be used. Removing this depedency on the libstd prelude allows the methods to be used in `#![no_std]` crate that use liballoc, which does not have its own implicitly-imported prelude.