IBM Support

IV20144: INCORRECT OUTPUT FROM SYSTEM.ARRAYCOPY WHEN INLINED INTO AOT-COM PILED CODE

Subscribe

You can track all active APARs for this component.

 

APAR status

  • Closed as program error.

Error description

  • Error Message: When a Java method that moves data within an
    array using System.arraycopy is AOT-compiled, the
    System.arraycopy call is inlined for performance reasons. If the
    source and destination ranges overlap, the inlined code can be
    incorrect and can produce incorrect content in the array. This
    may lead to unexpected exceptions or crashes.
    In many applications, this problem manifests itself as a
    corrupted string after the string has undergone special
    character escaping or Unicode character decoding.
    For example, escaping the backslash in the string "foo\bar"
    should result in the string "foo%5cbar", but this problem can
    corrupt the string to "fooo5cbar". Another example is decoding
    the string "foo\U0024bar", which should result in "foo$bar",
    however it can be corrupted into "ffo$bar" instead.
    This problem affects z/OS and z/Linux.
    .
    Stack Trace:
    .
    

Local fix

  • This problem can be avoided by disabling AOT compilations with
    the -Xnoaot option. Alternatively, it can be avoided by using
    the "gencon" GC policy, with the -Xgcpolicy:gencon option.
    

Problem summary

  • The problem is caused when the JIT compiler optimizes an
    arraycopy of primitive arrays into a simple memory copy, but is
    unable to determine the exact type of the arrays. In this
    scenario, the System z code generator can emit instructions to
    copy an incorrect number of array elements.
    

Problem conclusion

  • This defect will be fixed in:
    6.0.0 SR12
    6.0.1 SR3
    7.0.0 SR2
    .
    The JIT compiler has been updated to prevent the improper
    optimization of such arraycopy calls.
    

Temporary fix

Comments

APAR Information

  • APAR number

    IV20144

  • Reported component name

    JIT

  • Reported component ID

    620700124

  • Reported release

    600

  • Status

    CLOSED PER

  • PE

    NoPE

  • HIPER

    NoHIPER

  • Special Attention

    NoSpecatt

  • Submitted date

    2012-04-24

  • Closed date

    2012-05-05

  • Last modified date

    2012-05-05

  • 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

    JIT

  • Fixed component ID

    620700124

Applicable component levels

  • R600 PSY

       UP

  • R260 PSY

       UP

[{"Business Unit":{"code":"BU048","label":"IBM Software"},"Product":{"code":"SSC9HBA","label":"Just In Time (JIT) Compiler"},"Component":"","ARM Category":[],"Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"6.0","Edition":"","Line of Business":{"code":"","label":""}}]

Document Information

Modified date:
05 May 2012