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

(se) SelectorImpl.register does not need to set the attachment when it is null

    XMLWordPrintable

Details

    • Enhancement
    • Resolution: Fixed
    • P4
    • 14
    • None
    • core-libs
    • b18

    Description

      The getAndSet to set the attachment object when registering a channel with a Selector is not needed when the attachment object is null.

      While in the area, the AtomicReferenceFieldUpdater to update the attachment can be replaced with a VarHandle.

      Attachments

        Activity

          People

            alanb Alan Bateman
            alanb Alan Bateman
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: