Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8078497

C2's superword optimization causes unaligned memory accesses

    XMLWordPrintable

Details

    • Bug
    • Status: Closed
    • P2
    • Resolution: Fixed
    • 8u60, 9
    • 9
    • hotspot
    • None
    • b66
    • Verified

    Backports

      Description

        C2's superword optimization generates unaligned memory accesses that cause crashes on systems that require proper address alignment (for example, Sparc):

        #
        # A fatal error has been detected by the Java Runtime Environment:
        #
        # SIGBUS (0xa) at pc=0xffffffff7694984c, pid=2009, tid=2
        #
        # JRE version: Java(TM) SE Runtime Environment (9.0) (build 1.9.0-internal-fastdebug-tohartma_2015_04_14_10_06-b00)
        # Java VM: Java HotSpot(TM) 64-Bit Server VM (1.9.0-internal-fastdebug-tohartma_2015_04_14_10_06-b00 mixed mode solaris-sparc compressed oops)
        # Problematic frame:
        # J 5 C2 Test.copyByteToChar([B[B[CI)V (249 bytes) @ 0xffffffff7694984c [0xffffffff76949700+0x14c]
        #

        In this case the failing instruction is:

          0xffffffff7694984c: ldd [ %g5 + %l3 ], %f8

        Trying to load a double word (8 bytes) from byte[] src (see attached 'TestVectorizationWithInvariant.java'). The problem is that the address 0x00000005d57b3a3a (0b...1010) is not double word aligned.

        Attachments

          Issue Links

            Activity

              People

                thartmann Tobias Hartmann
                thartmann Tobias Hartmann
                Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved: