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

Improve Register class implementation

    XMLWordPrintable

    Details

    • Type: Enhancement
    • Status: Open
    • Priority: P4
    • Resolution: Unresolved
    • Affects Version/s: 18
    • Fix Version/s: tbd
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Introduced In Version:
      18

      Description

      We saw -Wnonnull warnings with GCC in JDK-8270083, then we avoided it with disabling compiler warnings. But it is just a workaround. We need to refactor it.

      Comments from Kim Barrett:
      https://github.com/openjdk/jdk/pull/4719#issuecomment-876904878

      The potential difficulty with doing that is the same as for markWord - see JDK-8235362. A different option might be to make the various categories of Register be enum classes without any defined enumerators. That wouldn't support the existing XXXRegisterImpl derivation from AbstractRegisterImpl. I'm not sure that relationship is needed; it may not even be good. The only use I can find is in the various assert_different_registers, and that could be done differently. (The numerous overloads could also probably be simplified using variadic templates.)

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned Unassigned
              Reporter:
              ysuenaga Yasumasa Suenaga
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated: