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

I am still trying to get the lvalue / rvalue concepts so that I know
exactly what to use when.

I have struct with a pointer member.

struct X {
 struct Y *base;
};

Now this pointer base can be updated while the function is running so
I need the value of the pointer refreshed (loaded) whenever it can
potentially change. In LLVM I emit explicit load instructions which
are then optimized so that any redundant loads are deleted. What would
be the equivalent method here? Should I just use a rvalue reference?
Will this be automatically refreshed? Should I use a local variable
and assign the value of the base pointer to it explicitly (i.e.
similar to explicit load) ?

Thanks and Regards

Dibyendu

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

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

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

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).