IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Assembler debugging Tool


IBM Mainframe Forums -> PL/I & Assembler
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Fri Apr 01, 2005 10:38 am
Reply with quote

Can anyone let me know how to compile and debug a assembler code...what are the tools required for the same.
Back to top
View user's profile Send private message
narendar

New User


Joined: 20 Apr 2005
Posts: 1
Location: Mumbai

PostPosted: Wed Apr 27, 2005 11:26 am
Reply with quote

// JOB (XXX,xx),'',NOTIFY=&SYSUID,CLASS=2,
// MSGCLASS=Q,REGION=6500K
//*
//STEP010 EXEC PGM=ASMA90,PARM=(NOTERM,'LIST,NODECK,OBJECT'),
// REGION=2M
//SYSLIB DD DSN=SYS1.MACLIB,DISP=SHR
//* DD DSN=
//* DD DSN=
//SYSUT1 DD DSN=&&SYSUT1,UNIT=SYSDA,SPACE=(1700,(600,100))
//SYSUT2 DD DSN=&&SYSUT2,UNIT=SYSDA,SPACE=(1700,(300,50))
//SYSUT3 DD DSN=&&SYSUT3,UNIT=SYSDA,SPACE=(1700,(300,50))
//SYSGO DD DUMMY
//SYSPRINT DD SYSOUT=*
//SYSPUNCH DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSIN DD DISP=SHR,DSN=give the asm library
//SYSLIN DD DISP=(,PASS),DSN=&&STEP010A,SPACE=(CYL,(10,1)),
// UNIT=SYSDA
//*
//STEP020 EXEC PGM=IEWL,COND=(5,LT,STEP010),
// PARM=('XREF,LET,LIST,MAP'),REGION=2M
//SYSLIB DD DUMMY
//SYSLMOD DD DISP=SHR,DSN=give theload library.
//SYSUT1 DD SPACE=(1024,(120,120),,,ROUND),UNIT=VIO
//SYSPRINT DD SYSOUT=*
//SYSLIN DD DISP=(SHR,DELETE),DSN=&&STEP010A
// DD DDNAME=SYSIN
//SYSIN DD DUMMY

Y ou can use the above jcl to compile the code ..
and u can always debug the code bye looking in to spool the compilatio errors u have got.

after compiling u can run the load module .. and execute.. it.
Back to top
View user's profile Send private message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Thu Apr 28, 2005 9:00 am
Reply with quote

thanks narendra...for ur kind reply
Back to top
View user's profile Send private message
grepusr3

New User


Joined: 10 May 2005
Posts: 29

PostPosted: Tue May 10, 2005 8:17 am
Reply with quote

Mr. Kanak,

Compilation/syntax errors are easy to detect - as outlined above by narender. For run time (execution time) errors, you need to do what is known as dump reading. Generally most programs abend with register dumps (hexadecimal) and for small programs it is easy to calculate the offset of the offending instruction by inspecting the Aseembler Gen.

For large complex programs, use IPCS and the debugging handbooks to locate and interpret major MVS control blocks in a dump. In other words you have to trace the os blocks as mapped by IBM macros. Please see the IBM classic manuals "MVS Debugging handbooks". They are a great reference material for IBM Assembler. Unfortunately these books are IBM Licensed products (Lxxx-xxxx numbers) and are usually available to mainframe customers. Your work (employer) may have these collections.

I hope it helps!

-Pelad
Back to top
View user's profile Send private message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Tue May 10, 2005 9:37 am
Reply with quote

ok Pelad, i will check in my shop...anywz thanks for ur kind reply...if u have any reading materials on this topic, if you don't mind can u PM me..it will be great help for me..
thanks in advance
kanak
Back to top
View user's profile Send private message
grepusr3

New User


Joined: 10 May 2005
Posts: 29

PostPosted: Tue May 10, 2005 8:17 pm
Reply with quote

Here are some URLs for iBM documentation that are provided on the IBM Collection kit. They are in PDF format.

