Skip to Main Content
IBM Z Software


This portal is to open public enhancement requests against IBM Z Software products. To view all of your ideas submitted to IBM, create and manage groups of Ideas, or create an idea explicitly set to be either visible by all (public) or visible only to you and IBM (private), use the IBM Unified Ideas Portal (https://ideas.ibm.com).


Shape the future of IBM!

We invite you to shape the future of IBM, including product roadmaps, by submitting ideas that matter to you the most. Here's how it works:

Search existing ideas

Start by searching and reviewing ideas and requests to enhance a product or service. Take a look at ideas others have posted, and add a comment, vote, or subscribe to updates on them if they matter to you. If you can't find what you are looking for,

Post your ideas
  1. Post an idea.

  2. Get feedback from the IBM team and other customers to refine your idea.

  3. Follow the idea through the IBM Ideas process.


Specific links you will want to bookmark for future use

Welcome to the IBM Ideas Portal (https://www.ibm.com/ideas) - Use this site to find out additional information and details about the IBM Ideas process and statuses.

IBM Unified Ideas Portal (https://ideas.ibm.com) - Use this site to view all of your ideas, create new ideas for any IBM product, or search for ideas across all of IBM.

ideasibm@us.ibm.com - Use this email to suggest enhancements to the Ideas process or request help from IBM for submitting your Ideas.

Status Not under consideration
Workspace COBOL Compilers
Categories z/OS
Created by Guest
Created on Nov 17, 2025

IBM Enterprise COBOL V6R4+ - Compilation directive to inform the compiler of the end of sequential code execution (call to exit / abend routine)

Hi,


We have observed that compiler optimization, particularly PERFORM inlining, can be disrupted by certain constructs in the COBOL source code:

  • EXEC CICS RETURN

  • EXEC CICS HANDLE ABEND LABEL

  • CALL to subprogram without expected return, (abend subprogram)


In fact, CICS commands are technically translated as CALLs, and the general rule is that you can return to the program after a CALL.

The case of EXEC CICS RETURN illustrates this: you're not supposed to return to the program, however, for some reason (which I can't explain), the EXEC CICS RETURN command might fail, and in that case, the program can continue to execute sequentially.


The case of a subroutine called to trigger an ABEND, in addition to other processing, is probably common in many customer's platforms; moreover, the Language Environment also handles ABENDs by calling such a routine.

While the COBOL compiler can recognize LE routines, it cannot recognize the routines implemented by clients.

Today the workaround to achieve inlining of PERFORM is to code GOBACKs after a "no-return CALL", which is logically incorrect and inelegant.


For these reasons, we propose implementing a new compilation directive in the COBOL compiler to indicate the end of sequential execution, often placed after a CALL or a CICS command, but other cases must exist.

This compilation directive would help the compiler better manage PERFORM inlining by taking sequence breaks (no-return CALL) into account.

Implementing the compilation directive could trigger a deliberate abend, for example, in the form of an abend S0C1 (illegal instruction), or any other solution.


See COBOL Comminity discussion I start:
https://community.ibm.com/community/user/discussion/ibm-enterprise-cobol-v6-disabling-optimizations-when-the-cics-option-is-active


Thanks.

Idea priority Medium
  • Guest
    Mar 9, 2026

    Hi,

    Answer provided on case TS020510459:

    The issue with inlining of PERFORM statements applies to programs containing one or more EXEC CICS HANDLE ABEND statements as well as at least two EXEC CICS ABEND statements. Other CICS statements, including other EXEC CICS HANDLE statements, are not affected.

    To the optimizer, error handling code can conservatively be entered at any point and return to any point. While this isn't true in practice - control can only return from an ABEND error handler to ONE place following a specific EXEC CICS ABEND call - this isn't something the optimizer automatically knows. This property prevents our PERFORM inlining optimization from inlining paragraphs that contain code that can branch to error handlers.

    We run analysis to identify this for other EXEC CICS HANDLE error handlers, allowing paragraphs containing them to be inlined. We don't do this analysis for EXEC CICS ABEND statements because we haven't found this to be as common in client code and because the mechanisms the compiler and CICS use to handle EXEC CICS ABENDs with error handling differs from other forms of CICS error handling.

    We don't intend to do the work to allow EXEC CICS ABEND statements to be inlined when EXEC CICS HANDLE ABEND handlers are present. We feel our clients will be better served overall by focusing on performance opportunities that are more widespread.

    This doesn't provide me with a solution for obtaining optimized code...

    The same problem exists for CALL calls to subroutines that "do not return" to the calling program (usually they trigger an abend).

    The proposed solution was a way to inform the compiler that there was an invisible sequence break in the source code so that it could optimize the code.

    I don't know if it's the EXEC CICS ABEND or EXEC CICS HANDLE ABEND that's causing the compiler problem (I think it's more likely EXEC CICS HANDLE ABEND), but in any case, these instructions are present in all our CICS programs (20,000 programs), and therefore none of our CICS programs are properly optimized because of this.

    A workaround for the compiler's limitations is requested.

    Thanks.

  • Admin
    Basil Kanneth
    Feb 4, 2026

    Hi, we realize that you have opened case TS020510459 for this idea as well. An update has been provided to case TS020510459 related to this topic. Due to the reasons mentioned in the case, this idea is being rejected.

  • Admin
    Basil Kanneth
    Dec 17, 2025

    This item is still being reviewed and requires more time.