McKown, John wrote:
-----Original Message-----
From: IBM Mainframe Discussion List [mailto:[email protected]] On Behalf Of Steve Comstock
Sent: Tuesday, July 07, 2009 9:44 AM
To: [email protected]
Subject: Re: Question about REUS=NONE

<snip>

You need to be careful with dynamic call vs. attaching. Enterprise
COBOL programs can appear in a multitasking environment if they
are compiled with the THREAD option. Each task will have its own
copy of working-storage. COBOL programs cannot do the attach, but
they may be attached.


The COBOL manual mentions POSIX threading along with the THREAD option. I wonder if that means that a COBOL program could use the UNIX pthread services such as BPX1PTC to create a new pthread (similar to ATTACH, but different) and BPX1PTJ to wait for that thread to end (similar to WAIT on the ECB for ATTACH, but different).

<snip>

I thought about that, but I don't think it works; my
guess is that a COBOL program can't handle signal events
and there may be some other restrictions that make it
either impossible or unwieldy to drive multithreading
from a COBOL program.

Might make for some interesting testing though, although
I hope Tom Ross will chime in with his perspective and
insights.



Kind regards,

-Steve Comstock
The Trainer's Friend, Inc.

303-393-8716
http://www.trainersfriend.com

  z/OS Application development made easier
    * Our classes include
       + How things work
       + Programming examples with realistic applications
       + Starter / skeleton code
       + Complete working programs
       + Useful utilities and subroutines
       + Tips and techniques

==> Ask about being added to our opt-in list:              <==
==>   * Early announcement of new courses                  <==
==>   * Early announcement of new techincal papers         <==
==>   * Early announcement of new promotions               <==


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: GET IBM-MAIN INFO
Search the archives at http://bama.ua.edu/archives/ibm-main.html

Reply via email to