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

Tracing the perform stack in Cobol


IBM Mainframe Forums -> COBOL Programming
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Wed Feb 17, 2010 7:39 pm
Reply with quote

A while back this question was posted in the Compuware forum:

How to find flow when the prog is abended in dump

The thread ended with no conclusion, and I would like to rephrase the question: Is there a common way to trace back the perform stack in a module?

An area in the DSA is designated Perform Save Cells, the location is listed in the compiler output, but do anyone know how to retrieve the return addresses for each perform from this area?

Doing some research on the topic I found this patent description(open the pdf-link), but it is based on s/370 MVS architecture, and I guess it cannot be taken as actual documentation of the architecture.

If a cookbook like method can be employed for this, it would be easier than to trace the condition variables in the program branches.
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 771
Location: Germany

PostPosted: Thu Feb 18, 2010 3:32 pm
Reply with quote

Morning Sir & Goddag !

I allway define a EyeCatcher area in my programms, Cobol and Assembler. In there, several Fields are defined to store the actual section-name. These fields discribe the hierarchical structure of the performs.

In case of abend, this is for example:

S00 S05 B05 B10

Means: actual section where abend occurs is B10
B10 was performed from B05
B05 was performed from S05
S05 was performed from S00

S00 is main-procedure of programm

I followed the very old SPL architecture of IBM and did it my own way.
I also codes some macros for section start and end, so that i can run my programms in a kind of trace-mode. That allows me to check the section flow during program run.

I think, every experienced guy of us has his own little helpers.

And, in fact of nothing helps, there must alway be a superb pleasant tempered bottle of red wine in immediate proximity.

Jeg ønsker dig en rigtig god dag
UmeySan
Back to top
View user's profile Send private message
kailas girase

New User


Joined: 20 Nov 2008
Posts: 6
Location: New Bombay

PostPosted: Thu Feb 18, 2010 3:33 pm
Reply with quote

For tracing control of programe thru different section I heard something below "In Environment Division, Source-Computer name given with debuging tool (xpeditor) should be used".

I have tried this but could not get expected results.

Can some clarify on this?
Back to top
View user's profile Send private message
UmeySan

Active Member


Joined: 22 Aug 2006
Posts: 771
Location: Germany

PostPosted: Thu Feb 18, 2010 3:41 pm
Reply with quote

@ kailas girase

Xeditor is a online debugging tool for Cobol ore Assembler.
You could debug your programm step by step and analyse the
content of variables and so on.

So you run your programm under the control of this debugging-software.

Hpe it helps.
Back to top
View user's profile Send private message
Kjeld

Active User


Joined: 15 Dec 2009
Posts: 365
Location: Denmark

PostPosted: Thu Feb 18, 2010 3:54 pm
Reply with quote

kailas girase wrote:
For tracing control of programe thru different section I heard something below "In Environment Division, Source-Computer name given with debuging tool (xpeditor) should be used".

I have tried this but could not get expected results.

Can some clarify on this?

The current version of Xpediter doesn't require you to make any modifications to the source code in order to use the tool.

You need to have the source support data generated for your source at compile time, but I think most shops do this when setting up Xpediter, so source support will be enabled by default.

UmeySan wrote:
I think, every experienced guy of us has his own little helpers.

That is true, but as I often am consulted on debugging legacy code, I was looking for a more general method. Men tak for hjælpen icon_cool.gif
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 -> COBOL Programming

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
No new posts Calling DFSORT from Cobol, using OUTF... DFSORT/ICETOOL 5
No new posts How to get a stack trace on a looping... ABENDS & Debugging 5
Search our Forums:

Back to Top