From d689a8ad1805cc48ddb1e04a37e645e92d7694ca Mon Sep 17 00:00:00 2001 From: Carl Mastrangelo Date: Sat, 9 Dec 2023 23:00:44 -0800 Subject: [PATCH] all thread locals --- java19/src/jmh/java/io/perfmark/java19/VirtualExecutor.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/java19/src/jmh/java/io/perfmark/java19/VirtualExecutor.java b/java19/src/jmh/java/io/perfmark/java19/VirtualExecutor.java index e70073a..4765a50 100644 --- a/java19/src/jmh/java/io/perfmark/java19/VirtualExecutor.java +++ b/java19/src/jmh/java/io/perfmark/java19/VirtualExecutor.java @@ -35,11 +35,9 @@ public final class VirtualExecutor implements ExecutorService { private final ExecutorService delegate; public VirtualExecutor(int maxThread, String prefix) { - boolean threadLocalsAllowed = !Boolean.getBoolean(THREAD_LOCALS_DISABLED_PROP); this.runnables = new LinkedBlockingQueue<>(); this.delegate = - Executors.newThreadPerTaskExecutor( - Thread.ofVirtual().name(prefix, 1).allowSetThreadLocals(threadLocalsAllowed).factory()); + Executors.newThreadPerTaskExecutor(Thread.ofVirtual().name(prefix, 1).factory()); for (int i = 0; i < maxThread; i++) { delegate.execute(new Worker()); }