All Questions
Tagged with stack-unwinding stack
7 questions
1
vote
1
answer
51
views
the value does not change recursion during the stack unwinding
void reverseLinkedList(Node* &head)
{
if (head == nullptr || head->next == nullptr)
{
return ;
}
Node* Rest = head->next;
reverseLinkedList(Rest);
head-&...
-1
votes
1
answer
124
views
Does exception handling work if the throw block and landing pad are in diffrent section? [closed]
Consider below case, Which ends up crashing with unwinder complaining
_URC_END_OF_STACK and no handler found in _UA_SEARCH_PHASE
class array{
public:
int foo() {
throw 5;
}
};
int main() {
...
0
votes
0
answers
122
views
how dwarf format caculate provious sp pointer
this is example is from dwarf document.
How Can I caculate provious sp(r7) pointer,I mean It didnot save sp somewhere since sp is a callee-save register.
The architectural ABI committee specifies that ...
2
votes
2
answers
68
views
Why program cannot reach proper return instruction after stack unwinding?
Compiler: g++ 9.2.0
Operating system: Windows 10
g++ call:
g++ -E main.cpp -v -o main.i
g++ -c main.cpp -v -o main.o
g++ main.o -v -o main.exe
main.exe
main.cpp:
#include <chrono>
#...
3
votes
0
answers
301
views
During C++ stack unwind during exception, where is local exception value stored
I am familiar with the mental model of a C++ exception, and how it can be controlled programatically. For example, everything in this answer :SO Question on topic
What bewilders me, however, is how ...
1
vote
3
answers
172
views
Why are the fields of the class automatic objects?
During my studing exeption's mechanism I found that there are calls of destructors for fields of the object while stack's unwinding. Let me explain explicitly:
class X
{
File_ptr aa;
Lock_ptr bb;
...
1
vote
5
answers
469
views
Pointer validity after stack unwinding
In C++ does a pointer remains valid after stack unwinding or not?