[cfe-dev] Gobal register variables marked local
Renato Golin
renato.golin at linaro.org
Fri May 9 10:19:09 PDT 2014
On 9 May 2014 18:14, Reid Kleckner <rnk at google.com> wrote:
> Please don't make VarDecl ~4 bytes bigger just to support a rarely used gnu
> extension.
Hi Reid,
As I said, that's just a marker to help me find the right decl while
debugging. I wouldn't leave it in the final patch.
> I think it might be better to model the asm blob as an initializer, which
> would save space and fix your tentative definition problems.
The problem is that this "variable" will never be properly initialized
because it only refers to access to a register. So, what I need to do
is to keep the VarDecl around, maybe even lying about it's
initialization status, and detect that the variable is a named
register (SC_Register + AsmLableAttr) and emit the intrinsic instead.
I'm looking for the common place where all the reads/writes to
variables get lowered, so that I only change in one/two place/s.
cheers,
--renato
More information about the cfe-dev
mailing list