You may want to look at IPCS (Dump/Debug Analysis tool), Diagnosis and Data Areas. For OS/390 (or z/OS under other kit):
www-1.ibm.com/servers/s390/os390/bkserv/

Look at "OS/390 elements and features Adobe? Acrobat? PDFs" section below on page and Select your OS version - for eg. V2R6

Find it
- BookManager book
- Product bookshelf
- OS/390 elements and features messages and codes
[ V2R10 | V2R9 | V2R8 | V2R7 | V2R6 | V2R5 | V2R4 | V1R3 | V1R2 | V1R1 ]
- OS/390 elements and features Adobe? Acrobat? PDFs
[ V2R10 | V2R9 | V2R8 | V2R7 | V2R6 | V2R5 ]
- OS/390 software products Adobe Acrobat PDFs
- Other available Adobe Acrobat PDFs
[ Hardware | VSE | z/OS | z/OS software | z/VM ]



This will present you with page (Adobe Acrobat (PDF) versions of OS-390 V2R6 publications)
www-1.ibm.com/servers/s390/os390/bkserv/r6pdf/

Select link for MVS (MVS PDF files - OS-390 Version 2 Release 6)
www-1.ibm.com/servers/s390/os390/bkserv/r6pdf/mvs.html
and you'll see the list of IBM documentation.

For other applications doc, select from ( www-1.ibm.com/servers/s390/os390/bkserv/r6pdf/ )
OS/390 system level books
C/C++
High Level Assembler (HLASM)
Language Environment


You'll just have to navigate your way through these URLs for your respective OS and Application version.

Happy Reading

- Pelad
Back to top
View user's profile Send private message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Tue May 10, 2005 8:27 pm
Reply with quote

it is really a nice collection..even i tried alot before you have sent these links to search in IBM site..but all in vain..thanksa lot ...really great stuff provided by you..
thanks once again
Back to top
View user's profile Send private message
subhasis_50

Moderator


Joined: 09 Mar 2005
Posts: 363
Location: Earth

PostPosted: Wed May 18, 2005 2:11 pm
Reply with quote

Hi,
For Debugging the assembler code you can use the following tools.
1. Tracemaster
2. Dumpmaster

1. Tracemaster: If you want to debugg your code line by line basis for better understanding, then this utility is best.
I am giving you a PPT regarding assembler debugging.

2. Dumpmaster: This utility are used for solving abends. If any program gives some abends. In the command line write DM to start the Dumpmaster. In the spool u will get a file a called dumfile. As you code in your JCL as DDNAME SYSABEND OR SYSUDUMP. Give that file in the DM and it will show all the details. Which instruction is causing that abend. What are the values stored in that moment in the respective variables. Now from there u can pick up the offset value and go to the compiler listing of the program and get the instruction also.

Hope it will help you.
Back to top
View user's profile Send private message
kanak

Moderator


Joined: 12 Mar 2005
Posts: 252
Location: India

PostPosted: Wed May 18, 2005 2:47 pm
Reply with quote

thanks subhasis...for ur kind help
Back to top
View user's profile Send private message
David P

Active User


Joined: 11 Apr 2005
Posts: 106
Location: Cincinnati Ohio

PostPosted: Wed May 18, 2005 2:54 pm
Reply with quote

Hi,
I believe these debugging tools are lincensed ones there fore may or may not be there on each and every istallation.

My suggestion for debugging an assembler source is to develope a good
understanding about the instructions and memory allocations for them.

To be able to get the problematic offset location using memory allocation
is the one I prefer.

regards,
David.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> PL/I & Assembler

 


Similar Topics
Topic Forum Replies
No new posts Error while running web tool kit REXX... CLIST & REXX 5
No new posts Build dataset list with properties us... PL/I & Assembler 4
No new posts Finding Assembler programs PL/I & Assembler 5
No new posts How Can I Recall a Migrated Data Set ... PL/I & Assembler 3
No new posts step by step trace 4 ISPF dialog call... TSO/ISPF 17
Search our Forums:

Back to Top