[LLVMdev] Debug Info and DFSan
peter at pcc.me.uk
Tue Oct 7 17:15:31 PDT 2014
On Tue, Oct 07, 2014 at 04:10:08PM -0700, David Blaikie wrote:
> On Tue, Oct 7, 2014 at 3:41 PM, Peter Collingbourne <peter at pcc.me.uk> wrote:
> > On Tue, Oct 07, 2014 at 03:30:49PM -0700, David Blaikie wrote:
> > > On Tue, Oct 7, 2014 at 2:51 PM, Peter Collingbourne <peter at pcc.me.uk>
> > wrote:
> > >
> > > > Looks good, thanks!
> > > >
> > > > Can you write the test case, please? You probably have more experience
> > > > writing debug info tests than I do.
> > > >
> > >
> > > Sure - though how would I get the pre-dfsan .ll file to produce this
> > > behavior? I've tried compiling to a .ll file without dfsan, then feeling
> > > that .ll through opt -dfsan, and I got different output. Instead of
> > > wrapping main, it just replaced it. Is there some attribute or other
> > thing
> > > the frontend is adding to ensure main is wrapped, rather than converted?
> > The pass takes an ABI list file, which in this case needs to contain the
> > following two entries in order to tell the pass that main is
> > uninstrumented:
> > fun:main=uninstrumented
> > fun:main=discard
> > Please take a look at the test/Instrumentation/DataFlowSanitizer/abilist.ll
> > test case for an example of how to specify an ABI list (you only need the
> > -dfsan-abilist flag).
> Lovely. Committed in r219249.
More information about the llvm-dev