IBM Support

LI74774: OUT OF MEMORY CAUSING COMPILER TO ABEND AT -O2

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • At -O2, the compiler runs out of memory and abends because it
    goes into an infinite loop when trying to compile the following
    test case:
    
    ===Compile Line:
    xlC_r -c -O2 -w test.cpp
    
    
    ===Start of test.cpp:
    #include <map>
    
    class CATUnicodeString ;
    
    class CVisitorMother {
    public:
            virtual ~CVisitorMother() {};
            virtual int accept() = 0;
    };
    
    
    void myClass()
    {
    
            {
                    class CVisiteur : public CVisitorMother {
    
                            std::map<CATUnicodeString,
                                    std::pair<CATUnicodeString*,
                                            unsigned int> >
                            _caches_tmp;
    
                    public:
    
                            CVisiteur()
                            {
                            };
    
    
                            ~CVisiteur() {
                            };
                            int accept(){
                            };
    
    
                    };
    
            };
    };
    =====End of test.cpp=========
    
    
    ===== ACTUAL OUTPUT:
    $xlC_r -c -O2 -w reduced.cpp
    xlC_r: 1501-230 (S) Internal compiler error; please contact your
    Service Representative
    
    ===== EXPECTED OUTPUT:
    Should not abend.
    

Local fix

  • n/a
    

Problem summary

  • This problem is seen only with local
    classes, inlining and implicit template class
    instantiation.
    
    The compiler entered a loop due to a
    mishandled implicit instantiation required by a local
    class.
    

Problem conclusion

  • The compiler no longer mishandles the
    implicit class template instantiation.
    

Temporary fix

Comments

APAR Information

  • APAR number

    LI74774

  • Reported component name

    XL C/C++ RHEL5

  • Reported component ID

    5724S7310

  • Reported release

    900

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2009-07-27

  • Closed date

    2009-07-27

  • Last modified date

    2009-07-27

  • APAR is sysrouted FROM one or more of the following:

    IZ50320

  • APAR is sysrouted TO one or more of the following:

Fix information

  • Fixed component name

    XL C/C++ RHEL5

  • Fixed component ID

    5724S7310

Applicable component levels

[{"Business Unit":{"code":"BU054","label":"Systems w\/TPS"},"Product":{"code":"SSJT9L","label":"XL C\/C++"},"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"9.0","Line of Business":{"code":"LOB08","label":"Cognitive Systems"}}]

Document Information

Modified date:
16 October 2021