rust/compiler
Aaron Hill b9653568a7
Encode less metadata for proc-macro crates
Currently, we serialize the same crate metadata for proc-macro crates as
we do for normal crates. This is quite wasteful - almost none of this
metadata is ever used, and much of it can't even be deserialized (if it
contains a foreign `CrateNum`).

This PR changes metadata encoding to skip encoding the majority of crate
metadata for proc-macro crates. Most of the `Lazy<[T]>` fields are left
completetly empty, while the non-lazy fields are left as-is.

Additionally, proc-macros now have a def span that does not include
their body. This was done for normal functions in #75465, but was missed
for proc-macros.

As a result of this PR, we should only ever encode local `CrateNum`s
when encoding proc-macro crates. I've added a specialized serialization
impl for `CrateNum` to assert this.
2020-09-26 12:26:27 -04:00
..
rustc
rustc_apfloat /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_arena Auto merge of #77172 - jonas-schievink:rollup-a041rou, r=jonas-schievink 2020-09-25 01:56:06 +00:00
rustc_ast tidy 2020-09-23 22:08:30 +02:00
rustc_ast_lowering simplfy condition in ItemLowerer::with_trait_impl_ref() 2020-09-16 23:09:57 +02:00
rustc_ast_passes use matches!() macro for simple if let conditions 2020-09-18 20:28:35 +02:00
rustc_ast_pretty
rustc_attr Allow multiple allow_internal_unstable attributes 2020-09-25 15:19:46 +02:00
rustc_builtin_macros Auto merge of #76485 - estebank:format_arg_capture_spans, r=davidtwco 2020-09-26 10:05:49 +00:00
rustc_codegen_llvm Address review comment 2020-09-25 22:48:44 +01:00
rustc_codegen_ssa Simplify some match statements on `DefPathDataName' 2020-09-25 22:46:15 +01:00
rustc_data_structures Rollup merge of #77121 - duckymirror:html-root-url, r=jyn514 2020-09-25 02:29:45 +02:00
rustc_driver /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_error_codes Rollup merge of #76973 - lzutao:unstably-const-assume, r=oli-obk 2020-09-25 19:42:29 +02:00
rustc_errors /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_expand Remove redundant #![feature(...)] 's from compiler/ 2020-09-17 07:58:45 +02:00
rustc_feature Add cfg(target_has_atomic_equal_alignment). 2020-09-21 20:42:25 +02:00
rustc_fs_util
rustc_graphviz /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_hir Move is_raw_guess check in ty::print::pretty 2020-09-25 22:48:44 +01:00
rustc_hir_pretty
rustc_incremental /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_index cache types during normalization 2020-09-19 17:27:13 +02:00
rustc_infer Implement Display for DisambiguatedDefPathData and DefPathData 2020-09-25 22:46:15 +01:00
rustc_interface PR feedback 2020-09-17 12:18:09 +02:00
rustc_lexer Fix typo in rustc_lexer docs 2020-09-21 05:43:39 +02:00
rustc_lint Simplify some match statements on `DefPathDataName' 2020-09-25 22:46:15 +01:00
rustc_llvm /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_macros Preserve doc-comments when generating queries 2020-09-17 00:28:31 -04:00
rustc_metadata Encode less metadata for proc-macro crates 2020-09-26 12:26:27 -04:00
rustc_middle Auto merge of #70743 - oli-obk:eager_const_to_pat_conversion, r=eddyb 2020-09-26 06:44:28 +00:00
rustc_mir Auto merge of #70743 - oli-obk:eager_const_to_pat_conversion, r=eddyb 2020-09-26 06:44:28 +00:00
rustc_mir_build Auto merge of #70743 - oli-obk:eager_const_to_pat_conversion, r=eddyb 2020-09-26 06:44:28 +00:00
rustc_parse Rollup merge of #76994 - yuk1ty:fix-small-typo, r=estebank 2020-09-23 14:54:07 +02:00
rustc_parse_format /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_passes Address review comment 2020-09-25 22:48:44 +01:00
rustc_plugin_impl /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_privacy /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_query_system
rustc_resolve /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_save_analysis /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_serialize /nightly/nightly-rustc 2020-09-23 21:51:56 +02:00
rustc_session Auto merge of #70743 - oli-obk:eager_const_to_pat_conversion, r=eddyb 2020-09-26 06:44:28 +00:00
rustc_span Remove now unused double_braced_* symbols 2020-09-25 22:46:15 +01:00
rustc_symbol_mangling Implement Display for DisambiguatedDefPathData and DefPathData 2020-09-25 22:46:15 +01:00
rustc_target Rollup merge of #77121 - duckymirror:html-root-url, r=jyn514 2020-09-25 02:29:45 +02:00
rustc_trait_selection Rollup merge of #77155 - lcnr:ImplSource, r=ecstatic-morse 2020-09-25 19:42:48 +02:00
rustc_traits Upgrade chalk to 0.28.0 2020-09-24 20:54:33 +02:00
rustc_ty Rollup merge of #77155 - lcnr:ImplSource, r=ecstatic-morse 2020-09-25 19:42:48 +02:00
rustc_typeck Rollup merge of #77155 - lcnr:ImplSource, r=ecstatic-morse 2020-09-25 19:42:48 +02:00