[PATCH] RC->contains is a trap... (PR16106)

Eric Christopher echristo at gmail.com
Wed Jun 12 12:36:06 PDT 2013


Off by one error. :) PR16105.
On Jun 12, 2013 12:31 PM, "Jakob Stoklund Olesen" <stoklund at 2pi.dk> wrote:

>
> On Jun 12, 2013, at 11:58 AM, Eric Christopher <echristo at gmail.com> wrote:
>
> > Hi Jakob and Lang,
> >
> > RC->contains is a trap for the register allocator since it tests the
> > presence of the register in the class, however, it ignores any
> > additions or removals done by an AltOrder and so shouldn't be used in
> > this situation. The greedy allocator uses AllocationOrder, but the
> > fast allocator doesn't and just grabs the order specifically when it
> > needs it.
> >
> > I see a few possible ways here:
> >
> > a) the patch I've got,
> > b) modify contains,
> > c) use AllocationOrder in the fast allocator,
> > d) something else (fix the hint? something?)
> >
> > At any rate contains should probably go away or something. It just
> > seems like a trap. I haven't audited all uses of contains throughout
> > the compiler, but this appears to be the only use in any of the
> > allocators.
> >
> > Thoughts?
>
> Is that the right PR#?
>
> /jakob
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20130612/04338695/attachment.html>


More information about the llvm-commits mailing list