summary refs log tree commit diff
path: root/src/librustc_metadata/encoder.rs
AgeCommit message (Collapse)AuthorLines
2017-04-16rustc: use monomorphic const_eval for cross-crate enum discriminants.Eduard-Mihai Burtescu-9/+37
2017-04-14Rollup merge of #40702 - mrhota:global_asm, r=nagisaCorey Farwell-0/+2
Implement global_asm!() (RFC 1548) This is a first attempt. ~~One (potential) problem I haven't solved is how to handle multiple usages of `global_asm!` in a module/crate. It looks like `LLVMSetModuleInlineAsm` overwrites module asm, and `LLVMAppendModuleInlineAsm` is not provided in LLVM C headers 😦~~ I can provide more detail as needed, but honestly, there's not a lot going on here. r? @eddyb CC @Amanieu @jackpot51 Tracking issue: #35119
2017-04-13use `tcx.crate_name(LOCAL_CRATE)` rather than `LinkMeta::crate_name`Niko Matsakis-2/+2
2017-04-12First attempt at global_asm! macroA.J. Gardner-0/+2
2017-04-12ICH: Replace old, transitive metadata hashing with direct hashing approach.Michael Woerister-11/+37
Instead of collecting all potential inputs to some metadata entry and hashing those, we directly hash the values we are storing in metadata. This is more accurate and doesn't suffer from quadratic blow-up when many entries have the same dependencies.
2017-04-12ICH: Hash everything that gets encoded into crate metadata.Michael Woerister-24/+36
2017-03-27Rollup merge of #40683 - nikomatsakis:incr-comp-coerce-unsized-info, r=eddybAlex Crichton-5/+13
on-demand-ify `custom_coerce_unsized_kind` and `inherent-impls` This "on-demand" task both checks for errors and computes the custom unsized kind, if any. This task is only defined on impls of `CoerceUnsized`; invoking it on any other kind of impl results in a bug. This is just to avoid having an `Option`, could easily be changed. r? @eddyb
2017-03-27Fix various useless derefs and slicingsOliver Schneider-2/+2
2017-03-23move `export_map` into the tcxNiko Matsakis-5/+1
2017-03-23convert `custom_coerce_unsized_kind` into a `coerce_unsized_info`Niko Matsakis-5/+13
This "on-demand" task both checks for errors and computes the custom unsized kind, if any. This task is only defined on impls of `CoerceUnsized`; invoking it on any other kind of impl results in a bug. This is just to avoid having an `Option`, could easily be changed.
2017-03-18translate tuple-variant constructors using MIRAriel Ben-Yehuda-2/+2
2017-03-12Update usages of 'OSX' (and other old names) to 'macOS'.Corey Farwell-1/+1
As of last year with version 'Sierra', the Mac operating system is now called 'macOS'.
2017-03-03Integrate `TokenStream`.Jeffrey Seyfried-1/+2
2017-02-25rustc_const_eval: demand that the MIR qualify_consts ran on each evaluated body.Eduard-Mihai Burtescu-3/+10
2017-02-25rustc: allow handling cycle errors gracefully in on-demand.Eduard-Mihai Burtescu-1/+1
2017-02-25rustc_typeck: hook up collect and item/body check to on-demand.Eduard-Mihai Burtescu-2/+2
2017-02-25rustc: simplify tcx.closure_type(...) as it can copy the cached values.Eduard-Mihai Burtescu-1/+1
2017-02-25rustc: introduce a query system for type information in ty::maps.Eduard Burtescu-2/+2
2017-02-25rustc: consolidate dep-tracked hashmaps in tcx.maps.Eduard-Mihai Burtescu-5/+5
2017-02-25rustc: move the actual values of enum discriminants into a map.Eduard-Mihai Burtescu-6/+14
2017-02-25rustc: store type parameter defaults outside of ty::Generics.Eduard-Mihai Burtescu-19/+42
2017-02-11Rebase falloutSimonas Kazlauskas-1/+2
Because certain somebody sucks at resolving big conflicts
2017-02-10Move type of discriminant to AdtDefSimonas Kazlauskas-5/+5
Previously AdtDef variants contained ConstInt for each discriminant, which did not really reflect the actual type of the discriminants. Moving the type into AdtDef allows to easily put the type into metadata and also saves bytes from ConstVal overhead for each discriminant. Also arguably the code is cleaner now :)
2017-02-06Introduce ReprOptions, a struct for holding info from the repr attributes. ↵Austin Hicks-5/+19
This effectively deprecates lookup_repr_hints.
2017-02-03Bump version, upgrade bootstrapAlex Crichton-2/+0
This commit updates the version number to 1.17.0 as we're not on that version of the nightly compiler, and at the same time this updates src/stage0.txt to bootstrap from freshly minted beta compiler and beta Cargo.
2017-01-29Privatize constructors of tuple structs with private fieldsVadim Petrochenkov-1/+7
2017-01-28rustc: move object default lifetimes to resolve_lifetimes.Eduard-Mihai Burtescu-0/+7
2017-01-28rustc: always include elidable lifetimes in HIR types.Eduard-Mihai Burtescu-2/+12
2017-01-26rustc: rename TyCtxt's `map` field to `hir`.Eduard-Mihai Burtescu-30/+30
2017-01-06rustc: keep track of tables everywhere as if they were per-body.Eduard-Mihai Burtescu-1/+1
2016-12-30Fix rebase falloutSimonas Kazlauskas-4/+8
This commit includes manual merge conflict resolution changes from a rebase by @est31.
2016-12-28rustc: simplify constant cross-crate loading and rustc_passes::consts.Eduard-Mihai Burtescu-29/+13
2016-12-28rustc: move function arguments into hir::Body.Eduard-Mihai Burtescu-14/+30
2016-12-28rustc: separate bodies for static/(associated)const and embedded constants.Eduard-Mihai Burtescu-1/+3
2016-12-28rustc: separate TraitItem from their parent Item, just like ImplItem.Eduard-Mihai Burtescu-2/+4
2016-12-24Use `DefId`s instead of `NodeId`s for `pub(restricted)` visibilities.Jeffrey Seyfried-35/+11
2016-12-16definitions: Store DefPath data in separate table in metadataMichael Woerister-19/+13
2016-12-08also generate MIR for staticsOliver Schneider-0/+1
2016-12-07add a -Z flag to guarantee that MIR is generated for all functionsOliver Schneider-2/+4
2016-12-05trans: Rename `reachable` to `exported_symbols` where appropriate.Michael Woerister-12/+12
2016-12-02Auto merge of #38053 - eddyb:lazy-9, r=nikomatsakisbors-1/+0
[9/n] rustc: move type information out of AdtDef and TraitDef. _This is part of a series ([prev](https://github.com/rust-lang/rust/pull/37688) | [next]()) of patches designed to rework rustc into an out-of-order on-demand pipeline model for both better feature support (e.g. [MIR-based](https://github.com/solson/miri) early constant evaluation) and incremental execution of compiler passes (e.g. type-checking), with beneficial consequences to IDE support as well. If any motivation is unclear, please ask for additional PR description clarifications or code comments._ <hr> Both `AdtDef` and `TraitDef` contained type information (field types, generics and predicates) which was required to create them, preventing their use before that type information exists, or in the case of field types, *mutation* was required, leading to a variance-magicking implementation of `ivar`s. This PR takes that information out and the resulting cleaner setup could even eventually end up merged with HIR, because, just like `AssociatedItem` before it, there's no dependency on types anymore. (With one exception, variant discriminants should probably be moved into their own map later.)
2016-11-30rustc: track the Span's of definitions across crates.Eduard-Mihai Burtescu-12/+18
2016-11-29rustc: remove type information from TraitDef.Eduard-Mihai Burtescu-1/+0
2016-11-29revamp `Visitor` with a single method for controlling nested visitsNiko Matsakis-3/+3
2016-11-29Split nested_visit_mode function off from nested_visit_mapFlorian Diebold-3/+3
... and make the latter mandatory to implement.
2016-11-29Refactor inlined items some moreFlorian Diebold-3/+3
They don't implement FnLikeNode anymore, instead are handled differently further up in the call tree. Also, keep less information (just def ids for the args).
2016-11-29Add make tidy fixesFlorian Diebold-3/+9
2016-11-29Fix cross-crate associated constant evaluationFlorian Diebold-1/+3
2016-11-29Save bodies of functions for inlining into other cratesFlorian Diebold-3/+5
This is quite hacky and I hope to refactor it a bit, but at least it seems to work.
2016-11-29rustc_metadata: fix compilationFlorian Diebold-2/+5