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

Type speculation should favor profile data from outermost inlined method

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: P3
    • Resolution: Fixed
    • Affects Version/s: hs25
    • Fix Version/s: 9
    • Component/s: hotspot
    • Labels:
      None
    • Subcomponent:
    • Resolved In Build:
      b04

      Backports

        Description

        When a node has a speculative type, and parsing encounter extra profiling data, the extra profiling data is ignored. So profiling data coming from profile points closer to the root of the compilation is favored which I think makes sense: it's the data that is most specific to the context of this compilation that we rely on.

        There are exception to this in practice. For instance:
        m1() {
           m3();
        }

        m() {
          m1();
          m2();
        }

        Let's say, m3() and m2() have profile data for the same node. The first profile data to be encountered during parsing is from m3() and profile data from m2() is ignored but profile data from m2() is the one that is actually the most specific and is the one that should be favored.

          Attachments

            Issue Links

              Activity

                People

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

                  Dates

                  Created:
                  Updated:
                  Resolved: