Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

8181313: SA: Remove libthread_db dependency on Linux #34

Closed

Conversation

jerboaa
Copy link
Contributor

@jerboaa jerboaa commented Jun 16, 2021

This backport fixes tier1 test failures in the serviceability area for systems using glibc 2.33. On those system attaching to a different process doesn't work currently:

$ export LIBSAPROC_DEBUG=true
$ jhsdb clhsdb --pid 148082
Attaching to process 148082, please wait...
libsaproc DEBUG: lookup failed for symbol 'nptl_version' in obj 'libpthread.so.0'
libsaproc DEBUG: can't create libthread_db agent
libsaproc DEBUG: lookup failed for symbol '__vt_10JavaThread' in obj 'libjvm.so'
libsaproc DEBUG: lookup failed for symbol '__vt_10JavaThread' in obj 'libjvm.so'
Warning: Nashorn engine is planned to be removed from a future JDK release
javax.script.ScriptException: TypeError: sapkg.runtime.VM.getVM is not a function in sa.js at line number 54
javax.script.ScriptException: TypeError: sapkg.runtime.VM.getVM is not a function in sa.js at line number 54
Warning! JS Engine can't start, some commands will not be available.
hsdb> threads
148099 Common-Cleaner
State: BLOCKED
libsaproc DEBUG: ptrace(PTRACE_GETREGS, ...) failed for lwp 148099
Error: sun.jvm.hotspot.debugger.DebuggerException: sun.jvm.hotspot.debugger.DebuggerException: get_thread_regs failed for a lwp
hsdb>

See also this related gdb bug:
https://sourceware.org/bugzilla/show_bug.cgi?id=27526

The proposal is to remove the need of thread_db entirely as it's not need (which brings JDK 11) in line with JDK 17+

The patch didn't apply cleanly. Conflicts where only in copyright headers.

Testing:

  • tier1 on Linux x86_64 with glibc 2.33 (fails prior, passes after patch).

Thoughts?


Progress

  • Change must not contain extraneous whitespace
  • Commit message must refer to an issue
  • Change must be properly reviewed

Issue

  • JDK-8181313: SA: Remove libthread_db dependency on Linux

Reviewers

Reviewing

Using git

Checkout this PR locally:
$ git fetch https://git.openjdk.java.net/jdk11u-dev pull/34/head:pull/34
$ git checkout pull/34

Update a local copy of the PR:
$ git checkout pull/34
$ git pull https://git.openjdk.java.net/jdk11u-dev pull/34/head

Using Skara CLI tools

Checkout this PR locally:
$ git pr checkout 34

View PR using the GUI difftool:
$ git pr show -t 34

Using diff file

Download this PR as a diff file:
https://git.openjdk.java.net/jdk11u-dev/pull/34.diff

@bridgekeeper
Copy link

bridgekeeper bot commented Jun 16, 2021

👋 Welcome back sgehwolf! A progress list of the required criteria for merging this PR into master will be added to the body of your pull request. There are additional pull request commands available for use with this pull request.

@openjdk openjdk bot changed the title Backport ef3336ec27665397783550ec880e1bc6b711a247 8181313: SA: Remove libthread_db dependency on Linux Jun 16, 2021
@openjdk
Copy link

openjdk bot commented Jun 16, 2021

This backport pull request has now been updated with issue from the original commit.

@openjdk openjdk bot added backport rfr Pull request is ready for review labels Jun 16, 2021
@mlbridge
Copy link

mlbridge bot commented Jun 16, 2021

Webrevs

Copy link
Member

@eastig eastig left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@openjdk
Copy link

openjdk bot commented Jun 16, 2021

@jerboaa This change now passes all automated pre-integration checks.

After integration, the commit message for the final commit will be:

8181313: SA: Remove libthread_db dependency on Linux

Reviewed-by: clanger

You can use pull request commands such as /summary, /contributor and /issue to adjust it as needed.

At the time when this comment was updated there had been 3 new commits pushed to the master branch:

  • 23719ae: 8262000: jdk/jfr/event/gc/detailed/TestPromotionFailedEventWithParallelScavenge.java failed with "OutOfMemoryError: Java heap space"
  • 9638c41: 8266288: assert root method not found in witnessed_reabstraction_in_supers is too strong
  • 57d8e1e: 8268127: Shenandoah: Heap size may be too small for region to align to large page size

Please see this link for an up-to-date comparison between the source branch of this pull request and the master branch.
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.

➡️ To integrate this PR with the above commit message to the master branch, type /integrate in a new comment.

@openjdk openjdk bot added the ready Pull request is ready to be integrated label Jun 16, 2021
@jerboaa
Copy link
Contributor Author

jerboaa commented Jun 17, 2021

Thanks for the reviews!

@jerboaa
Copy link
Contributor Author

jerboaa commented Jun 17, 2021

/integrate

@openjdk
Copy link

openjdk bot commented Jun 17, 2021

Going to push as commit 0605504.
Since your change was applied there have been 3 commits pushed to the master branch:

  • 23719ae: 8262000: jdk/jfr/event/gc/detailed/TestPromotionFailedEventWithParallelScavenge.java failed with "OutOfMemoryError: Java heap space"
  • 9638c41: 8266288: assert root method not found in witnessed_reabstraction_in_supers is too strong
  • 57d8e1e: 8268127: Shenandoah: Heap size may be too small for region to align to large page size

Your commit was automatically rebased without conflicts.

@openjdk openjdk bot closed this Jun 17, 2021
@openjdk openjdk bot added integrated Pull request has been integrated and removed ready Pull request is ready to be integrated rfr Pull request is ready for review labels Jun 17, 2021
@openjdk
Copy link

openjdk bot commented Jun 17, 2021

@jerboaa Pushed as commit 0605504.

💡 You may see a message that your pull request was closed with unmerged commits. This can be safely ignored.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport integrated Pull request has been integrated
4 participants