Skip to content

Commit 1e69638

Browse files
committed
add missing truffle boundaries
1 parent 614994d commit 1e69638

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/ThreadModuleBuiltins.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,7 @@ long getId() {
114114
@GenerateNodeFactory
115115
abstract static class GetThreadCountNode extends PythonBuiltinNode {
116116
@Specialization
117+
@TruffleBoundary
117118
long getCount() {
118119
return getContext().getThreadGroup().activeCount();
119120
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/thread/PThread.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242

4343
import com.oracle.graal.python.builtins.objects.object.PythonBuiltinObject;
4444
import com.oracle.graal.python.builtins.objects.type.PythonClass;
45+
import com.oracle.truffle.api.CompilerDirectives.TruffleBoundary;
4546

4647
public class PThread extends PythonBuiltinObject {
4748
public final static String GRAALPYTHON_THREADS = "GRAALPYTHON_THREADS";
@@ -56,6 +57,7 @@ public PThread(PythonClass cls, ThreadGroup group, long stackSize, Runnable runn
5657
this.thread = new Thread(group, runnable, "graalpython-thread-" + group.activeCount(), stackSize);
5758
}
5859

60+
@TruffleBoundary
5961
public void start() {
6062
if (!this.thread.isAlive()) {
6163
thread.start();

0 commit comments

Comments
 (0)