Analyzers
Support for Analyzers (Intel VTune™ Profiler, Intel Advisor, Intel Inspector)
Announcements
This community is designed for sharing of public information. Please do not share Intel or third-party confidential information here.
4679 Discussions

Vtune cannot find setenv symbol even after being exported in the target binary

pbansal
Beginner
1,220 Views

Hello,

I am trying to profile statically linked binary using Vtune 2021.3.0 installed with oneapi kit.

I have build the application with the required switches i.e. -g, -O2 and  -Wl, -u__setenv. As you can see from attached image which is output of "objdump -x <target binary name> | grep setenv", __setenv symbol is exported to the binary.

However, when I am trying to profile this binary with Vtune with hotspot analysis with the following command, it still throws the following error:

vtune: Error: Valid setenv symbol is not found in the binary of the analysis target.

vtune: Error: Binary file of the analysis target does not contain symbols required for profiling. See the 'Analyzing Statically Linked Binaries' help topic for more details. I vtune -collect hotspots -search-dir=/usr/lib/debug/lib64  <path to binary>

I received the above error with the following command:

vtune -collect hotspots -search-dir=/usr/lib/debug/lib64  <path to binary>

where /usr/lib/debug/lib64 is the path to directory where the symbol libc-2.28.so.debug is located.

Could you please help on the above issue. 

Thanks,

Prakhar

 

0 Kudos
11 Replies
AthiraM_Intel
Moderator
1,196 Views

Hi,


Thanks for reaching out to us.


Could you please confirm whether the binary file exports all the symbols from system libraries as mentioned in the below documentation:

https://software.intel.com/content/www/us/en/develop/documentation/vtune-help/top/set-up-analysis-ta...


If the issue still persists, please share reproducer code and the complete steps you followed so that we can try out the same from our end.


Thanks.


AthiraM_Intel
Moderator
1,160 Views

Hi,


Could you please give us an update?


Thanks


pbansal
Beginner
1,133 Views

Hello,

Sorry for the delay in reply!

I verified that all the required symbols from the documentation on Analyze statically Linked Binaries on Linux* targets are exported to the target binary.

Please find the following steps to reproduce the issue at your end:

1) Download the Aerospike Database server from git repo:

git clone https://github.com/aerospike/aerospike-server.git

2) Please apply the attached patch(after extracting from zip) after cloning Aerospike into local repository to add required compiler switches:

git apply > <patch name>

3)  Build the server by following the steps in https://github.com/aerospike/aerospike-serverPlease do the default build.

4) Run vtune from the root of aerospike-server directory (Assuming vtune 2021.3.0 is installed) with path to asd binary for database server.

vtune -collect hotspots -search-dir=/usr/lib/debug/lib64   /target/Linux-x86_64/bin/asd,  where /usr/lib/debug/lib64 is the path to directory where the symbol libc-2.28.so.debug is located.

Above command will result in below error:

vtune: Error: Valid setenv symbol is not found in the binary of the analysis target.

vtune: Error: Binary file of the analysis target does not contain symbols required for profiling. See the 'Analyzing Statically Linked Binaries' help topic for more details.

Please let me know for any questions in reproducing the issue.

Thanks,
Prakhar

 

AthiraM_Intel
Moderator
1,114 Views

Hi,


Thanks for sharing the details. We will try the same from our end and let you know the updates soon.

Could you please let us know which OS you are using?


Thanks


pbansal
Beginner
1,107 Views

Hi,

I am using Linux with Centos 8 distribution on Intel's cascade lake server.

 

Thanks!

 

AthiraM_Intel
Moderator
1,088 Views

Hi,

 

Thanks. We are checking on it internally, will get back to you soon with an update.

 

Thanks.

 

DMITRY_T_Intel
Employee
1,046 Views

Hi Prakhar,

I escalated this issue to development. I will let you know as soon as I get any information.

Thank you!


pbansal
Beginner
969 Views

Hi,

 

Is there any update on this issue?

 

Thanks,

Prakhar

pbansal
Beginner
944 Views

Hi,

 

I'm still awaiting a reply on this issue. Is there any update?

 

Thanks!

pbansal
Beginner
912 Views

Hi,

 

Is there any update on this issue?

 

Thanks,

Prakhar

DMITRY_T_Intel
Employee
814 Views

Hi Prakhar,

Our developers told me that this issue was fixed in VTune Profiler version 2021.4.0. Meanwhile VTune Profiler version 2021.5.0 has been released and it can be downloaded from this page: https://software.intel.com/content/www/us/en/develop/articles/oneapi-standalone-components.html Please try it .

Thank you very much!


Reply