[lld] r181752 - [lld][LayoutPass] Fix a bug that caused buildbot to fail on some platforms.

Rui Ueyama ruiu at google.com
Mon May 13 20:43:35 PDT 2013


They failed to compile because of an unused variable if assertion is
disabled, so it was not really related to lld's functionality.


On Mon, May 13, 2013 at 8:08 PM, David Blaikie <dblaikie at gmail.com> wrote:

> On Mon, May 13, 2013 at 6:51 PM, Rui Ueyama <ruiu at google.com> wrote:
> > Author: ruiu
> > Date: Mon May 13 20:51:56 2013
> > New Revision: 181752
> >
> > URL: http://llvm.org/viewvc/llvm-project?rev=181752&view=rev
> > Log:
> > [lld][LayoutPass] Fix a bug that caused buildbot to fail on some
> platforms.
>
> Would it be possible/practical to add a test case that would fail on
> all platforms?
>
> >
> > Modified:
> >     lld/trunk/lib/Passes/LayoutPass.cpp
> >
> > Modified: lld/trunk/lib/Passes/LayoutPass.cpp
> > URL:
> http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Passes/LayoutPass.cpp?rev=181752&r1=181751&r2=181752&view=diff
> >
> ==============================================================================
> > --- lld/trunk/lib/Passes/LayoutPass.cpp (original)
> > +++ lld/trunk/lib/Passes/LayoutPass.cpp Mon May 13 20:51:56 2013
> > @@ -144,15 +144,16 @@ const DefinedAtom *LayoutPass::findAtomF
> >  bool LayoutPass::checkAllPrevAtomsZeroSize(const DefinedAtom
> *targetAtom) {
> >    const DefinedAtom *atom = _followOnRoots[targetAtom];
> >    while (true) {
> > -    AtomToAtomT::iterator targetFollowOnAtomsIter =
> _followOnNexts.find(atom);
> > -    // The target atom must be in the chain of its root.
> > -    assert(targetFollowOnAtomsIter != _followOnNexts.end());
> >      if (atom == targetAtom)
> >        return true;
> >      if ((*atom).size() != 0)
> >        // TODO: print warning that an impossible layout is being desired
> by the
> >        // user.
> >        return false;
> > +    AtomToAtomT::iterator targetFollowOnAtomsIter =
> _followOnNexts.find(atom);
> > +    // The target atom must be in the chain of its root.
> > +    assert(targetFollowOnAtomsIter != _followOnNexts.end());
> > +    atom = targetFollowOnAtomsIter->second;
> >    }
> >  }
> >
> >
> >
> > _______________________________________________
> > llvm-commits mailing list
> > llvm-commits at cs.uiuc.edu
> > http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130513/66e0cab5/attachment.html>


More information about the llvm-commits mailing list