about summary refs log tree commit diff
path: root/src/librustc/ich
AgeCommit message (Collapse)AuthorLines
2018-05-15Rename ty::Generics::parameters to paramsvarkor-2/+2
2018-05-15Reduce parent_params to parent_countvarkor-2/+2
2018-05-15Consolidate ty::Genericsvarkor-8/+9
2018-05-12Rollup merge of #50550 - llogiq:fmt-result, r=petrochenkovMark Simulacrum-1/+1
use fmt::Result where applicable This is a quite boring PR, but I think the type alias improves readability, so why not use it?
2018-05-11Introduce ConstValue and use it instead of miri's Value for constant valuesJohn Kåre Alsaker-0/+24
2018-05-09use fmt::Result where applicableAndre Bogus-1/+1
2018-05-08Insert fields from TypeAndMut into TyRef to allow layout optimizationJohn Kåre Alsaker-1/+2
2018-05-08Store the GeneratorInterior in the new GeneratorSubstsJohn Kåre Alsaker-9/+6
2018-05-08Store generator movability outside GeneratorInteriorJohn Kåre Alsaker-3/+5
2018-05-02make it compile againflip1995-1/+1
2018-05-02Remove Option from the return type of Attribute::name()Seiichi Uchida-3/+2
2018-05-02Allow Path for name of MetaItemSeiichi Uchida-4/+12
2018-04-30Unify MIR assert messages and const eval errorsOliver Schneider-27/+7
2018-04-30Merge ConstMathError into EvalErrorKindOliver Schneider-25/+17
2018-04-30Remove the `rustc_const_math` crateOliver Schneider-30/+17
2018-04-30Remove ConstFloatOliver Schneider-5/+0
2018-04-30Remove unused const math opsOliver Schneider-3/+0
2018-04-30Remove unused const error variantOliver Schneider-3/+0
2018-04-30Remove the `UnequalTypes` error variantOliver Schneider-1/+0
2018-04-30Implement `PartialCmp` for `ConstFloat`Oliver Schneider-1/+0
2018-04-30Remove unused error variantsOliver Schneider-5/+0
2018-04-28Track unused mutable variables across closuresKeith Yeung-0/+5
2018-04-27Rename InternedString to LocalInternedString and introduce a new thread-safe ↵John Kåre Alsaker-4/+24
InternedString
2018-04-26rustc_target: move in syntax::abi and flip dependency.Irina Popa-1/+1
2018-04-26Rename rustc_back::target to rustc_target::spec.Irina Popa-1/+1
2018-04-26rustc_back: move LinkerFlavor, PanicStrategy, and RelroLevel to target.Irina Popa-1/+1
2018-04-24Make Binder's field private and clean up its usageTyler Mandry-2/+1
2018-04-23add `Goal::CannotProve` and extract `ProgramClause` structNiko Matsakis-0/+1
2018-04-23create a `QueryRegionConstraint` typeNiko Matsakis-4/+0
Chalk wants to be able to pass these constraints around. Also, the form we were using in our existing queries was not as general as we are going to need.
2018-04-19Remove HIR inliningWesley Wiser-28/+0
Fixes #49690
2018-04-17Auto merge of #49626 - fanzier:chalk-lowering, r=scalexmbors-0/+1
Implement Chalk lowering rule Normalize-From-Impl This extends the Chalk lowering pass with the "Normalize-From-Impl" rule for generating program clauses from a trait definition as part of #49177. r? @nikomatsakis
2018-04-16Auto merge of #49847 - sinkuu:save_analysis_implicit_extern, r=petrochenkovbors-3/+9
Fix save-analysis generation with extern_in_paths/extern_absolute_paths Fixes #48742.
2018-04-15Implement Chalk lowering rule Normalize-From-ImplFabian Zaiser-0/+1
2018-04-15Auto merge of #49947 - oli-obk:turing_complete_const_eval, r=nagisabors-1/+0
Don't abort const eval due to long running evals, just warn one check-box of #49930 r? @nagisa (https://github.com/rust-lang/rfcs/pull/2344#issuecomment-368246665)
2018-04-14Stop referring to statics' AllocIds directlyOliver Schneider-2/+1
2018-04-14Don't recurse into allocations, use a global table insteadOliver Schneider-11/+13
2018-04-13Don't abort const eval due to long running evals, just warnOliver Schneider-1/+0
2018-04-13Auto merge of #49718 - petrochenkov:fieldcmp, r=eddybbors-12/+35
Hygiene 2.0: Avoid comparing fields by name There are two separate commits here (not counting tests): - The first one unifies named (`obj.name`) and numeric (`obj.0`) field access expressions in AST and HIR. Before field references in these expressions are resolved it doesn't matter whether the field is named or numeric (it's just a symbol) and 99% of code is common. After field references are resolved we work with them by index for all fields (see the second commit), so it's again not important whether the field was named or numeric (this includes MIR where all fields were already by index). (This refactoring actually fixed some bugs in HIR-based borrow checker where borrows through names (`S { 0: ref x }`) and indices (`&s.0`) weren't considered overlapping.) - The second commit removes all by-name field comparison and instead resolves field references to their indices once, and then uses those resolutions. (There are still a few name comparisons in save-analysis, because save-analysis is weird, but they are made correctly hygienic). Thus we are fixing a bunch of "secondary" field hygiene bugs (in borrow checker, lints). Fixes https://github.com/rust-lang/rust/issues/46314
2018-04-13Move `path_len` to ExternCrateShotaro Yamada-21/+6
2018-04-12Avoid comparing fields by name when possibleVadim Petrochenkov-11/+35
Resolve them into field indices once and then use those resolutions + Fix rebase
2018-04-12AST/HIR: Merge field access expressions for named and numeric fieldsVadim Petrochenkov-1/+0
2018-04-12Implement inferring outlives requirements for references, structs, enum, ↵toidiu-0/+14
union, and projection types. added a feature gate and tests for these scenarios.
2018-04-10Add ok-wrapping to catch blocks, per RFCScott McMurray-1/+2
2018-04-11Extend `ExternCrate` to cover externs inferred from `use` or pathsShotaro Yamada-3/+24
2018-04-07[incremental] Hash `Allocation`sShotaro Yamada-1/+1
2018-04-06Auto merge of #48779 - michaelwoerister:share-generics4, r=alexcrichtonbors-2/+16
Allow for re-using monomorphizations in upstream crates. Followup to #48611. This implementation is pretty much finished modulo failing tests if there are any. Not quite ready for review yet though. ### DESCRIPTION This PR introduces a `share-generics` mode for RLIBs and Rust dylibs. When a crate is compiled in this mode, two things will happen: - before instantiating a monomorphization in the current crate, the compiler will look for that monomorphization in all upstream crates and link to it, if possible. - monomorphizations are not internalized during partitioning. Instead they are added to the list of symbols exported from the crate. This results in less code being translated and LLVMed. However, there are also downsides: - it will impede optimization somewhat, since fewer functions can be internalized, and - Rust dylibs will have bigger symbol tables since they'll also export monomorphizations. Consequently, this PR only enables the `shared-generics` mode for opt-levels `No`, `Less`, `Size`, and `MinSize`, and for when incremental compilation is activated. `-O2` and `-O3` will still generate generic functions per-crate. Another thing to note is that this has a somewhat similar effect as MIR-only RLIBs, in that monomorphizations are shared, but it is less effective because it cannot share monomorphizations between sibling crates: ``` A <--- defines `fn foo<T>() { .. }` / \ / \ B C <--- both call `foo<u32>()` \ / \ / D <--- calls `foo<u32>()` too ``` With `share-generics`, both `B` and `C` have to instantiate `foo<u32>` and only `D` can re-use it (from either `B` or `C`). With MIR-only RLIBs, `B` and `C` would not instantiate anything, and in `D` we would then only instantiate `foo<u32>` once. On the other hand, when there are many leaf crates in the graph (e.g. when compiling many individual test binaries) then the `share-generics` approach will often be more effective. ### TODO - [x] Add codegen test that makes sure monomorphizations can be internalized in non-Rust binaries. - [x] Add codegen-units test that makes sure we share generics. - [x] Add run-make test that makes sure we don't export any monomorphizations from non-Rust binaries. - [x] Review for reproducible-builds implications.
2018-04-06Allow for re-using monomorphizations from upstream crates.Michael Woerister-2/+15
2018-04-06Fix incomplete ICH implementation for ty::subst::UnpackedKind.Michael Woerister-0/+1
2018-04-06Use `Ident` instead of `Name` in `MetaItem`Vadim Petrochenkov-1/+1
2018-04-06Fix stable hash for identifiersVadim Petrochenkov-2/+3