I am using Clang to compile my Gem5 simulator program and my problem is that I am trying to instrument only some specific files but I am not succeeding. The command I am using to compile the program is the following:
clang++ -O2 -fprofile-instr-generate -fcoverage-mapping -fprofile-list=fun.list *.cc
being the content of fun.list:
src:/home/elvira.moreno/vanilla-gem5-testing-benchmark/src/arch/home/elvira.moreno/vanilla-gem5-testing-benchmark/src/arch/generic/debugfaults.hh
The debugfaults.hh file is the only one I want to instrument and get coverage information but all the files are instrumented though
I have also tried with the other version of the fun.lis file:
[clang]
source:/home/elvira.moreno/vanilla-gem5-testing-benchmark/src/arch/home/elvira.moreno/vanilla-gem5-testing-benchmark/src/arch/generic/debugfaults.hh=allow
default:forbid
And the same thing happens, any idea how to get only instrument that file?