Skip to content
Commit 3dead2f2 authored by Valentin Schneider's avatar Valentin Schneider
Browse files

trace: Refactor timespan computation

This mostly involves shuffling around window and x_{min/max} variables.

There is one behaviour change:
Previously, with normalize_time=False, the expected window was still
with normalized times. Here's an example:

----------
Say our trace timestamps are in [10, 20]

Trace(.., normalize_time=True, window=[2, 7])
Absolute window we're looking at = [12, 17]

Trace(.., normalize_time=False, window=[12, 17])
Abs window = [24, 27] -> no trace events in there

Trace(.., normalize_time=False, window=[2, 7])
Abs window = [12, 17]
----------

This makes it annoying to give a window when using non normalized time.
The new behaviour is:

----------
Trace(.., normalize_time=True, window=[2, 7])
Absolute window we're looking at = [12, 17]

Trace(.., normalize_time=False, window=[12, 17])
Abs window = [12, 17] -> no trace events in there
----------
parent ab821fb5
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment