code gen for C string literals

Ian Lance Taylor iant@google.com
Tue Feb 15 19:42:00 GMT 2011


kevin diggs <diggskevin38@gmail.com> writes:

> I am asking if there is something like STRING_CST that the frontend
> will return for for global'ish (i.e. non-auto stuff that is found from
> locations other than the stack) data items that I can similarly search
> the code for.

No.  Unless you count MEM.

> P.S.:  If you would be so kind as to jot down a sentence or two as to
> what GIMPLE (some other frontends' tree?) is and how it relates to
> SIMPLE (C frontend tree representation) I would REALLY appreciate it!
> Ditto for something called SSA?

GIMPLE is the representation used by the middle-end.  GENERIC is the
tree representation used by the C and C++ frontends, and also used by
GIMPLE for operands and types.  Both the C and C++ frontends extend
GENERIC with frontend specific tree codes; thus, both frontends use a
tree representation, and GENERIC is the shared subset of their tree
representations.

SIMPLE is a different intermediate representation used by a different
compiler, which influenced the designed of GENERIC and then GIMPLE used
by gcc.

SSA is a compiler optimization technique which heavily influences the
design of the intermediate representation.  See
http://en.wikipedia.org/wiki/Static_single_assignment_form .

Ian



More information about the Gcc-help mailing list