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

Shenandoah: pacer should not affect interrupt status

XMLWordPrintable

    • gc
    • b27
    • Not verified

        This was originally found by Aditya Mandaleeka when running sh/jdk11 tests. It seems to reproduce as the very rare timeout in java/security/Provider/GetServiceRace.java test. The underlying reason is that pacer does this:

           JavaThread::current()->sleep(cur);

        ...which in turn checks and *clears* the interrupt status in the guts of OS code:

            if (os::is_interrupted(thread, true)) { // "true" means clear interrupt status
              return OS_INTRPT;
            }

        And that interferes with interrupt status of Java thread. This is incorrect.

              shade Aleksey Shipilev
              shade Aleksey Shipilev
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: