linux - Can i use gcov for kernel modules without recompiling the whole kernel? -


i have ubuntu os , installed gcov in it. able use gcov c-program in user space , getting desired results. when want use gcov .ko files(kernel space) getting error. googled , below mentioned link found have recompile whole kernel enabling config_debug_fs, config_gcov_kernel, config_gcov_format_autodetect , config_gcov_profile_all.

http://techvolve.blogspot.in/2014/03/how-to-gcovlcov-for-linux-kernel-modules.html

do have other way integrate gcov kernel loadable modules without recompiling kernel? if more information required end please let me know. update it. thank you

without support linux kernel core cannot collect coverage kernel module. so, if current kernel has no such support, have recompile it.


config_gcov_profile_all isn't needed coverage kernel module, other configuration options needed:

  • config_gcov_kernel - enables coverage counters in kernel space,

  • config_debug_fs - enables debugfs filesystem, way extract counters user space,

  • config_gcov_format_autodetect - describes format of collected coverage (you may chose configuration option selects specific format instead of autodetecting).


Comments

Popular posts from this blog

PHP and MySQL WP -

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

go - golang pprof for c library code -