This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: duplicate body remover


Li Guanglei <guanglei@cn.ibm.com> writes:

> [...]  today when I tried to shrink the size of the generate .c file
> from stap,

The biggest current source of repetition is the entry- and
registration-related functions, not the final probe handlers or
auxiliary functions.  I'm close to checking in a major improvement on
this front.

> [...]
> +    if(typeid(*statements[i])==typeid(null_statement))

(We try to avoid run-time typing checks like that - it indicates poor
OO design.)

While your code does shrink pass-2 output, as David said, it is almost
certainly unnecessary given the pass-3-level duplicate elimination for
probe handlers.


- FChE


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]