Community support for Analyzers (Intel VTune™ Profiler, Intel Advisor, Intel Inspector)
4922 Discussions

Problem getting VTune to instrument code with a custom kernel...



With a standard Redhat Enterprise 3.0WS installation running on a Pentium M, using a Sampling Activity, I have successfully analysed an object file (testProgram.o). I can drill down into this object and see in which functions the CPU is being spent etc...

My problem is that after creating a custom kernel, VTune can no longer instrument this object file. It seems to have categorised it under the "other32" module. I've rebuilt the kernel again with the gcc -g option enabled in the top level Makefile under CFLAGS and CFLAGS_KERNEL but this seems to have had no effect.

I ran the /opt/intel/vtune/vdk/src/build-kernel script which reported that the sampling driver failed to build successfully, but there was no apparent warnings/errors reported. Running the build-driver script from the same directory passes.

Are there any specific kernel options that I should have enabled for this to work?

Any help you can give would be appreciated.


0 Kudos
1 Reply
Any time you change the kernel, you will need to rebuild the driver (build-driver script) as root. If this succeeds, the driver will be loaded (use 'lsmod' and look for a driver witha name that starts with 'vtune_drv')and you can run a sampling activity.
An application module like testProgram.o should never show up in Other32, unless the driver does not match the kernel (that is what the build-driver script is for). However, without symbols for the kernel, you may see samples in Other32. Building the kernel with -g is all that should be required. Just make sure the symbols aren't stripped in the finally link step of the build.
0 Kudos