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

[REDO] Elide more final field's write memory barrier with escape analysis result

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
    • Environment:

      aarch64 development board

    • Subcomponent:
    • Resolved In Build:
      b96
    • CPU:
      aarch64
    • OS:
      generic

      Description

      MemBarRelease for final field write can be removed when its allocation doesn't escape thread, allocation node can be acquired from its MemBarNode::Precedent input.
      Currently, MemBarRelase's Precedent input is only added when eliminate_boxing is true and its owning object is primitive Box (see Parse::do_put_xxx and Parse::do_exits). Checking OpenJDK log, this is added for autoboxing elimination early. Now I suggest turn on this optimization for general object type, this can benefit RMO platform (like aarch64) performance.

      Enhancement try removing constraints for set_alloc_with_final(obj) in do_put_xxx (parse3.cpp). This leads to adding Precedent input for all kind object's final field writes' MemBarRelase node. Then they have opportunities to get optimized.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                hshi Hui Shi
                Reporter:
                roland Roland Westrelin
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: