Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [tracecompass-dev] Question about visualizing thread-related events in TC incubator

Hi Patrick,

I extended thread status data provider by some extent, but I was blocked by the way to use it:

Before this I was using default Control Flow Viewer to view my trace, if I want to define new visual element in the view, should I not only extend the ThreadStatusDataProvider but also extend the ControlFlowView, so as to create the expected features? If so, is there other thing I should take care of when creating this new view module? (it would be nice if there's a referable example, such as the view of another trace or a document, which one would you suggest to have a look?)

​I have this question because I look into the codes of ControlFlowView, its only constructor is taking the base presentation provider and default thread status data provider. So I think my provider cannot be used by the default one.

Best regards,


From: tracecompass-dev-bounces@xxxxxxxxxxx <tracecompass-dev-bounces@xxxxxxxxxxx> on behalf of tracecompass developer discussions <tracecompass-dev@xxxxxxxxxxx>
Sent: Thursday, May 7, 2020 8:56 PM
To: tracecompass developer discussions
Subject: Re: [tracecompass-dev] Question about visualizing thread-related events in TC incubator
Hi Yang,

The expected method to achieve this in the current framework would be to have you data provider (for Control Flow view: ThreadStatusDataProvider) implement IOutputAnnotationProvider.

The returned annotations would have a category, an entryId (representing the row, matching the model from fetchTree()), a time, and a style.

The style map should contain properties COLOR, SYMBOL_TYPE and HEIGHT. There are few built-in symbol types, like CIRCLE and SQUARE.

If you split your annotations into different categories you can turn them on or off independently in the view's "Show Markers" menu.

If you include those styles in the model returned by fetchStyle(), then you can have the user configure the color and height (and eventually, the symbol type) from the view's legend.


On Thu, May 7, 2020 at 1:28 PM tracecompass developer discussions <tracecompass-dev@xxxxxxxxxxx> wrote:


I'm currently developing a module to import and visualize trace data of a new format. 

The importing is successful, and I would like to know if it's possible to create thread-related events in the control flow view.

The question is this: the MyTrace class implements the IKernalTrace interface, and I make my layout extend the DefaultEventLayout.

The events types are now parsed as "sched_switch" and "sched_wakeup", while we want there to have events like "wait" "notify" "lock/unlock" etc. 

It would be good if there could add a circle or square element as the picture draws, to denote the events such as lock/unlock, is it possible?

We are currently using the control flow view for this, can our expectation be achieved by developing upon this model? 

but perhaps someone already created a specific view that is better suited?​ 

Looking forward to your reply and Best regards,

tracecompass-dev mailing list
To unsubscribe from this list, visit

Back to the top