[cfe-dev] Gobal register variables marked local
Renato Golin
renato.golin at linaro.org
Thu May 15 13:51:37 PDT 2014
On 14 May 2014 17:40, Reid Kleckner <rnk at google.com> wrote:
> What about making a new LValue type that doesn't have an address? At the
> source level, current_stack_pointer is an lvalue that can be stored to. If
> we ever want to add support for the 'register' class specifier as it was
> originally designed, we will need a new 'Register' LValue type that can be
> read from and stored to. We probably don't want to do that, but it feels
> like the right model to me.
Hi Reid,
I think I got it. Creating a new type of LValue wasn't that much
invasive after all, though I don't know how folks feel about it.
Attached is a patch that makes it work (but breaks other things and
has more hacks than I'd consider healthy). Can you have a look and see
if that's (more or less) what you had in mind? If that's the right
angle, I'll fix the bugs and add some tests.
cheers,
--renato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: named-regs.patch
Type: text/x-patch
Size: 12316 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20140515/3e9bf136/attachment.bin>
More information about the cfe-dev
mailing list