rust/compiler/rustc_middle/src
bors f8d8ffa2eb Auto merge of #111029 - Nilstrieb:when-the-errs-are-too-big, r=petrochenkov
Shrink `SelectionError` a lot

`SelectionError` used to be 80 bytes (on 64 bit). That's quite big. Especially because the selection cache contained `Result<_, SelectionError>. The Ok type is only 32 bytes, so the 80 bytes significantly inflate the size of the cache.

Most variants of the `SelectionError` seem to be hard errors, only `Unimplemented` shows up in practice (for cranelift-codegen, it occupies 23.4% of all cache entries). We can just box away the biggest variant, `OutputTypeParameterMismatch`, to get the size down to 16 bytes, well within the size of the Ok type inside the cache.
2023-05-11 08:43:38 +00:00
..
dep_graph Allow LocalDefId as the argument to def_path_str 2023-04-21 22:27:20 +00:00
hir Remove unused TypeFoldable/TypeVisitable impls. 2023-04-26 15:19:50 +10:00
infer Rollup merge of #110386 - nnethercote:clean-up-traversal-macros, r=lcnr 2023-04-17 18:13:35 +02:00
middle Revert "Populate effective visibilities in rustc_privacy" 2023-05-08 21:47:44 +00:00
mir Implement SSA-based reference propagation. 2023-05-09 17:59:34 +00:00
query Rollup merge of #108705 - clubby789:refutable-let-closure-borrow, r=cjgillot 2023-05-11 07:05:26 +02:00
thir offset_of 2023-04-21 02:14:02 -07:00
traits Shrink SelectionError a lot 2023-05-09 07:10:47 +00:00
ty add EarlyBinder to thir_abstract_const; remove tcx.bound_abstract_const 2023-05-09 16:22:50 -06:00
util Restrict From<S> for {D,Subd}iagnosticMessage. 2023-05-03 08:44:39 +10:00
arena.rs Split {Idx, IndexVec, IndexSlice} into their own modules 2023-04-24 13:53:35 +00:00
error.rs fix(middle): emit error rather than delay bug when reaching limit 2023-04-03 11:08:14 +08:00
lib.rs Switch impl_tag! from explicit tags to ${index()} 2023-04-24 16:48:37 +00:00
lint.rs Restrict From<S> for {D,Subd}iagnosticMessage. 2023-05-03 08:44:39 +10:00
macros.rs Simplify CloneLiftImpls and TrivialTypeTraversalImpls. 2023-04-16 14:19:50 +10:00
metadata.rs rustc_metadata: Remove Span from ModChild 2023-04-18 17:25:04 +03:00
tests.rs mv compiler to compiler/ 2020-08-30 18:45:07 +03:00
thir.rs Remove unused TypeFoldable/TypeVisitable impls. 2023-04-26 15:19:50 +10:00
values.rs Avoid ICEing miri on layout query cycles 2023-05-02 16:14:20 +00:00