Commit ba293cd8 authored by Marco Perronet's avatar Marco Perronet
Browse files

Remove invocation cycle panics

parent af1fac2d
......@@ -31,3 +31,8 @@ testing/workloads/manual-input
# extensions
*.pdf
*.csv
# Cloned repos
src/events_generation/binary_parser/lib/libtraceevent
src/events_generation/binary_parser/lib/libtracefs
src/events_generation/binary_parser/lib/trace-cmd
{
"lifetime": 10,
"lifetime": 15,
"clusters": [
{
"cpus": [
......
......@@ -169,8 +169,12 @@ impl FTraceEVG {
println!("{:#?}", raw_event);
}
if crate::params::dump_raw_trace_w_type() && self.target_pids.contains(&trace_event.unwrap().pid) {
let event = trace_event.unwrap();
let mut event = trace_event.unwrap();
println!("*** {} - {} ***\n{:#?}", event.etype.short_name(), event.pid, raw_event);
if self.extra_event.is_some() {
event = self.extra_event.unwrap();
println!("*** {} - {} ***\n{:#?}", event.etype.short_name(), event.pid, raw_event);
}
}
return trace_event;
......
......@@ -132,7 +132,7 @@ impl InvocationCycle {
self.last_event_time = instant;
},
None => self.reset(),
_ => panic!("Last event type: {:#?}", self.last_event_type.unwrap())
_ => { println!("Invocation cycle warning: Last event type: {:#?} Pid {}", self.last_event_type.unwrap(), self.pid); self.reset(); }
}
}
......@@ -146,7 +146,7 @@ impl InvocationCycle {
self.last_event_time = instant;
}
None => self.reset(),
_ => panic!("Last event type: {:#?}", self.last_event_type.unwrap())
_ => { println!("Invocation cycle warning: Last event type: {:#?} Pid {}", self.last_event_type.unwrap(), self.pid); self.reset(); }
}
}
......@@ -176,7 +176,7 @@ impl InvocationCycle {
}
}
None => { self.reset(); None },
_ => panic!("Last event type: {:#?}", self.last_event_type.unwrap())
_ => { println!("Invocation cycle warning: Last event type: {:#?} Pid {}", self.last_event_type.unwrap(), self.pid); self.reset(); None }
}
}
......
......@@ -7,10 +7,10 @@ use crate::events_processing::invocation_cycle::IcHeuristic;
/* Debug */
pub static mut DUMP_RAW_TRACE: bool = false;
pub static mut DUMP_RAW_TRACE_W_TYPE: bool = true; // TODO TURN ME OFF
pub static mut DUMP_RAW_TRACE_W_TYPE: bool = false; // TODO TURN ME OFF
pub static mut LOGGER_EVENT_SEQ: bool = false;
// Record the current run
pub static mut LOGGER_REPLAY: bool = true; // Only turn this off when measuring performance!
pub static mut LOGGER_REPLAY: bool = false; // Only turn this off when measuring performance!
// Replay a previous run with this filename
pub static mut REPLAY_FILE: Option<String> = None;
pub static mut UNIT_TEST_MATCHER: bool = false; // TODO TURN ME BACK ON ONCE UNIT TESTS ARE FIXED
......
......@@ -94,11 +94,11 @@ pub fn matching_loop(rx_matcher: Receiver<EventUpdate>, tx_matcher: Sender<Model
}
/* Debug */
if models_of_pid.pjitter.is_some() {
let (p, j, _c, _o) = match models_of_pid.pjitter.unwrap() { Model::PJitterOffset(p, j, c, o) => (p, j, c, o), _ => panic!()};
period_convergence.push(p);
jitter_convergence.push(j);
}
// if models_of_pid.pjitter.is_some() {
// let (p, j, _c, _o) = match models_of_pid.pjitter.unwrap() { Model::PJitterOffset(p, j, c, o) => (p, j, c, o), _ => panic!()};
// period_convergence.push(p);
// jitter_convergence.push(j);
// }
}
/* Send update with matched models and rbfs */
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment