Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
8210558: serviceability/sa/TestJhsdbJstackLock.java fails to find '^\…
…s+- waiting to lock <0x[0-9a-f]+> \(a java\.lang\.Class ...'

Reviewed-by: kevinw, sspitsyn
  • Loading branch information
plummercj committed Dec 6, 2021
1 parent 082fdf4 commit 587e540
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion test/hotspot/jtreg/serviceability/sa/LingeredAppWithLock.java
@@ -1,5 +1,5 @@
/*
* Copyright (c) 2017, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2017, 2021, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
Expand Down Expand Up @@ -47,6 +47,19 @@ public static void main(String args[]) {
objectLock.start();
primitiveLock.start();

// Wait until all threads have reached their blocked or timed wait state
while ((classLock1.getState() != Thread.State.BLOCKED &&
classLock1.getState() != Thread.State.TIMED_WAITING) ||
(classLock2.getState() != Thread.State.BLOCKED &&
classLock2.getState() != Thread.State.TIMED_WAITING) ||
(objectLock.getState() != Thread.State.TIMED_WAITING) ||
(primitiveLock.getState() != Thread.State.TIMED_WAITING)) {
try {
Thread.sleep(100);
} catch (InterruptedException ex) {
}
}

LingeredApp.main(args);
}
}

3 comments on commit 587e540

@openjdk-notifier
Copy link

Choose a reason for hiding this comment

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

@GoeLin
Copy link
Member

@GoeLin GoeLin commented on 587e540 Sep 21, 2022

Choose a reason for hiding this comment

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

/backport jdk17u-dev

@openjdk
Copy link

@openjdk openjdk bot commented on 587e540 Sep 21, 2022

Choose a reason for hiding this comment

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

@GoeLin the backport was successfully created on the branch GoeLin-backport-587e5409 in my personal fork of openjdk/jdk17u-dev. To create a pull request with this backport targeting openjdk/jdk17u-dev:master, just click the following link:

➡️ Create pull request

The title of the pull request is automatically filled in correctly and below you find a suggestion for the pull request body:

Hi all,

This pull request contains a backport of commit 587e5409 from the openjdk/jdk repository.

The commit being backported was authored by Chris Plummer on 6 Dec 2021 and was reviewed by Kevin Walls and Serguei Spitsyn.

Thanks!

If you need to update the source branch of the pull then run the following commands in a local clone of your personal fork of openjdk/jdk17u-dev:

$ git fetch https://github.com/openjdk-bots/jdk17u-dev GoeLin-backport-587e5409:GoeLin-backport-587e5409
$ git checkout GoeLin-backport-587e5409
# make changes
$ git add paths/to/changed/files
$ git commit --message 'Describe additional changes made'
$ git push https://github.com/openjdk-bots/jdk17u-dev GoeLin-backport-587e5409

Please sign in to comment.