Analyzers
Talk to fellow users of Intel Analyzer tools (Intel VTune™ Profiler, Intel Advisor)
5000 Discussions

Select Loops by Source File/Line Number

TestDR
Beginner
1,279 Views

Hi,

Ref: Intel Advisor 2023 user guide, page 393: Select Loops by Source File/Line Number

 

I am trying to offload a portion of a large application to GPU.  This portion containing a loop appears in separate compilation unit/source file from the main program.  My goal is to do offload modelling only for this portion of my application. I am following the instructions as below. But the Advisor is not focusing on the specified block of loop, rather it focus on the entire application. 

For Offload Modeling: Go to Project Properties > Performance Modeling and enter the CLI action
option --select=<string> in the Other parameters field. For example, --
select=foo.cpp:34,bar.cpp:192. 

 

Also, when the survey report, obtained from "advisor --report=survey --project-dir=./advi_results -- ./myApplication", does not show the loop ID for the loop want to offload

 

 Is it possible just to analyze a portion of a large application? If so, can you point me to an example? I have access to devcloud.

 

0 Kudos
9 Replies
Ruslan_M_Intel
Employee
1,233 Views

Hello,

 

I assume you are talking about "Enforce Offloading for Specific Loops" chapter from Advisor User Guide document. Having this option specified should do the trick indeed - you need to specify loop location to reduce analysis scope. You are saying that the option doesn't work and Advisor does analysis for whole app instead?

 

Best regards,

Ruslan 

0 Kudos
AthiraM_Intel
Moderator
1,155 Views

Hi,


We have not heard back from you. Did you try the suggestion given by Ruslan? Could you please give us an update?



Thanks


0 Kudos
TestDR
Beginner
1,141 Views

Hi,

Yes, the loop is not selected when specified the portion of source code. Also, when I run a survey, the loop id is not available for this specific loop I want to analyse. Is there a limit to the number of loops analysed by the Advisor?

Thanks

0 Kudos
Ruslan_M_Intel
Employee
1,127 Views

Hi,

 

No, there is no such limitation - Advisor profiles all found loops.  Please make sure that missing loops run long enough (10ms or more) -or- you can try to play with sampling interval instead (e.g. setting --interval=1 option makes sampling interval equal to 1ms). Could you please tell me which compiler do you use at the moment? (it is better to use Intel Compiler to build your application). Please make sure you enabled debug info (e.g. -g flag for linux version).

 

Best regards,

Ruslan

0 Kudos
AthiraM_Intel
Moderator
1,066 Views

Hi,


We have not heard back from you. Did you try the suggestion given by Ruslan? Could you please give us an update?



Thanks


0 Kudos
TestDR
Beginner
1,041 Views

Hi,

Minimum sampling interval of Intel Advisor is 1ms. Our application is very close to this sampling interval. I guess the offline analysis may not be accurate in this case.

Is my understanding correct?

Thanks

0 Kudos
Ruslan_M_Intel
Employee
993 Views

Hi,

 

That's right. Moreover, typical use case for Offload Modelling is quite big application execution time on CPU (e.g. few seconds or more). Otherwise there is no point in offloading because launch and data transfer taxes make offload "non profitable"

 

Best regards,

Ruslan

0 Kudos
AthiraM_Intel
Moderator
930 Views

Hi,


We have not heard back from you. Could you please give us an update? Is your issue resolved?



Thanks



0 Kudos
AthiraM_Intel
Moderator
881 Views

Hi,


We have not heard back from you. This thread will no longer be monitored by Intel. If you need further assistance, please post a new question.



Thanks


0 Kudos
Reply