@@ -37,7 +37,7 @@ pub const STACK_ADDR: u64 = 32 * PAGE_SIZE; // not really about the "stack", but
3737pub const STACK_SIZE : u64 = 16 * PAGE_SIZE ; // whatever
3838
3939/// Extra data stored with each stack frame
40- pub struct FrameData < ' tcx > {
40+ pub struct FrameExtra < ' tcx > {
4141 /// Extra data for Stacked Borrows.
4242 pub borrow_tracker : Option < borrow_tracker:: FrameState > ,
4343
@@ -58,20 +58,20 @@ pub struct FrameData<'tcx> {
5858 pub is_user_relevant : bool ,
5959}
6060
61- impl < ' tcx > std:: fmt:: Debug for FrameData < ' tcx > {
61+ impl < ' tcx > std:: fmt:: Debug for FrameExtra < ' tcx > {
6262 fn fmt ( & self , f : & mut std:: fmt:: Formatter < ' _ > ) -> std:: fmt:: Result {
6363 // Omitting `timing`, it does not support `Debug`.
64- let FrameData { borrow_tracker, catch_unwind, timing : _, is_user_relevant : _ } = self ;
64+ let FrameExtra { borrow_tracker, catch_unwind, timing : _, is_user_relevant : _ } = self ;
6565 f. debug_struct ( "FrameData" )
6666 . field ( "borrow_tracker" , borrow_tracker)
6767 . field ( "catch_unwind" , catch_unwind)
6868 . finish ( )
6969 }
7070}
7171
72- impl VisitTags for FrameData < ' _ > {
72+ impl VisitTags for FrameExtra < ' _ > {
7373 fn visit_tags ( & self , visit : & mut dyn FnMut ( BorTag ) ) {
74- let FrameData { catch_unwind, borrow_tracker, timing : _, is_user_relevant : _ } = self ;
74+ let FrameExtra { catch_unwind, borrow_tracker, timing : _, is_user_relevant : _ } = self ;
7575
7676 catch_unwind. visit_tags ( visit) ;
7777 borrow_tracker. visit_tags ( visit) ;
@@ -258,10 +258,10 @@ pub struct AllocExtra {
258258 pub borrow_tracker : Option < borrow_tracker:: AllocState > ,
259259 /// Data race detection via the use of a vector-clock,
260260 /// this is only added if it is enabled.
261- pub data_race : Option < data_race:: AllocExtra > ,
261+ pub data_race : Option < data_race:: AllocState > ,
262262 /// Weak memory emulation via the use of store buffers,
263263 /// this is only added if it is enabled.
264- pub weak_memory : Option < weak_memory:: AllocExtra > ,
264+ pub weak_memory : Option < weak_memory:: AllocState > ,
265265}
266266
267267impl VisitTags for AllocExtra {
@@ -736,7 +736,7 @@ impl<'mir, 'tcx> Machine<'mir, 'tcx> for MiriMachine<'mir, 'tcx> {
736736 type MemoryKind = MiriMemoryKind ;
737737 type ExtraFnVal = Dlsym ;
738738
739- type FrameExtra = FrameData < ' tcx > ;
739+ type FrameExtra = FrameExtra < ' tcx > ;
740740 type AllocExtra = AllocExtra ;
741741
742742 type Provenance = Provenance ;
@@ -908,14 +908,14 @@ impl<'mir, 'tcx> Machine<'mir, 'tcx> for MiriMachine<'mir, 'tcx> {
908908 . map ( |bt| bt. borrow_mut ( ) . new_allocation ( id, alloc. size ( ) , kind, & ecx. machine ) ) ;
909909
910910 let race_alloc = ecx. machine . data_race . as_ref ( ) . map ( |data_race| {
911- data_race:: AllocExtra :: new_allocation (
911+ data_race:: AllocState :: new_allocation (
912912 data_race,
913913 & ecx. machine . threads ,
914914 alloc. size ( ) ,
915915 kind,
916916 )
917917 } ) ;
918- let buffer_alloc = ecx. machine . weak_memory . then ( weak_memory:: AllocExtra :: new_allocation) ;
918+ let buffer_alloc = ecx. machine . weak_memory . then ( weak_memory:: AllocState :: new_allocation) ;
919919 let alloc: Allocation < Provenance , Self :: AllocExtra > = alloc. adjust_from_tcx (
920920 & ecx. tcx ,
921921 AllocExtra { borrow_tracker, data_race : race_alloc, weak_memory : buffer_alloc } ,
@@ -1070,7 +1070,7 @@ impl<'mir, 'tcx> Machine<'mir, 'tcx> for MiriMachine<'mir, 'tcx> {
10701070 fn init_frame_extra (
10711071 ecx : & mut InterpCx < ' mir , ' tcx , Self > ,
10721072 frame : Frame < ' mir , ' tcx , Provenance > ,
1073- ) -> InterpResult < ' tcx , Frame < ' mir , ' tcx , Provenance , FrameData < ' tcx > > > {
1073+ ) -> InterpResult < ' tcx , Frame < ' mir , ' tcx , Provenance , FrameExtra < ' tcx > > > {
10741074 // Start recording our event before doing anything else
10751075 let timing = if let Some ( profiler) = ecx. machine . profiler . as_ref ( ) {
10761076 let fn_name = frame. instance . to_string ( ) ;
@@ -1088,7 +1088,7 @@ impl<'mir, 'tcx> Machine<'mir, 'tcx> for MiriMachine<'mir, 'tcx> {
10881088
10891089 let borrow_tracker = ecx. machine . borrow_tracker . as_ref ( ) ;
10901090
1091- let extra = FrameData {
1091+ let extra = FrameExtra {
10921092 borrow_tracker : borrow_tracker. map ( |bt| bt. borrow_mut ( ) . new_frame ( & ecx. machine ) ) ,
10931093 catch_unwind : None ,
10941094 timing,
@@ -1157,7 +1157,7 @@ impl<'mir, 'tcx> Machine<'mir, 'tcx> for MiriMachine<'mir, 'tcx> {
11571157 #[ inline( always) ]
11581158 fn after_stack_pop (
11591159 ecx : & mut InterpCx < ' mir , ' tcx , Self > ,
1160- mut frame : Frame < ' mir , ' tcx , Provenance , FrameData < ' tcx > > ,
1160+ mut frame : Frame < ' mir , ' tcx , Provenance , FrameExtra < ' tcx > > ,
11611161 unwinding : bool ,
11621162 ) -> InterpResult < ' tcx , StackPopJump > {
11631163 if frame. extra . is_user_relevant {
0 commit comments