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

Release storage or not?


IBM Mainframe Forums -> IMS DB/DC
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
Daniel Prosser

New User


Joined: 05 Nov 2010
Posts: 57
Location: Amsterdam

PostPosted: Fri Apr 19, 2013 6:35 pm
Reply with quote

Hello,

I have a simple question really - at what point does IMS release the working storage allocated by a particular program/module.

We have a large transaction with a large calling chain, I would imagine that when a COBOL program in the calling chain returns control to the calling module the storage allocated is released.

Though this doesn't seem to be happening.

Can anyone point me in the right direction?

Dan. icon_cool.gif

icon_cool.gif icon_cool.gif icon_cool.gif
Back to top
View user's profile Send private message
charanmsrit

New User


Joined: 25 Oct 2007
Posts: 81
Location: Australia

PostPosted: Fri Apr 19, 2013 6:57 pm
Reply with quote

i am sure IMS experts will be able to provide the right answer.

Working in IMS environment for sometime now, my understanding is that the storage is released only after the transaction ends (UOW)
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Fri Apr 19, 2013 7:38 pm
Reply with quote

Unless you do a CANCEL in the COBOL program, a called subprogram will remain in memory until the end of the task (i.e., job if running in batch). This is standard and typical COBOL behavior; I doubt there's much difference due to IMS.
Back to top
View user's profile Send private message
Daniel Prosser

New User


Joined: 05 Nov 2010
Posts: 57
Location: Amsterdam

PostPosted: Mon Apr 22, 2013 12:35 pm
Reply with quote

Well it's an IMS transaction but I assume the principal is the same.

I'll have to look for a solution, thanks for your replies. icon_cool.gif
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Wed Apr 24, 2013 8:10 pm
Reply with quote

Daniel Prosser wrote:
I have a simple question really - at what point does IMS release the working storage allocated by a particular program/module.
Your program is "conversational" or "non-conversational". I know it's IMS DC question not CICS but that answer will help to get in some direction.
Back to top
View user's profile Send private message
Daniel Prosser

New User


Joined: 05 Nov 2010
Posts: 57
Location: Amsterdam

PostPosted: Thu Apr 25, 2013 12:36 pm
Reply with quote

Its conversational.

I thought that when you call a module (B) and control is returned to the calling module (A) the storage used by B is free'd.

Evidence seems to point the other way though.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Thu Apr 25, 2013 2:26 pm
Reply with quote

Click on the IBM Manuals link at the top of this page, find the Enterprise COBOL Language Reference manual and read section 5.1.3 on Local-storage. The behavior you seem to be expecting appears to be very similar to LOCAL-STORAGE, not WORKING-STORAGE.
Back to top
View user's profile Send private message
Daniel Prosser

New User


Joined: 05 Nov 2010
Posts: 57
Location: Amsterdam

PostPosted: Thu Apr 25, 2013 3:01 pm
Reply with quote

Thanks Robert, Your absolutely correct.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Thu Apr 25, 2013 6:00 pm
Reply with quote

Robert is correct. OTOH, for IMS/DC, if this program is a "conversational" - it'll have a SPA (Scratch Pad Area). In IMS/VS conversational processing, a work area in main storage or on direct access storage used to retain information from the application program for executions of the application program from the same terminal -- I believe, this is what you're calling as "working storage allocated by a particular program/module".

For a 'transaction', (pseudo conversational) program releases working-storage upon each event/PF key.

OTOH, SPA is an obselete concept now. Get rid of it, if you can.
Back to top
View user's profile Send private message
Daniel Prosser

New User


Joined: 05 Nov 2010
Posts: 57
Location: Amsterdam

PostPosted: Thu Apr 25, 2013 7:42 pm
Reply with quote

Thanks everyone. icon_cool.gif
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


Joined: 22 Apr 2006
Posts: 6250
Location: Mumbai, India

PostPosted: Fri Apr 26, 2013 10:50 am
Reply with quote

You're welcome and Good Luck! icon_smile.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 -> IMS DB/DC

 


Similar Topics
Topic Forum Replies
No new posts CLIST - Virtual storage allocation error CLIST & REXX 5
No new posts CICS vs LE: STORAGE option CICS 0
No new posts Insufficient Storage ABENDS & Debugging 7
No new posts Mass JCL release via IDZ tool(eclipse... CA Products 1
No new posts Interviewers are surprised with my an... Mainframe Interview Questions 6
Search our Forums:

Back to Top