[PATCH] Allocate stack storage for .block_descriptor and captured self.

Eric Christopher echristo at gmail.com
Mon Feb 25 17:14:28 PST 2013


On Mon, Feb 25, 2013 at 5:02 PM, John McCall <rjmccall at apple.com> wrote:

> On Feb 25, 2013, at 4:55 PM, Adrian Prantl <aprantl at apple.com> wrote:
> > here’s another patch for review:
> >
> > Allocate stack storage for .block_descriptor and captured self.
> > This way the register allocator will not optimize away the the
> > debug info for captured variables.
>
> Allocating stack storage is not the right way to fix this problem.
> The frontend is emitting the right intrinsics to say that the argument
> is being kept in an LLVM value, not in memory.  If that's not working,
> then basically all optimized debug info is useless.
>
>
That's pretty accurate. The backend in a lot of places is depending upon an
alloca existing in order to get a location for a variable. To make optimized
debug info work we're going to need to fix that assumption.

-eric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130225/ee70b999/attachment.html>


More information about the cfe-commits mailing list