Re: CEETBCK and LE conforming assembler
Concerning the note, I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK Every time this question comes up and this happens every month or so (or something similar) I tell posters that you should submit an IBM REQUEST (via marketing and reference the existing SHARE requirement: SSLNGC0313587 - New LE Callable Service to get (various) Program Names A new LE callable service (with capabilities well beyond CEE3GRN) should be created to obtain various program names. This should include options to obtain: - The currently executing program's name - The name of the program that activated (Called, Invoked, whatever) the currently executing program - The name of the program at the top of the current LE enclave - The name of the program at the top of the current LE thread For each of these, sub-options may be required to provide information such as - Any alias by with the program was entered - Any long-name (with mixed characters) as supported by the Binder - Any Entry-point name when other than the modules name Finally, although not necessarily a part of this callable service, it would also be desirable to be able to obtain the data set name (HFS, PDS, PDSE, LPA member, or whatever) from which each of these entities was obtained. *** This SHARE requirement was submitted to IBM in 2003. The need for this functionality comes up repeatedly in IBM-MAIN (and similar forums), but until/unless IBM customers communicate to IBM thru official channels that this is IMPORTANT for IBM to provide a solution to, I don't think they will actually do so. Please, PLEASE, Even if/when you do find a work-around make certain that your business needs are communicated to IBM. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
On 1/28/2011 10:33 AM, Brad Wissink wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. I'm unclear on where your Assembler program would stand in the call heirarchy. It sounds like your Assembler program is supposed to be sort of an observer. But how is it invoked? It can't sit between the caller and the callee, because then it becomes the callee. I wouldn't be too exicited about CEETBCK, which is documented in the LE Vendor's Interfaces guide as a compiler writers interface. Or is this program supposed to gather this information later from, say, SMF or log records? Some more detail of what you're trying to accomplish would certainly help. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
The order would be that the originating Cobol program would call another Cobol program. The called Cobol program wants to know who called it because it can be called from many different programs. The called Cobol program would then call my assembler program which would traverse back though the called chain using CEETBCK and report back who called it. Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 11:50 AM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 10:33 AM, Brad Wissink wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. I'm unclear on where your Assembler program would stand in the call heirarchy. It sounds like your Assembler program is supposed to be sort of an observer. But how is it invoked? It can't sit between the caller and the callee, because then it becomes the callee. I wouldn't be too exicited about CEETBCK, which is documented in the LE Vendor's Interfaces guide as a compiler writers interface. Or is this program supposed to gather this information later from, say, SMF or log records? Some more detail of what you're trying to accomplish would certainly help. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
On Fri, Jan 28, 2011 at 11:10 AM, Wissink, Brad [ITSYS] bjwi...@iastate.edu wrote: The order would be that the originating Cobol program would call another Cobol program. The called Cobol program wants to know who called it because it can be called from many different programs. The called Cobol program would then call my assembler program which would traverse back though the called chain using CEETBCK and report back who called it. Brad can you provide some additional information regarding what is meant by 'who called it'. Here are some specific questions. 1) the immediate predecessor (caller)? 2) the entire calling chain? 3) the name of the calling program according signature bytes put in the object code by the compiler? 4) In the case of caller that was dynamically loaded, the name of the program located in the CDE control blocks? 5) If running in a multithreaded situation, do you need to get back past the current TCB? Cheers, Sam Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 11:50 AM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 10:33 AM, Brad Wissink wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. I'm unclear on where your Assembler program would stand in the call heirarchy. It sounds like your Assembler program is supposed to be sort of an observer. But how is it invoked? It can't sit between the caller and the callee, because then it becomes the callee. I wouldn't be too exicited about CEETBCK, which is documented in the LE Vendor's Interfaces guide as a compiler writers interface. Or is this program supposed to gather this information later from, say, SMF or log records? Some more detail of what you're trying to accomplish would certainly help. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
I think I am after #1. Cobol program A dynamically calls Cobol program B. Now I need a way for Cobol Program B to find out it was called by Cobol program A. I was going to use CEETBCK to do this. Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Sam Siegel Sent: Friday, January 28, 2011 1:32 PM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On Fri, Jan 28, 2011 at 11:10 AM, Wissink, Brad [ITSYS] bjwi...@iastate.edu wrote: The order would be that the originating Cobol program would call another Cobol program. The called Cobol program wants to know who called it because it can be called from many different programs. The called Cobol program would then call my assembler program which would traverse back though the called chain using CEETBCK and report back who called it. Brad can you provide some additional information regarding what is meant by 'who called it'. Here are some specific questions. 1) the immediate predecessor (caller)? 2) the entire calling chain? 3) the name of the calling program according signature bytes put in the object code by the compiler? 4) In the case of caller that was dynamically loaded, the name of the program located in the CDE control blocks? 5) If running in a multithreaded situation, do you need to get back past the current TCB? Cheers, Sam Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 11:50 AM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 10:33 AM, Brad Wissink wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. I'm unclear on where your Assembler program would stand in the call heirarchy. It sounds like your Assembler program is supposed to be sort of an observer. But how is it invoked? It can't sit between the caller and the callee, because then it becomes the callee. I wouldn't be too exicited about CEETBCK, which is documented in the LE Vendor's Interfaces guide as a compiler writers interface. Or is this program supposed to gather this information later from, say, SMF or log records? Some more detail of what you're trying to accomplish would certainly help. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
On 1/28/2011 2:14 PM, Wissink, Brad [ITSYS] wrote: I think I am after #1. Cobol program A dynamically calls Cobol program B. Now I need a way for Cobol Program B to find out it was called by Cobol program A. I was going to use CEETBCK to do this. Brad Wissink Information Technology Services Iowa State University 515-294-3088 I don't know if you have any say in the matter, but this is a really bad design. Presumably program B intends to work differently if called by program A. There are really two ways to do this correctly: 1) have the calling parameters for invoking program B contain some kind of a processing indicator; or, 2) create two separate programs and call the correct one from the calling program. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
We are using this information for logging and audit purposes. We are creating an interface program that may be called by hundreds of other programs. We were looking for a simple way to log which program called the interface program just in case that type of information would be needed if the interface program abended or had problems. Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 3:21 PM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 2:14 PM, Wissink, Brad [ITSYS] wrote: I think I am after #1. Cobol program A dynamically calls Cobol program B. Now I need a way for Cobol Program B to find out it was called by Cobol program A. I was going to use CEETBCK to do this. Brad Wissink Information Technology Services Iowa State University 515-294-3088 I don't know if you have any say in the matter, but this is a really bad design. Presumably program B intends to work differently if called by program A. There are really two ways to do this correctly: 1) have the calling parameters for invoking program B contain some kind of a processing indicator; or, 2) create two separate programs and call the correct one from the calling program. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
On Fri, Jan 28, 2011 at 1:14 PM, Wissink, Brad [ITSYS] bjwi...@iastate.eduwrote: I think I am after #1. Cobol program A dynamically calls Cobol program B. Now I need a way for Cobol Program B to find out it was called by Cobol program A. I was going to use CEETBCK to do this. Brad, Let me ask one more clarifying question. First some background just to establish a level-set to ensure we are discussing the same thing. COBOL will place the character string located in the PROGRM-ID into the object code. This will also be located in the load module along with the rest of the compiler generated stuff. When the object code is linked into a single load module, it is possible (using the NAME control card) to specify a name which is different from the name specified by the PROGRAM-ID. This occurs quite frequently when code is cloned to a different source module and and the PROGRM-ID field is not updated. Additionally, there is the case where the calling modules is part of a statically linked composite compose of several different object modules. The load module name may have no relationship top COBOL program you are interested in. Actually, there could be several object modules in a statically linked composite all of which dynamically call the subprogram. The question is which caller's name is needed. PROGRAM-ID, Load module or both? For my information, can you shed some light on what the name of the calling program will be used for? Sam Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Sam Siegel Sent: Friday, January 28, 2011 1:32 PM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On Fri, Jan 28, 2011 at 11:10 AM, Wissink, Brad [ITSYS] bjwi...@iastate.edu wrote: The order would be that the originating Cobol program would call another Cobol program. The called Cobol program wants to know who called it because it can be called from many different programs. The called Cobol program would then call my assembler program which would traverse back though the called chain using CEETBCK and report back who called it. Brad can you provide some additional information regarding what is meant by 'who called it'. Here are some specific questions. 1) the immediate predecessor (caller)? 2) the entire calling chain? 3) the name of the calling program according signature bytes put in the object code by the compiler? 4) In the case of caller that was dynamically loaded, the name of the program located in the CDE control blocks? 5) If running in a multithreaded situation, do you need to get back past the current TCB? Cheers, Sam Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 11:50 AM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 10:33 AM, Brad Wissink wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. I'm unclear on where your Assembler program would stand in the call heirarchy. It sounds like your Assembler program is supposed to be sort of an observer. But how is it invoked? It can't sit between the caller and the callee, because then it becomes the callee. I wouldn't be too exicited about CEETBCK, which is documented in the LE Vendor's Interfaces guide as a compiler writers interface. Or is this program supposed to gather this information later from, say, SMF or log records? Some more detail of what you're trying to accomplish would certainly help. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists
Re: CEETBCK and LE conforming assembler
On Fri, Jan 28, 2011 at 1:28 PM, Wissink, Brad [ITSYS] bjwi...@iastate.eduwrote: We are using this information for logging and audit purposes. We are creating an interface program that may be called by hundreds of other programs. We were looking for a simple way to log which program called the interface program just in case that type of information would be needed if the interface program abended or had problems. Brad, Question about the logging function mentioned above. How will the audit and logging data be saved? Will you be writing to disk or passing a buffer to a logging address space? Sam Brad Wissink Information Technology Services Iowa State University 515-294-3088 -Original Message- From: IBM Mainframe Discussion List [mailto:IBM-MAIN@bama.ua.edu] On Behalf Of Steve Comstock Sent: Friday, January 28, 2011 3:21 PM To: IBM-MAIN@bama.ua.edu Subject: Re: CEETBCK and LE conforming assembler On 1/28/2011 2:14 PM, Wissink, Brad [ITSYS] wrote: I think I am after #1. Cobol program A dynamically calls Cobol program B. Now I need a way for Cobol Program B to find out it was called by Cobol program A. I was going to use CEETBCK to do this. Brad Wissink Information Technology Services Iowa State University 515-294-3088 I don't know if you have any say in the matter, but this is a really bad design. Presumably program B intends to work differently if called by program A. There are really two ways to do this correctly: 1) have the calling parameters for invoking program B contain some kind of a processing indicator; or, 2) create two separate programs and call the correct one from the calling program. -- Kind regards, -Steve Comstock The Trainer's Friend, Inc. 303-393-8716 http://www.trainersfriend.com * To get a good Return on your Investment, first make an investment! + Training your people is an excellent investment * Try our new tool for calculating your Return On Investment for training dollars at http://www.trainersfriend.com/ROI/roi.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html
Re: CEETBCK and LE conforming assembler
This link into the z/OS V1R11 Information Center shows examples for Assembler and C and example output: http://publib.boulder.ibm.com/infocenter/zos/v1r11/index.jsp?topic=/com.ibm.zos.r11.ceev100/ceetbck.htm http://publib.boulder.ibm.com/infocenter/zos/v1r11/index.jsp?topic=/com.ibm.zos.r11.ceev100/ceetbck.htm --Roger On Fri, Jan 28, 2011 at 10:33 AM, Brad Wissink bjwi...@iastate.edu wrote: I have a requirement to be able to find the caller of a called program. The caller and called program are both COBOL running in batch. I found from the list that I should try CEETBCK. So I am trying to write an assembler routine to do this. Since I a novice at assembler I was wondering if anyone had a sample they would be willing to share showing me how to use CEETBCK. -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html -- For IBM-MAIN subscribe / signoff / archive access instructions, send email to lists...@bama.ua.edu with the message: GET IBM-MAIN INFO Search the archives at http://bama.ua.edu/archives/ibm-main.html