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

Cross-modifying code

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: 13
    • Fix Version/s: 13
    • Component/s: hotspot
    • Subcomponent:
    • Resolved In Build:
      b15

      Description

      After a JavaThread have been in a safepoint/(handshake) safe state it can start executing updated code.
      E.g. an oop in the instruction stream can have been updated.

      Most hardware's require a barrier or that the code cross modified is far away to guarantee that the thread executing the update instruction stream sees the modification.

      What far away is and how far an update instruction stream is from a safepoint safe state is not clear.

      To be compliant with those architectures an instruction stream barrier must be added when leaving the safepoint safe state.

      In this issue we added the basic blocks and follow the x86 recommendations:
      AMD64 Architecture Programmer's Manual Volume 2: System Programming, section 7.6.1
      Intel® 64 and IA-32 Architectures Software Developer’s Manual, Volume 3A, section 8.1.3

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              rehn Robbin Ehn
              Reporter:
              rehn Robbin Ehn
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: