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

No debug info for assembler files

    Details

    • Subcomponent:
    • Resolved In Build:
      b03

      Backports

        Description

        There are a few assembler files in the hotspot tree:
        $ find src/hotspot/ -name \*.S -o -name \*.s
        src/hotspot/os_cpu/linux_x86/linux_x86_64.s
        src/hotspot/os_cpu/linux_x86/linux_x86_32.s
        src/hotspot/os_cpu/linux_sparc/linux_sparc.s
        src/hotspot/os_cpu/bsd_x86/bsd_x86_32.s
        src/hotspot/os_cpu/bsd_x86/bsd_x86_64.s
        src/hotspot/os_cpu/linux_arm/linux_arm_32.s
        src/hotspot/os_cpu/linux_arm/linux_arm_64.s
        src/hotspot/os_cpu/solaris_sparc/solaris_sparc.s
        src/hotspot/os_cpu/solaris_x86/solaris_x86_64.s
        src/hotspot/os_cpu/linux_aarch64/threadLS_linux_aarch64.s
        src/hotspot/os_cpu/linux_aarch64/copy_linux_aarch64.s
        src/hotspot/os_cpu/linux_aarch64/linux_aarch64.S
        src/hotspot/cpu/aarch64/aarch64_linkage.S

        However, when assembling them and configuring with:
        --with-native-debug-symbols=internal
        no debug info gets generated. Other files contain debug info as expected.

        Example for SpinPause which is in linux_x86_64.s:

        $ gdb -ex 'set confirm off' -ex 'handle SIGSEGV pass nostop noprint' -ex 'set breakpoint pending on' -ex 'break SpinPause' -ex 'run' -ex 'bt' -ex 'quit' --args ./build/linux-x86_64-normal-server-release/images/jdk/bin/java -version
        GNU gdb (GDB) Fedora 8.1-19.fc28
        Copyright (C) 2018 Free Software Foundation, Inc.
        License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
        This is free software: you are free to change and redistribute it.
        There is NO WARRANTY, to the extent permitted by law. Type "show copying"
        and "show warranty" for details.
        This GDB was configured as "x86_64-redhat-linux-gnu".
        Type "show configuration" for configuration details.
        For bug reporting instructions, please see:
        <http://www.gnu.org/software/gdb/bugs/>.
        Find the GDB manual and other documentation resources online at:
        <http://www.gnu.org/software/gdb/documentation/>.
        For help, type "help".
        Type "apropos word" to search for commands related to "word"...
        Reading symbols from ./build/linux-x86_64-normal-server-release/images/jdk/bin/java...done.
        Signal Stop Print Pass to program Description
        SIGSEGV No No Yes Segmentation fault
        Function "SpinPause" not defined.
        Breakpoint 1 (SpinPause) pending.
        Starting program: /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-normal-server-release/images/jdk/bin/java -version
        [Thread debugging using libthread_db enabled]
        Using host libthread_db library "/lib64/libthread_db.so.1".
        [New Thread 0x7ffff7fc8700 (LWP 129968)]
        [New Thread 0x7fffd85c7700 (LWP 129969)]
        [New Thread 0x7fffc1657700 (LWP 129970)]
        [New Thread 0x7fffc1555700 (LWP 129971)]
        [New Thread 0x7fffc0c4b700 (LWP 129972)]
        [New Thread 0x7fffc0b49700 (LWP 129973)]
        [New Thread 0x7fffc0247700 (LWP 129974)]
        [Switching to Thread 0x7fffc0c4b700 (LWP 129972)]

        Thread 6 "G1 Refine#0" hit Breakpoint 1, 0x00007ffff689ccc0 in SpinPause () from /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-normal-server-release/images/jdk/lib/server/libjvm.so
        #0 0x00007ffff689ccc0 in SpinPause () at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/mutex.cpp:1200
        #1 0x00007ffff69d144d in Monitor::TrySpin (this=this@entry=0x7ffff000c780, Self=Self@entry=0x7ffff01e0800) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/mutex.cpp:361
        #2 0x00007ffff69d17a3 in Monitor::TrySpin (Self=0x7ffff01e0800, this=0x7ffff000c780) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/os.hpp:229
        #3 Monitor::ILock (this=0x7ffff000c780, Self=0x7ffff01e0800) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/mutex.cpp:450
        #4 0x00007ffff69d1c6f in Monitor::IWait (this=this@entry=0x7ffff000c780, Self=Self@entry=0x7ffff01e0800, timo=timo@entry=1)
            at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/mutex.cpp:818
        #5 0x00007ffff69d2bd9 in Monitor::wait (this=0x7ffff000c780, no_safepoint_check=no_safepoint_check@entry=true, timeout=timeout@entry=1, as_suspend_equivalent=as_suspend_equivalent@entry=false)
            at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/runtime/mutex.cpp:1097
        #6 0x00007ffff64c33a8 in ConcurrentGCThread::wait_for_universe_init (this=0x7ffff01e0800) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/gc/shared/concurrentGCThread.cpp:62
        #7 ConcurrentGCThread::run (this=0x7ffff01e0800) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/share/gc/shared/concurrentGCThread.cpp:79
        #8 0x00007ffff6a189f0 in thread_native_entry (thread=0x7ffff01e0800) at /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/os/linux/os_linux.cpp:698
        #9 0x00007ffff79a7594 in start_thread () from /lib64/libpthread.so.0
        #10 0x00007ffff72c702f in clone () from /lib64/libc.so.6

        Note this:

        SpinPause () from /disk/openjdk/upstream-sources/openjdk-head/build/linux-x86_64-normal-server-release/images/jdk/lib/server/libjvm.so

        Should be something like this:

        SpinPause () from /disk/openjdk/upstream-sources/openjdk-head/src/hotspot/os_cpu/linux_x86/linux_x86_64.s:45

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  sgehwolf Severin Gehwolf
                  Reporter:
                  sgehwolf Severin Gehwolf
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: