On 13/03/11 23:27, Marc Chametzky wrote:
Purely out of interest, how would I diassemble a DEC C routine on
VAX/VMS? Can I use DEBUG to do this?
Yes, you can use DEBUG for this.
If I remembered how to use the VMS debugger better, I'd give you more detailed
information, but what you can do is set a breakpoint at the strcpy(), and then STEP/INTO
to go into DECC$STRCPY. Since there's no source for it, DEBUG will show you the VAX
instructions.
Let me see what I can do. Warning: I'm very, very rusty! :-)
Okay, I compiled and linked the program /DEBUG.
Then, I ran the program and stepped to the strcpy() line.
I used "SET MODE SCREEN" to enable full-screen debugging and then "DISP
INST AT RH1" to put the VAX instructions on the screen next to the source.
Using "SET STEP INST" will step by instructions instead of source lines. You can
then use "STEP/INTO" to step into the RTL and see the instructions as you step
through it.
Without symbols in DECC$SHR, you're probably not going to get much out of it, but at
least you can see what's there.
--Marc
Thanks for all the suggestions! I half guessed using DEBUG in this case might be the
easiest solution for me, I was more rusty in not remembering any of the commands.
Regards, Mark.