[haiku-development] Re: Debugging help

  • From: "Dale Cieslak" <dmarc-noreply@xxxxxxxxxxxxx> (Redacted sender "dcieslak" for DMARC)
  • To: "haiku-development@xxxxxxxxxxxxx" <haiku-development@xxxxxxxxxxxxx>
  • Date: Sat, 22 Apr 2017 06:12:14 +0000 (UTC)

Hi Adrien,
That might actually be just the help I needed.  I'm working on 
https://dev.haiku-os.org/ticket/11518, and when I was trying to use the ;
userland Debugger, there was no symbol info once my code got into the app 
server.  I assumed it was part of the kernel and I'd have to use the KDL.  
If the app server is not part of the kernel then it definitely sounds like 
building it in debug mode might be exactly what I need to trace my issue,  I 
will give that a try. 
Thanks, and sorry for being confusing.

Regards,Dale


      From: Adrien Destugues <pulkomandy@xxxxxxxxxxxxx>
 To: haiku-development@xxxxxxxxxxxxx 
 Sent: Friday, April 21, 2017 10:53 PM
 Subject: [haiku-development] Re: Debugging help
   
On Sat, Apr 22, 2017 at 05:07:36AM +0000, Dale Cieslak wrote:

Hi All,
I have code that's hanging, and I can't figure out what to do about it.  I 
read the "Welcome to Kernel Debugging Land" article, and so I can see that 
the thread is "waiting" and there's a cvar, and the cvar says "READ FAULT" 
but I'm kind of stuck there.  I've gone over and over my code and it looks 
identical to similar pieces of code in the App server... is there more 
information somewhere about how to debug the kernel?  I'm stuck and would 
appreciate any tips on how to find out what the actual root of the issue is.  
Do I need to lock something?  Or unlock something?  Or just re-read the 
kernel debugging article?  Any ideas would be greatly appreciated!

Hi,

What kind of code are you working on? You talk about app_server, but then
go on with the kernel debugger. app_server does not run inside the
Kernel, so it would seem more appropriate to use the userland Debugger.

Of course, if app_server is freezing, it is not easy to run the Debugger
GUI. However, you can also use it from the command line. And you can
even do that through an ssh connection, which should still work if you
only locked the app_server and not the Kernel. The userland Debugger is
a little more user friendly, so if it is possible to use it this way,
I'd recommend that.

You can build app_server in debug mode (using SetConfigVar DEBUG ... in
your USerBuildConfig, there are examples in
build/jam/UserBuildConfig.*). This way the Debugger (but not the KDL)
will give you a lot more information.

-- 
Adrien.



   

Other related posts: