IBM Support

IZ50320: 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

    IZ50320

  • Reported component name

    XLC C++ AIX

  • Reported component ID

    5724S7100

  • Reported release

    900

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2009-04-28

  • Closed date

    2009-06-25

  • Last modified date

    2009-07-21

Fix information

  • Fixed component name

    XLC C++ AIX

  • Fixed component ID

    5724S7100

Applicable component levels

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

Document Information

Modified date:
21 July 2009