work around rare non-started abbs
This commit is contained in:
parent
3444fdd8ec
commit
87ddf4a77d
@ -294,17 +294,12 @@ fn add_abb_info(trace: &mut Vec<ExecInterval>, table: &HashMap<u64, ReducedFreeR
|
||||
open_abb_at_this_task_or_level.insert( (trace[i].level, if trace[i].level<2 {&curr_name} else {trace[i].start_capture.1.as_str()}) , i);
|
||||
task_has_started.insert(curr_name.clone());
|
||||
} else {
|
||||
if trace[i].start_capture.1 == "isr_starter" { // fix up case for isr starter, which does not always end
|
||||
if let Some(last) = open_abb_at_this_task_or_level.get(&(trace[i].level, if trace[i].level<2 {&curr_name} else {trace[i].start_capture.1.as_str()})) {
|
||||
wip_abb_trace.push(wip_abb_trace[*last].clone());
|
||||
} else {
|
||||
eprintln!("Continued block with no start {} {:?} {:?} {} {}", trace[i].start_tick, trace[i].start_capture, trace[i].end_capture, task_has_started.contains(curr_name),trace[i].level);
|
||||
wip_abb_trace.push(Rc::new(RefCell::new(AtomicBasicBlock{start: edges[i].1.unwrap_or(0), ends: HashSet::new(), level: if trace[i].level<2 {trace[i].level} else {2}})))
|
||||
}
|
||||
} else {
|
||||
// generic case, continue a preempted block
|
||||
let last = open_abb_at_this_task_or_level.get(&(trace[i].level, if trace[i].level<2 {&curr_name} else {trace[i].start_capture.1.as_str()})).expect(&format!("Continued block with no start {} {:?} {:?} {} {}", trace[i].start_tick, trace[i].start_capture, trace[i].end_capture, task_has_started.contains(curr_name),trace[i].level));
|
||||
wip_abb_trace.push(wip_abb_trace[*last].clone());
|
||||
}
|
||||
}
|
||||
},
|
||||
_ => panic!("Undefined block start")
|
||||
|
Loading…
x
Reference in New Issue
Block a user