|
24 | 24 | */
|
25 | 25 | package com.oracle.svm.core.thread;
|
26 | 26 |
|
27 |
| -import com.oracle.svm.core.locks.VMLockSupport; |
28 |
| -import jdk.graal.compiler.api.directives.GraalDirectives; |
29 |
| -import jdk.graal.compiler.api.replacements.Fold; |
30 |
| -import jdk.graal.compiler.replacements.ReplacementsUtil; |
31 |
| -import jdk.graal.compiler.replacements.nodes.AssertionNode; |
32 | 27 | import org.graalvm.nativeimage.CurrentIsolate;
|
33 | 28 | import org.graalvm.nativeimage.ImageSingletons;
|
34 | 29 | import org.graalvm.nativeimage.Isolate;
|
|
55 | 50 | import com.oracle.svm.core.jdk.UninterruptibleUtils;
|
56 | 51 | import com.oracle.svm.core.jdk.UninterruptibleUtils.AtomicWord;
|
57 | 52 | import com.oracle.svm.core.locks.VMCondition;
|
| 53 | +import com.oracle.svm.core.locks.VMLockSupport; |
58 | 54 | import com.oracle.svm.core.locks.VMMutex;
|
59 | 55 | import com.oracle.svm.core.log.Log;
|
60 | 56 | import com.oracle.svm.core.nodes.CFunctionEpilogueNode;
|
|
68 | 64 | import com.oracle.svm.core.util.UnsignedUtils;
|
69 | 65 | import com.oracle.svm.core.util.VMError;
|
70 | 66 |
|
| 67 | +import jdk.graal.compiler.api.directives.GraalDirectives; |
| 68 | +import jdk.graal.compiler.api.replacements.Fold; |
| 69 | +import jdk.graal.compiler.replacements.ReplacementsUtil; |
| 70 | +import jdk.graal.compiler.replacements.nodes.AssertionNode; |
| 71 | + |
71 | 72 | /**
|
72 | 73 | * Utility methods for the manipulation and iteration of {@link IsolateThread}s.
|
73 | 74 | */
|
@@ -407,12 +408,12 @@ public static boolean wasStartedByCurrentIsolate(IsolateThread thread) {
|
407 | 408 | return StartedByCurrentIsolate.getAddress(thread).readByte(0) != 0;
|
408 | 409 | }
|
409 | 410 |
|
410 |
| - @Uninterruptible(reason = "Called from uninterruptible code.", mayBeInlined = true) |
| 411 | + @Uninterruptible(reason = "Thread locks/holds the THREAD_MUTEX.", callerMustBe = true) |
411 | 412 | static void lockThreadMutexInNativeCode() {
|
412 | 413 | lockThreadMutexInNativeCode(false);
|
413 | 414 | }
|
414 | 415 |
|
415 |
| - @Uninterruptible(reason = "Called from uninterruptible code.") |
| 416 | + @Uninterruptible(reason = "Thread locks/holds the THREAD_MUTEX.", callerMustBe = true) |
416 | 417 | @NeverInline("Must not be inlined in a caller that has an exception handler: We only support InvokeNode and not InvokeWithExceptionNode between a CFunctionPrologueNode and CFunctionEpilogueNode.")
|
417 | 418 | private static void lockThreadMutexInNativeCode(boolean unspecifiedOwner) {
|
418 | 419 | CFunctionPrologueNode.cFunctionPrologue(StatusSupport.STATUS_IN_NATIVE);
|
|
0 commit comments