On Page 6 of my paper on Named Return Value Optimisation:http://www.virjacode.com/downloads/nrvo/paper_nrvo_latest.pdf
I place a UUID on the stack alongside data which is to be retrieved
later. Basically it's a universal way of implementing thread-local
storage. So if I want to have a thread_local variable called 'abc',
then my strategy is that at every thread entry point, I place the UUID
on the stack beside the four bytes 'a' 'b' 'c' '\0' followed by the
bytes denoting its value. Then later in the program's execution I can
walk the stack backwards til I find the UUID and then I have access to
my thread-local data.
I can use the function "alloca" at runtime to create more thread-local
But more to the point: We should have control of stuff in C++. Every
C++ platform has a stack, so give us access to it. Just because I can
only come up with one good use for it now doesn't mean someone else
won't come up with a use for it later.