- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
it is clear how to use cilkview in a c function. One just places cilkview.h in the include file secton, put __cilk_data_t start in the file defintion section of the c function. Finallly, puting __cilkview_query(strat); in the line above the cilk_for loop and at the end put __cilkview_report(&start,NULL,"title",CV_REPORT_WRITE_TO_RESULTS); at the bottom ogf the file.
NowI attempting to speed up only with cilk_for's, andI have set up each function as I have shown above.
But,I want to check to the contributionof each cilk_for and there may be more than one cilk_for in a function. All,I can do is check the whole function, noteach cilk-for.How do I do the latter.
Thanks in advance.
Newport_j
Link Copied
1 Reply
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello,
only code executed between __cilkview_query(...) and __cilkview_report(...) will be analyzed.
So, why don't you just enclose one for-loop by those two statements, e.g.:
[cpp]void foo() { ... cilk_for(...) { } ... __cilkview_query(...); cilk_for(...) { } __cilkview_report(...); }[/cpp] ...to just analyze the second for-loop.
Of course you need to make sure you don't mix the results of multiple invocations of the function (here: foo())! You can do this by either bailing-out early after having the first report or by using different tags.
Best regards,
Georg Zitzlsberger
only code executed between __cilkview_query(...) and __cilkview_report(...) will be analyzed.
So, why don't you just enclose one for-loop by those two statements, e.g.:
[cpp]void foo() { ... cilk_for(...) { } ... __cilkview_query(...); cilk_for(...) { } __cilkview_report(...); }[/cpp] ...to just analyze the second for-loop.
Of course you need to make sure you don't mix the results of multiple invocations of the function (here: foo())! You can do this by either bailing-out early after having the first report or by using different tags.
Best regards,
Georg Zitzlsberger
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