I have a shared library compiled with -g -O0
including:
void MyClass::whatever()
{
...
doSomething(myImage, myPoints);
...
}
bool MyClass::doSomething(const Image& image, std::vector<cv::Vec2f>& points) const
{
const int32_t foo = 1;
const float bar = 0.1f;
...
}
Now I'm stepping through whatever()
with s
, but it doesn't step into doSomething()
, but over it. It's not a matter of source availability, because (1) it's in the same file and (2) I can set a breakpoint in doSomething()
and step there through the sources with no problem. But s
seems to believe that there is no source available.
If I set step-mode on
, I get output like
0xb5d51148 in myClass::doSomething (this=0xb25e4, image=...,
points=std::vector of length -91315, capacity 372871920 = {...})
from /path/to/myclass.so
like you get when there is no source available. After a couple of n
the foo
initialization is displayed with source.
So there could be some inline
magic from my parameter (an opencv
type, release build) put at the beginning of the function. Is it possible that gdb
sees this stuff, thinks "weird stuff, let's continue after this function" and doesn't find that there is really source availible for most of the function?
(If should matter, it's compiled with LLVM/clang 3.5 on an ARM box with Ubuntu)