Replies: 2 comments
-
Which is possible already if you inline the function being called to the function calling it, now you have the same stack, so it can be preserved |
Beta Was this translation helpful? Give feedback.
0 replies
-
It's still the same as in #62127 (and the same answers) for
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Recently I've written an algorithm that does so much math I wanted to just returned the bytes I've allocated in the stack for performance reason but I can't find a way to do it without copying to heap, or returning by values.
The stack allocated memory will change, I know I can probably hack it by returning a struct that has 256 single byte variable and a length that tells how much of them were the values actually returned, I could probably use a shared memory passed in from the parameter, but also would be nice if I can get a pointer to this memory allocated in the stack and make sure it doesn't get destroyed.
Beta Was this translation helpful? Give feedback.
All reactions