In the last report, I wrote about the necessities for having different views of trace abstraction for different attributes and group of them. However after defining the different levels and generating the synthetic events and states, we need to visualize them in such a way that make users able to better understand the traces and easily find misbehavior of the system.
Last week, I have been working on visualization of the states and testing the different solutions of that.
In fact, there are some challenges in the visualization of system states:
1- Visualization of states in different levels of details. At each level, users must be able to navigate through different levels of details; Even between different levels of events and different levels of attributes (a machin, a group of processes, group of FDs , etc)
2- Visualization of large trace files. We need to deal with large trace files and visualize them in a reasonable time.
Querying the modeled state for each pixel, is the first solution that comes to mind. In a pixel oriented visualization, we need to decide for each pixel of the visualization panel that how many states we have. Since each pixel has an interval in the trace, for each pixel we should query twice the modeled state to know home many states we have there. However, the start point of a pixel is the end point of the previous one, so by querying the start point of the pixel intervals we can find what are exists in the pixels.
Last week, I tested this solution, I prototype this way and found that it is very time consuming and is not efficient at all. For example for a 10 MB trace file, it takes 2 seconds for visualizing the current visible window (current visible window shows about 20 attributes (processes, files , ...) simultaneity).
So using this ways is not efficient. But I added two heuristics to increase the speed.
1- Reading multiple pixels instead of reading one pixels at each query (reading a large interval).
2- Drawing the large states and skip next pixels for this attribute.
In this way, we read an interval of the trace and extract the pixels from it. At each point when we see a state that is greater than a pixel's interval, we just draw that state and skip the next pixels of the attribute until then end of the state.
These two heuristics help us to have a reasonable speed and performance to read states of large trace files and visualize them. In my tests, It takes 200 milliseconds to visualize current visible windows of a 100 MB trace file.
Now, I am working on testing and optimizing the solution. Also I am trying to design a user-friendly interface to better show the the states for attributes and group of them.