Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

CICS and GO TOs, are there special considerations?

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS
View previous topic :: :: View next topic  
Author Message
jasorn

Active User


Joined: 12 Jul 2006
Posts: 153
Location: USA

PostPosted: Sun Jul 18, 2010 6:41 pm    Post subject: CICS and GO TOs, are there special considerations?
Reply with quote

I've had very little exposure to CICS in my career but one thing I've noticed is that some shops I've worked in shunned gotos except in CICS applications.

Before I go on, I don't want to rehash the goto debate here.

I'm just curious if gotos have a benefit in CICS which helps override the goto hater's fears. And if someone could point me to something on the matter of gotos as they relate to best practice in CICS applications. I know google is my friend but he's not cooperating with me on this one.

The only real discussion I've found on the matter is a small blurb in two books I have. The problem is the newer of those books is 18 years old and in my quick browsing I found some recommendations in them which google tells me are old techniques and not recommended any more.
Back to top
View user's profile Send private message

Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8055
Location: East Dubuque, Illinois, USA

PostPosted: Sun Jul 18, 2010 7:08 pm    Post subject:
Reply with quote

I don't think there's a whole lot of benefit -- the few CICS programs I've written in the last years have had no GOTO statements at all. There used to be something of a push to use GOTO over PERFORM due to the overhead of the PERFORM statement, but as machines have gotten faster that push has pretty much died out.
Back to top
View user's profile Send private message
jasorn

Active User


Joined: 12 Jul 2006
Posts: 153
Location: USA

PostPosted: Sun Jul 18, 2010 7:21 pm    Post subject:
Reply with quote

So a high performance application with sub second SLA's might still get a benefit from the GOTO over perform? So far this is the only reason anyone has offered to me outside the traditional arguments around GOTO EXIT for and against.

Robert Sample wrote:
There used to be something of a push to use GOTO over PERFORM due to the overhead of the PERFORM statement, but as machines have gotten faster that push has pretty much died out.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8055
Location: East Dubuque, Illinois, USA

PostPosted: Sun Jul 18, 2010 8:36 pm    Post subject:
Reply with quote

It might but considering z10 cycle times, I think the application would have to be pretty unusual to require GOTO over PERFORM. The main determinant of response times is going to be I/O -- which is still milliseconds versus nanoseconds for code execution.
Back to top
View user's profile Send private message
jasorn

Active User


Joined: 12 Jul 2006
Posts: 153
Location: USA

PostPosted: Sun Jul 18, 2010 8:43 pm    Post subject:
Reply with quote

Thanks, Robert. That's enough for me. I'll go without them and see how it goes.
Back to top
View user's profile Send private message
Bill O'Boyle

CICS Moderator


Joined: 14 Jan 2008
Posts: 2502
Location: Atlanta, Georgia, USA

PostPosted: Sun Jul 18, 2010 8:53 pm    Post subject: Reply to: CICS and GO TOs, are there special considerations?
Reply with quote

FWIW, HANDLE CONDITIONS, catering to multiple errors, expand into a GO TO DEPENDING ON statement. However, since the inception of the RESP keyword (or NOHANDLE), introduced with CICS/MVS 1.7, many applications have had the HANDLE CONDITION API's removed in favor of RESP/NOHANDLE. Also, HANDLE CONDITION API's generate an internal CICS GETMAIN.

Bill
Back to top
View user's profile Send private message
CICS Guy

Senior Member


Joined: 18 Jul 2007
Posts: 2150
Location: At my coffee table

PostPosted: Sun Jul 18, 2010 9:16 pm    Post subject: Re: Reply to: CICS and GO TOs, are there special considerati
Reply with quote

Bill O'Boyle wrote:
However, since the inception of the RESP keyword (or NOHANDLE), introduced with CICS/MVS 1.7, many applications have had the HANDLE CONDITION API's removed in favor of RESP/NOHANDLE.
Error handling became much better when the RESP keyword was added, but my only complaint is that I wish they had included a four byte field with the CICS abend code that would have been generated so I could issue the correct abcode if really needed......
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CICS All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts CICS Transaction Timeout Hooman24 CICS 2 Sun Apr 16, 2017 2:16 pm
No new posts Date and time format in CICS Chandru3183 CICS 2 Sat Mar 18, 2017 12:46 pm
No new posts Asynchronous CICS Processing Question moezbud CICS 1 Mon Mar 06, 2017 6:13 pm
No new posts CICS Question RE: Browse, Readnext an... moezbud CICS 7 Sun Mar 05, 2017 5:45 am
No new posts how to send just 10 rows in a CICS sc... Megha Gupta CICS 5 Thu Feb 23, 2017 6:57 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us