File tree Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Expand file tree Collapse file tree 2 files changed +5
-7
lines changed Original file line number Diff line number Diff line change 1- use rustc_target:: abi:: { Align , Size } ;
1+ use rustc_target:: abi:: { MemoryPosition , Size } ;
22use rustc_data_structures:: fx:: { FxHashSet } ;
33use std:: cmp:: { self , Ordering } ;
44use rustc_data_structures:: sync:: Lock ;
@@ -54,8 +54,7 @@ impl CodeStats {
5454 pub fn record_type_size < S : ToString > ( & self ,
5555 kind : DataTypeKind ,
5656 type_desc : S ,
57- align : Align ,
58- overall_size : Size ,
57+ mem_pos : MemoryPosition ,
5958 packed : bool ,
6059 opt_discr_size : Option < Size > ,
6160 mut variants : Vec < VariantInfo > ) {
@@ -68,8 +67,8 @@ impl CodeStats {
6867 let info = TypeSizeInfo {
6968 kind,
7069 type_description : type_desc. to_string ( ) ,
71- align : align. bytes ( ) ,
72- overall_size : overall_size . bytes ( ) ,
70+ align : mem_pos . align . bytes ( ) ,
71+ overall_size : mem_pos . size . bytes ( ) ,
7372 packed : packed,
7473 opt_discr_size : opt_discr_size. map ( |s| s. bytes ( ) ) ,
7574 variants,
Original file line number Diff line number Diff line change @@ -1612,8 +1612,7 @@ impl<'tcx> LayoutCx<'tcx, TyCtxt<'tcx>> {
16121612 let type_desc = format ! ( "{:?}" , layout. ty) ;
16131613 self . tcx . sess . code_stats . record_type_size ( kind,
16141614 type_desc,
1615- layout. pref_pos . align . abi ,
1616- layout. pref_pos . size ,
1615+ layout. pref_pos . mem_pos ( ) ,
16171616 packed,
16181617 opt_discr_size,
16191618 variants) ;
You can’t perform that action at this time.
0 commit comments