- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I wish to write code like, with nested style
__itt_event grandpa = __itt_event_create( "grandpa", 7 );
__itt_event dad = __itt_event_create( "dad", 3 );
__itt_event son = __itt_event_create( "son", 3 );
{
__itt_event_start(grandpa);
//....lots of function calls
{
__itt_event_start(dad);
//....lots of function calls
{
__itt_event_start(son);
__itt_event_end( son);
}
__itt_event_end( dad);
}
__itt_event_end( grandpa);
}
and hope to view the profile result in tree view
+grandpa-----10ms
----+dad------8ms
----son--6ms
----others-2ms
----others---2ms
is it possible to do that, or can u add in the future version?
Link Copied
3 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes. Please see simple examplebelow -Please note that you use users nested events, and observe the results in time line, not in tree view#include "libittnotify.h"
__itt_event mark_event = __itt_event_create( "User Mark", 9 );
if( mark_event == __itt_event_err )
return err;
__itt_event frame_event = __itt_event_create( "Frame Completed", 15 );
if( frame_event == __itt_event_err ) return err;
...
int return_value; return_value = __itt_event_start( mark_event );
if( return_value == __itt_err ) report_error();
...
for( int f ; f{
return_value = __itt_event_start( frame_event );
if( return_value == __itt_err )
report_error();
do_stuff_for_frame();
return_value = __itt_event_end( frame_event );
if( return_value == __itt_err )
report_error();
}
return_value = __itt_event_end( mark_event );
if( return_value == __itt_err )
report_error();
-Peter
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi, thx for the reply.
I did integrate code in your example style, but the result is the user event in timeline is the same color.
I am a game developer, I'll insert more then 30 user events to profile, so in this case, if no tree view, it's a nightmare to check this.
is this(nested user event, and same color in time line with different names) all amplifier can do?
is there any way we can ask for this event view feature added in the future?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Yes, the user events can be seen only in timeline as Peter stated. Currently nested user events are not shown in tree view or different colors. Similar functionality can be added in future releases, maybe in some different API features. Could you please provide your view of the desired functionality in details?We will pass it to development team, so they can take it into account.

Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page