@@ -181,16 +181,13 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
181181 }
182182
183183 // Prepare all exposed memory, depending on whether we have a supervisor process.
184- #[ cfg( all( unix, any( target_arch = "x86" , target_arch = "x86_64" ) ) ) ]
185184 if super :: trace:: Supervisor :: init ( ) . is_ok ( ) {
186185 this. prepare_exposed_for_native_call ( false ) ?;
187186 } else {
188187 //this.prepare_exposed_for_native_call(true)?;
189188 //eprintln!("Oh noes!")
190189 panic ! ( "No ptrace!" ) ;
191190 }
192- #[ cfg( not( all( unix, any( target_arch = "x86" , target_arch = "x86_64" ) ) ) ) ]
193- this. prepare_exposed_for_native_call ( true ) ?;
194191
195192 // Convert them to `libffi::high::Arg` type.
196193 let libffi_args = libffi_args
@@ -200,7 +197,6 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
200197
201198 // Call the function and store output, depending on return type in the function signature.
202199 let ret = this. call_native_with_args ( link_name, dest, code_ptr, libffi_args) ?;
203- #[ cfg( all( unix, any( target_arch = "x86" , target_arch = "x86_64" ) ) ) ]
204200 if let Some ( events) = super :: trace:: Supervisor :: get_events ( ) {
205201 this. apply_events ( events) ?;
206202 }
@@ -209,7 +205,6 @@ pub trait EvalContextExt<'tcx>: crate::MiriInterpCxExt<'tcx> {
209205 }
210206}
211207
212- #[ cfg( all( unix, any( target_arch = "x86" , target_arch = "x86_64" ) ) ) ]
213208unsafe fn do_native_call < T : libffi:: high:: CType > ( ptr : CodePtr , args : & [ ffi:: Arg < ' _ > ] ) -> T {
214209 use shims:: trace:: Supervisor ;
215210
@@ -221,12 +216,6 @@ unsafe fn do_native_call<T: libffi::high::CType>(ptr: CodePtr, args: &[ffi::Arg<
221216 }
222217}
223218
224- #[ cfg( not( all( unix, any( target_arch = "x86" , target_arch = "x86_64" ) ) ) ) ]
225- #[ inline( always) ]
226- unsafe fn do_native_call < T : libffi:: high:: CType > ( ptr : CodePtr , args : & [ ffi:: Arg < ' _ > ] ) -> T {
227- unsafe { ffi:: call ( ptr, args) }
228- }
229-
230219#[ derive( Debug , Clone ) ]
231220/// Enum of supported arguments to external C functions.
232221// We introduce this enum instead of just calling `ffi::arg` and storing a list
0 commit comments