about summary refs log tree commit diff
path: root/src/librustc
AgeCommit message (Collapse)AuthorLines
2019-04-14Derive Default for ExternEntryAaron Hill-20/+11
2019-04-14Fix ExternEntry testAaron Hill-25/+11
2019-04-14Refactor structure of ExternEntryAaron Hill-38/+28
2019-04-14Move new_public to 'tess' moduleAaron Hill-8/+10
2019-04-14Improve formattingAaron Hill-24/+1
2019-04-14Fix testsAaron Hill-7/+28
2019-04-14Rollup merge of #59877 - Zoxc:hiridify_def_id, r=eddybMazdak Farrokhzad-75/+232
HirIdify hir::Def cc @ljedrz r? @oli-obk
2019-04-14Rollup merge of #59856 - albins:update-polonius, r=nikomatsakisMazdak Farrokhzad-1/+1
update polonius-engine This updates polonius-engine to [version 0.7.0](https://github.com/rust-lang/polonius/blob/master/RELEASES.md#v070), which adds a hybrid algorithm that starts off with performing a cheaper, location-insensitive analysis before proceeding with the full analysis. r? @nikomatsakis
2019-04-14Auto merge of #59693 - nnethercote:64-bit-Spans, r=petrochenkovbors-1/+1
Increase `Span` from 4 bytes to 8 bytes. This increases the size of some important types, such as `ast::Expr` and `mir::Statement`. However, it drastically reduces how much the interner is used, and the fields are more natural sizes that don't require bit operations to extract. As a result, instruction counts drop across a range of workloads, by as much as 10% for `script-servo` incremental builds. Peak memory usage goes up a little for some cases, but down by more for some other cases -- as much as 18% for non-incremental builds of `packed-simd`. The commit also: - removes the `repr(packed)`, because it has negligible effect, but can cause undefined behaviour; - replaces explicit impls of common traits (`Copy`, `PartialEq`, etc.) with derived ones. r? @petrochenkov
2019-04-14HirIdify hir::Defljedrz-75/+232
2019-04-14Fix tidyAaron Hill-1/+1
2019-04-14Combine 'Extern' and 'ExternPrivate'Aaron Hill-27/+50
2019-04-14Properly parse '--extern-private' with name and pathAaron Hill-6/+48
2019-04-14Auto merge of #59950 - Centril:rollup-hpmr62i, r=Centrilbors-6/+32
Rollup of 6 pull requests Successful merges: - #59776 (Apply resource-suffix to search-index and source-files scripts as well) - #59784 (Suggest importing macros from the crate root) - #59812 (Exclude profiler-generated symbols from MSVC __imp_-symbol workaround.) - #59874 (Clean up handling of `-Z pgo-gen` commandline option.) - #59890 (Don't generate empty json variables) - #59911 (Revert "compile crates under test w/ -Zemit-stack-sizes") Failed merges: r? @ghost
2019-04-14Rollup merge of #59874 - michaelwoerister:pgo-updates-1, r=cramertjMazdak Farrokhzad-6/+32
Clean up handling of `-Z pgo-gen` commandline option. This PR adapts the `-Z pgo-gen` flag to how Clang and GCC handle the corresponding `-fprofile-generate` flag. In particular, the flag now optionally takes a directory to place the profiling data in and allows to omit the argument (instead of having to pass an empty string).
2019-04-14Rollup merge of #59899 - nnethercote:sort-enum-variants-by-size, r=pnkfelixMazdak Farrokhzad-1/+7
In `-Zprint-type-size` output, sort enum variants by size. It's useful to see the biggest variants first. r? @pnkfelix
2019-04-14Rollup merge of #59858 - mark-i-m:dup-matcher-bindings-3, r=CentrilMazdak Farrokhzad-9/+1
Make duplicate matcher bindings a hard error r? @Centril Closes #57742
2019-04-14Rollup merge of #59735 - matklad:deadcode, r=sanxiynMazdak Farrokhzad-3/+3
remove lookup_char_pos_adj It is now exactly equivalent to lookup_char_pos.
2019-04-13Auto merge of #59515 - wesleywiser:measureme, r=michaelwoeristerbors-396/+143
Use measureme in self profiler r? @michaelwoerister ~Changes are still very rough.~ ~I'm not sure what the right way to add the `measureme` dependency is. Currently it's just added with a relative path which Works On My Machine ™️.~ I'm also not sure what to do with the category data.
2019-04-12Use measureme in self-profilerWesley Wiser-396/+143
Related to #58372 Related to #58967
2019-04-12Rollup merge of #59859 - davidtwco:issue-59756, r=cramertjMazdak Farrokhzad-1/+30
Suggest removing `?` to resolve type errors. Fixes #59756.
2019-04-12Auto merge of #59651 - tmandry:discr-index, r=eddybbors-0/+4
Add discr_index to multi-variant layouts We remove the assumption that the discriminant is always field 0, in preparations for layouts like generators where this is not (always) going to be the case. Specifically, upvars are going to go before the discriminant. In theory, it's possible to remove _that_ assumption instead and keep the discriminant at field index 0, but one assumption or the other had to go :) There is one place I know of in the debuginfo code where we'll still need to remove assumptions that the discriminant is the _only_ field. I was planning on doing this along with the upcoming generator change, which will also include tests that exercise the code changing in this PR. r? @eddyb cc @oli-obk cc @cramertj
2019-04-12Rollup merge of #59809 - Zoxc:trait_methods_not_found, r=estebankMazdak Farrokhzad-2/+2
Make trait_methods_not_found use a lock r? @estebank
2019-04-12Uplift `get_def_path` from Clippyflip1995-6/+28
This uplifts `get_def_path` from Clippy. This is a follow up on the implementation of internal lints: #59316 The internal lint implementation also copied the implementation of the `AbsolutePathPrinter`. To get rid of this code duplication this also uplifts the `get_def_path` function from Clippy. This also renames `match_path` to `match_def_path`, as it was originally named in Clippy.
2019-04-12Auto merge of #59536 - Zoxc:the-arena, r=eddybbors-19/+283
Introduce an arena type which may be used to allocate a list of types with destructors You can also specify that you want deserializers for `&'tcx [T]` and `&'tcx T` for a type in the list, which will allocate those using the arena. Based on https://github.com/rust-lang/rust/pull/59517 and https://github.com/rust-lang/rust/pull/59533. Look at the last commit for the interesting changes. An alternative to https://github.com/rust-lang/rust/pull/56448. cc @michaelwoerister @eddyb r? @oli-obk
2019-04-11Continue evaluating after missing mainEsteban Küber-1/+0
2019-04-12In `-Zprint-type-size` output, sort enum variants by size.Nicholas Nethercote-1/+7
It's useful to see the biggest variants first.
2019-04-11Add discr_index to multi-variant layoutsTyler Mandry-0/+4
We relax the assumption that the discriminant is always field 0, in preparations for layouts like generators where this is not going to be the case.
2019-04-11Auto merge of #59227 - Zoxc:fix-get, r=eddybbors-3/+3
Fix lifetime on LocalInternedString::get function cc @eddyb @nnethercote
2019-04-11Clean up handling of -Zpgo-gen commandline option.Michael Woerister-6/+32
2019-04-10forgot oneMark Mansi-1/+0
2019-04-10make duplicate matcher bindings a hard errorMark Mansi-8/+1
2019-04-10Suggest removing `?` to resolve type errors.David Wood-1/+30
This commit adds a suggestion to remove the `?` from expressions if removing the `?` would resolve a type error.
2019-04-10update polonius-engineAlbin Stjerna-1/+1
2019-04-09Do not render ascii colors to buffersOliver Scherer-2/+2
2019-04-09Fix a typoJohn Kåre Alsaker-1/+1
2019-04-09Make trait_methods_not_found use a lockJohn Kåre Alsaker-2/+2
2019-04-07Auto merge of #58739 - matthewjasper:more-restrictive-tpb, r=pnkfelixbors-1/+12
More restrictive 2 phase borrows - take 2 Signal lint diagnostic `mutable_borrow_reservation_conflict` when borrow-check finds a 2-phase borrow's reservation overlapping with a shared borrow. (pnkfelix updated description) cc #56254 , #59159 blocks PR #59114 r? @pnkfelix cc @RalfJung @nikomatsakis
2019-04-06Rollup merge of #59738 - flip1995:match_path_move, r=eddyb,ManishearthMazdak Farrokhzad-107/+114
Move match_path from DefId to lint::LateContext cc https://github.com/rust-lang/rust/pull/59316#discussion_r272351353 r? @eddyb
2019-04-06Auto merge of #59723 - Zoxc:rem-noforce, r=michaelwoeristerbors-1/+0
Remove no_force from coherent_trait r? @michaelwoerister
2019-04-05Move match_path from DefId to lint::LateContextflip1995-107/+114
2019-04-05remove lookup_char_pos_adjAleksey Kladov-3/+3
It is now exactly equivalent to lookup_char_pos.
2019-04-05Remove no_force from coherent_traitJohn Kåre Alsaker-1/+0
2019-04-05Increase `Span` from 4 bytes to 8 bytes.Nicholas Nethercote-1/+1
This increases the size of some important types, such as `ast::Expr` and `mir::Statement`. However, it drastically reduces how much the interner is used, and the fields are more natural sizes that don't require bit operations to extract. As a result, instruction counts drop across a range of workloads, by as much as 12% for incremental "check" builds of `script-servo`. Peak memory usage goes up a little for some cases, but down by more for some other cases -- as much as 18% for non-incremental builds of `packed-simd`. The commit also: - removes the `repr(packed)`, because it has negligible effect, but can cause undefined behaviour; - replaces explicit impls of common traits (`Copy`, `PartialEq`, etc.) with derived ones.
2019-04-05Add DropArena and use it to allocate types with few allocationsJohn Kåre Alsaker-22/+148
2019-04-05Impl UseSpecializedDecodable for &TJohn Kåre Alsaker-9/+0
2019-04-05Make ArenaAllocatable a marker trait to allow overlapping impls and use ↵John Kåre Alsaker-28/+28
specialization to find the right field
2019-04-05Introduce an arena type which may be used to allocate a list of types with ↵John Kåre Alsaker-18/+165
destructors
2019-04-04Placate tidyFelix S Klock II-2/+2
Get us back below 100 characters per line to placate tidy.
2019-04-04Adjust the mutable_borrow_reservation_conflict messageMatthew Jasper-0/+4
We aren't sure if this will become an error or not yet.