H
hpoliset
I have a debugging question w.r.t core dumps with signal 4 Illegal
instruction messages.
I analyzed the core file through gdb. In simple english following is the
pattern observed:
I have an program with a piece of code -lets call it function1() that gets
called by different callers. This function is executed 1000 's of times as
while the binary is run and it works fine.
However, under some strange circumstances (which is not reproducable
consistently) if the call sequence happens to have a specific
function_root() in the stack, the binary crashed in function1() with a
signal 4 illegal argument exception. This never happens at the same place in
the code.
The crash stack looks as follows:
function1() {
...some code
......
.....
returncode = function2(.......); -------------------------> crashes on this
line
....
}
When I look at the code in function1 and beyond it looks all clean.
These are the following questions i have:
1) Is it posibble to identify from the core dump whether its a stack
corruption. what are the other posibbilities.
2) Is there any systematic process to be followed to identify the victim of
the corruption followed by the actual culprit
Please advice.
instruction messages.
I analyzed the core file through gdb. In simple english following is the
pattern observed:
I have an program with a piece of code -lets call it function1() that gets
called by different callers. This function is executed 1000 's of times as
while the binary is run and it works fine.
However, under some strange circumstances (which is not reproducable
consistently) if the call sequence happens to have a specific
function_root() in the stack, the binary crashed in function1() with a
signal 4 illegal argument exception. This never happens at the same place in
the code.
The crash stack looks as follows:
function1() {
...some code
......
.....
returncode = function2(.......); -------------------------> crashes on this
line
....
}
When I look at the code in function1 and beyond it looks all clean.
These are the following questions i have:
1) Is it posibble to identify from the core dump whether its a stack
corruption. what are the other posibbilities.
2) Is there any systematic process to be followed to identify the victim of
the corruption followed by the actual culprit
Please advice.