Add preliminary support for IP control

This commit is contained in:
Guillume DIDIER 2021-10-13 15:39:05 +02:00
parent b2f7a80395
commit 843cf63ba9
3 changed files with 26 additions and 0 deletions

View File

@ -0,0 +1,5 @@
use prefetcher_reverse::ip_tool::tmp_test;
fn main() {
tmp_test();
}

View File

@ -0,0 +1,20 @@
global_asm!(
".global timed_maccess_template",
"timed_maccess_template:",
"nop",
"ret",
".global timed_maccess_template_end",
"timed_maccess_template_end:",
"nop",
);
extern "C" {
fn timed_maccess_template(pointer: *const u8) -> u64;
fn timed_maccess_template_end();
}
pub fn tmp_test() {
let size = timed_maccess_template_end as *const u8 as usize
- timed_maccess_template as *const u8 as usize;
println!("function size : {}", size);
}

View File

@ -1,3 +1,4 @@
#![feature(global_asm)]
#![deny(unsafe_op_in_unsafe_fn)]
use crate::Probe::{Flush, FullFlush, Load};