[llvm-commits] dependence analysis

Hal Finkel hfinkel at anl.gov
Thu Jul 26 14:58:11 PDT 2012


On Thu, 26 Jul 2012 14:33:36 -0700
Preston Briggs <preston.briggs at gmail.com> wrote:

> On Thu, Jul 26, 2012 at 2:26 PM, Hal Finkel <hfinkel at anl.gov> wrote:
> >
> > On Thu, 26 Jul 2012 12:28:43 -0700
> > Preston Briggs <preston.briggs at gmail.com> wrote:
> >
> > > I've written a dependence analyzer for LLVM. It's a fairly
> > > complete implementation of the paper
> >
> > Great!
> >
> > >
> > > Practical Dependence Testing
> > > Gina Goff, Ken Kennedy, and Chau-Wen Tseng
> > > PLDI 1991
> > >
> > >
> > > It lacks an MIV test and cannot yet propagate constraints between
> > > coupled RDIV subscripts (discussed in Section 5.3.2 of the
> > > paper). I expect to add these in the future.
> >
> > Sounds good.
> >
> > >
> > > It's organized as a FunctionPass with a single entry point that
> > > supports testing for dependence between two instructions in a
> > > function. If there's no dependence, it returns null. If there's a
> > > dependence, it returns a pointer to a Dependence which can be
> > > queried about details (what kind of dependence, is it loop
> > > independent, direction and distance vector entries, etc). I
> > > haven't included every imaginable feature, but there's a good
> > > selection that should be adequate for supporting many loop
> > > transformations. Of course, it can be extended as necessary.
> > >
> > > How do I go about getting it ready for check in?
> >
> > You'll need to send a patch to this list for review. Does it have
> > test cases?
> 
> It's currently 2 files, DependenceAnalysis.h and
> DependenceAnalysis.cpp I'm not sure how to organize these into a
> patch list.

Have you locally integrated them into LLVM's build system? If
you're asking for advice on use of svn/git, let me know, I'll be happy
to provide advice offlist.

> 
> I wrote a test driver that makes dependence queries along with 100+
> tests that exercise most everything.
> Again, I'm not sure how to organize all this into a format LLVM can
> use.

This sounds good. Are these tests setup internally (in C++), or are they
contained in LLVM files? How are the outputs represented/checked?

 -Hal

> 
> Thanks,
> Preston



-- 
Hal Finkel
Postdoctoral Appointee
Leadership Computing Facility
Argonne National Laboratory



More information about the llvm-commits mailing list