Hi, I'm working on the project along with Egon, and thank you in advance for your help. On 14:43, Tue 08 Aug, Ian Lance Taylor wrote: > gunman@xxxxxxxxx writes: > > We are wondering if it is possible to hook when the CFG is built in > > GCC, i.e. like it is done with lsm and the linux kernel. We are only > > aware of the GEM framework for doing this, but as we understand it, it > > is only possible to hook the preprocessor, AST, and the assembly code > > generation components of GCC. > > > > This is because we want to build a CFG which only include system calls > > to the kernel, i.e. we only want a CFG with basis-blocks containing > > system calls. > > You can, of course, edit the source code to do whatever you like. Of course, which is also an option we are considering. > If you mean: is there an API for adding CFG hooks such as you > describe, then the answer is no. We have, however, been thinking about just implementing another pass on the GIMPLE tree representation, once the Control Flow Graph have been created. Creating another pass is also an option, right? Or have I misunderstood something. Adding another pass just seems a lot easier than having to modify the GCC code in more complex ways. Regards, Lasse Bigum
Attachment:
smime.p7s
Description: S/MIME cryptographic signature