In your regex, match the keyword "function". The keyword is used for function in C.
Not in any version of C that I have seen.
Try a profiler instead: see your compiler documentation, often the -p option. See also prof(1) or gprof(1), sprof(1) for .so files. | [reply] |
If my assumption is correct
You meant , apart from normal C code, we had to put additional comments on the start of the function like
/* Function : main
Purpose: ..
Author: ..
*/
void main()
{
...
}
and identify the functions depending upon the comments.
You should have given a code example, otherwise this would lead to confusion
UPDATE
this was reply to irah's post, not directly to onkar's post.
I just clarified what irah was trying to say
Vivek
-- In accordance with the prarabdha of each, the One whose function it is to ordain makes each to act. What will not happen will never happen, whatever effort one may put forth. And what will happen will not fail to happen, however much one may seek to prevent it. This is certain. The part of wisdom therefore is to stay quiet.
| [reply] [d/l] |
No, its like
int main(){
printf("In - %s%d%s\n",__FILE__,__LINE__,__func__);
....do something here ....
printf("Out -%s%d%s\n",__FILE__,__LINE__,__func__);
return 0;
}
in all the functions in the large code base containing at least 10000 functions like the Linux Kernel source ....
Regards,
Onkar
| [reply] |