HPE Community read-only access December 15, 2018
This is a maintenance upgrade. You will be able to read articles and posts, but not post or reply.
Hours:
Dec 15, 4:00 am to 10:00 am UTC
Dec 14, 10:00 pm CST to Dec 15, 4:00 am CST
Dec 14, 8:00 pm PST to Dec 15, 2:00 am PST
cancel
Showing results for 
Search instead for 
Did you mean: 

Debugging??

 

Debugging??

Hi All,

i have a C program(which is compiled & linked with /debug) which is linked via a shareable image. Now I'm able to debug this C program & successfully exit from the debugger. But this C program in turn calls the routines defined thru the shareable image. And that routine is returning a different value & i need to find that.

example:

code = shareable_routine(x1,x2,x3);

The problem here is I'm not able to STEP/INTO that particular routine( Actually i don't lnow how to do that).Even though i have the complete source code of the shareable image, i dont know how to set up that.

Please help me out!!!

Thanks,
/Manesh

2 REPLIES
Bojan Nemec
Honored Contributor

Re: Debugging??

Manesh,

If you have the complete source code of the shareable image, compile and link this image with /debug. After that you can debug also the shareable part.
If you define a logical name pointing to the shareable image linked with the debugger it can stay in a different directory or/and have a different name.

To set a breakpoint or examine symbols from the shareable image use:
DBG> SET IMAGE shareable_image

Bojan
Robert Gezelter
Honored Contributor

Re: Debugging??

Manesh,

In addition to Bpjan's direct comment, I will add that time spent with the Debugger manual will pay extremely large dividends.

The OpenVMS Debugger is a very powerful utility. In addition to SET IMAGE, there are other commands that would also be useful in debugging a problem with a shareable image (since this often involves repeated debugging sessions, I also recommend the use of a initialization file referenced using the DBG$INIT logical name).

Using the full power of the debugger can save many hours of laborious work, and is well worth the effort.

- Bob Gezelter, http://www.rlgsc.com