public inbox for jit@gcc.gnu.org
 help / color / mirror / Atom feed
* Labeling of blocks and locals
@ 2015-01-01  0:00 Dibyendu Majumdar
  2015-01-01  0:00 ` David Malcolm
  0 siblings, 1 reply; 5+ messages in thread
From: Dibyendu Majumdar @ 2015-01-01  0:00 UTC (permalink / raw)
  To: jit

It seems that if a name is supplied to a block it is translated as a
label - but then if the same name is supplied to two blocks the labels
show up as the same.

In LLVM the block labels are automatically made unique - the user
supplied name is suffixed with a unique integer value. This is useful
as one can use meaningful labels without having to worry about making
the labels unique.

As it stands I would have to ensure unique label names before I could use them.

A similar question involves naming of locals. When I declare a local
and assign it a name - the name is not made unique. During code
generation whenever certain types of statements are processed, local
variables may be generated. These are given the same name - in LLVM
the names are automatically made unqiue, but I notice that in
libgccjit this is not so.

Of course I can work around this by creating unique label and local
names myself but that is an unnecessary pain.

Is it possible to consider changing this behaviour?


Thanks and Regards
Dibyendu

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-06-15 20:09 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-01-01  0:00 Labeling of blocks and locals Dibyendu Majumdar
2015-01-01  0:00 ` David Malcolm
2015-01-01  0:00   ` Dibyendu Majumdar
2015-01-01  0:00   ` Dibyendu Majumdar
2015-01-01  0:00     ` David Malcolm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).