LI77528: INTERNAL COMPILER ERROR WITH -O3

Subscribe

You can track all active APARs for this component.

APAR status

  • Closed as program error.

Error description

  • The following test case causes the compiler to produce an
    internal compiler error at -O3. It works fine with -O2.
    
    ===== COMPILE COMMAND:
    bgxlc++ -O3 -c test.cpp
    
    ===== TESTCASE:
    $ cat test.cpp
    volatile tmp;
    
    
    
    void
    
    set_b(bool *b) {
    
       *b=true;
    
    }
    
    
    
    void foo()
    
    {
    
       double l_data[2], g_data[2];
    
       bool rho_upd, e_upd;
    
    
    
       set_b(&rho_upd);
    
       set_b(&e_upd);
    
    
    
       l_data[0] = 0.0;
    
       // The internal compiler error occurs when trying to compile
    the line below
    
       l_data[1] = (rho_upd || e_upd) ? 1.0 : 0.0;
    
    
    
       tmp += (l_data[0] + l_data[1]);
    
    }
    $
    
    
    
    ===== ACTUAL OUTPUT:
    Compiler produces an internal compiler error.
    
    
    ===== EXPECTED OUTPUT:
    Internal compiler error should not occur.
    

Local fix

  • Use -O2
    

Problem summary

  • Clients who compile with -O3 may be affected by this issue.
    
    The compiler produces an internal compiler error due to a
    type mismatch caused during simplification of an if-conversion.
    

Problem conclusion

  • The compiler has been fixed to handle the above scenario.
    

Temporary fix

Comments

APAR Information

  • APAR number

    LI77528

  • Reported component name

    XL C/C++ FOR BG

  • Reported component ID

    5799AG100

  • Reported release

    C10

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2013-07-31

  • Closed date

    2013-11-29

  • Last modified date

    2013-11-29

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

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

Fix information

  • Fixed component name

    XL C/C++ FOR BG

  • Fixed component ID

    5799AG100

Applicable component levels

  • RC10 PSY

       UP



Rate this page:

(0 users)Average rating

Document information


More support for:

XL C/C++ for Blue Gene/Q
Compiler

Software version:

12.1

Reference #:

LI77528

Modified date:

2013-11-29

Translate my page

Machine Translation

Content navigation