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

[lworld] print parameter types for different compiled entry points

    Details

    • Type: Enhancement
    • Status: Resolved
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: repo-valhalla
    • Fix Version/s: repo-valhalla
    • Component/s: hotspot
    • Labels:

      Description

      Compiled methods can have up to 3 entry points that take different types of parameters. For debugging purposes, it's useful to print the types of each entry point.

      The following example shows how the [Verified Entry Point] of a C1 method shuffles the parameters before jumping to the [Verified Value Entry Point]:

      [Disassembling for mach='i386:x86-64']
        # {method} {0x00007fa9108ed690} 'test' '(QI2CStatic$V;IIIIIIII)I' in 'I2CStatic'
      [Entry Point]
      [Verified Entry Point]
      [Verified Value Entry Point (RO)]
        # parm0: rsi = int
        # parm1: rdx = int
        # parm2: rcx = int
        # parm3: r8 = int
        # parm4: r9 = int
        # parm5: rdi = int
        # parm6: [sp+0x40] = int (sp of caller)
        # parm7: [sp+0x48] = int [RESERVED]
        # parm8: [sp+0x50] = int
        # parm9: [sp+0x58] = int [RESERVED]
        # parm10: [sp+0x60] = int
        # parm11: [sp+0x68] = int
        0x00007fa924e371e0: push %rbp
        0x00007fa924e371e1: sub $0x30,%rsp
        0x00007fa924e371e5: mov $0x7fa9108ed690,%rbx
        0x00007fa924e371ef: callq 0x00007fa9249d9ac0 ; {runtime_call buffer_value_args Runtime1 stub}
        0x00007fa924e371f4: mov 0x10(%rax),%r11d
        0x00007fa924e371f8: mov %esi,0x10(%r11)
        0x00007fa924e371fc: mov %edx,0x14(%r11)
        0x00007fa924e37200: mov %r11,%rsi
        0x00007fa924e37203: mov %rcx,%rdx
        0x00007fa924e37206: mov %r8,%rcx
        0x00007fa924e37209: mov %r9,%r8
        0x00007fa924e3720c: mov %rdi,%r9
        0x00007fa924e3720f: mov 0x40(%rsp),%rdi
        0x00007fa924e37214: mov 0x50(%rsp),%r13
        0x00007fa924e37219: mov %r13,0x40(%rsp)
        0x00007fa924e3721e: mov 0x60(%rsp),%r13
        0x00007fa924e37223: mov %r13,0x48(%rsp)
        0x00007fa924e37228: mov 0x68(%rsp),%r13
        0x00007fa924e3722d: mov %r13,0x50(%rsp)
        0x00007fa924e37232: pop %rbp
        0x00007fa924e37233: add $0x30,%rsp
        0x00007fa924e37237: jmpq 0x00007fa924e37240
        ...
      [Verified Value Entry Point]
        # parm0: rsi:rsi = 'java/lang/Object'
        # parm1: rdx = int
        # parm2: rcx = int
        # parm3: r8 = int
        # parm4: r9 = int
        # parm5: rdi = int
        # parm6: [sp+0x40] = int (sp of caller)
        # parm7: [sp+0x48] = int
        # parm8: [sp+0x50] = int
        0x00007fa924e37240: mov %eax,-0x16000(%rsp)
        0x00007fa924e37247: push %rbp
        0x00007fa924e37248: sub $0x30,%rsp

        Attachments

          Activity

            People

            • Assignee:
              iklam Ioi Lam
              Reporter:
              iklam Ioi Lam
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: