Less confusing instr stat

This commit is contained in:
Aleksey Kladov 2021-01-06 18:16:04 +03:00
parent 655ac47ee3
commit ec9e2f50f4

View file

@ -76,7 +76,11 @@ impl fmt::Display for StopWatchSpan {
instructions /= 1000; instructions /= 1000;
prefix = "m" prefix = "m"
} }
write!(f, ", {}{}i", instructions, prefix)?; if instructions > 10000 {
instructions /= 1000;
prefix = "g"
}
write!(f, ", {}{}instr", instructions, prefix)?;
} }
if let Some(memory) = self.memory { if let Some(memory) = self.memory {
write!(f, ", {}", memory)?; write!(f, ", {}", memory)?;