Identify control statements in source code
Joel Sherrill
joel.sherrill at oarcorp.com
Thu Aug 13 19:40:37 UTC 2015
On 8/13/2015 2:06 PM, Hermann Felbinger wrote:
> Hi all!
>
> I am working on a tool to analyze source code coverage for RTEMS.
> Currently I am looking for a tool to annotate source code such that I can extract information about statements and conditions that affect the control flow of a program.
> A similar tool exists for Ada programs. They call this information 'Source Coverage Obligations'. Some information about SCOs can be found in [1].
> I attached a program triangle.c which contains some if-statements. Each of these statements contains two or more conditions. The second attached file is the output of compiling triangle.c with
> gcc -O1 -fdump-tree-cfg -o triangle triangle.c
> This output is almost what I am looking for, but I think that there has to be something better out there.
>
> Does anybody of you know a tool which I can use to annotate source code?
As far as I know, there isn't anything comparable for C.
This would best be asked on the gcc at gcc.gnu.org mailing list with
me as a CC if you don't get an answer on this list.
> Best,
> Hermann
>
> [1] http://docs.adacore.com/gnatcoverage-docs/html/cov_source.html
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill at OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985
More information about the devel
mailing list