public class org.graalvm.compiler.truffle.test.CodeInvalidationTest extends com.oracle.truffle.api.test.polyglot.AbstractPolyglotTest
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.graalvm.compiler.truffle.test.CodeInvalidationTest
super_class: com.oracle.truffle.api.test.polyglot.AbstractPolyglotTest
{
private static final java.lang.String NODE_REPLACE_SUCCESSFUL;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "Node replace successful!"
public void <init>();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokespecial com.oracle.truffle.api.test.polyglot.AbstractPolyglotTest.<init>:()V
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest;
public void testInvalidation();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=12, args_size=1
start local 0 0: new java.util.concurrent.CountDownLatch
dup
iconst_2
invokespecial java.util.concurrent.CountDownLatch.<init>:(I)V
astore 1
start local 1 1: new org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate
dup
invokedynamic get()Ljava/util/function/Supplier;
Bootstrap: invokestatic java.lang.invoke.LambdaMetafactory.metafactory:(Ljava/lang/invoke/MethodHandles$Lookup;Ljava/lang/String;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodType;Ljava/lang/invoke/MethodHandle;Ljava/lang/invoke/MethodType;)Ljava/lang/invoke/CallSite;
Method arguments:
()Ljava/lang/Object;
org/graalvm/compiler/truffle/test/CodeInvalidationTest.lambda$0()Ljava/lang/Boolean; (6)
()Ljava/lang/Boolean;
invokestatic java.lang.ThreadLocal.withInitial:(Ljava/util/function/Supplier;)Ljava/lang/ThreadLocal;
aload 1
invokespecial org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate.<init>:(Ljava/lang/ThreadLocal;Ljava/util/concurrent/CountDownLatch;)V
astore 2
start local 2 2: new org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode
dup
ldc 1000000000
invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
aload 2
invokespecial org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode.<init>:(Ljava/lang/Object;Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$BaseNode;)V
astore 3
start local 3 3: aload 3
getfield org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode.loop:Lcom/oracle/truffle/api/nodes/LoopNode;
astore 4
start local 4 4: aload 0
iconst_0
anewarray java.lang.String
invokestatic org.graalvm.polyglot.Context.create:([Ljava/lang/String;)Lorg/graalvm/polyglot/Context;
new org.graalvm.compiler.truffle.test.CodeInvalidationTest$1
dup
aload 0
aload 3
invokespecial org.graalvm.compiler.truffle.test.CodeInvalidationTest$1.<init>:(Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest;Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$WhileLoopNode;)V
invokevirtual org.graalvm.compiler.truffle.test.CodeInvalidationTest.setupEnv:(Lorg/graalvm/polyglot/Context;Lcom/oracle/truffle/api/test/polyglot/ProxyLanguage;)V
5: ldc "proxyLanguage"
ldc ""
ldc "DummySource"
invokestatic org.graalvm.polyglot.Source.newBuilder:(Ljava/lang/String;Ljava/lang/CharSequence;Ljava/lang/String;)Lorg/graalvm/polyglot/Source$Builder;
invokevirtual org.graalvm.polyglot.Source$Builder.build:()Lorg/graalvm/polyglot/Source;
astore 5
start local 5 6: aload 0
getfield org.graalvm.compiler.truffle.test.CodeInvalidationTest.context:Lorg/graalvm/polyglot/Context;
aload 5
invokevirtual org.graalvm.polyglot.Context.eval:(Lorg/graalvm/polyglot/Source;)Lorg/graalvm/polyglot/Value;
pop
7: aload 4
checkcast org.graalvm.compiler.truffle.runtime.OptimizedOSRLoopNode
invokevirtual org.graalvm.compiler.truffle.runtime.OptimizedOSRLoopNode.getCompiledOSRLoop:()Lorg/graalvm/compiler/truffle/runtime/OptimizedCallTarget;
astore 8
start local 8 8: aload 8
invokestatic org.junit.Assert.assertNotNull:(Ljava/lang/Object;)V
9: aload 8
invokevirtual org.graalvm.compiler.truffle.runtime.OptimizedCallTarget.isValid:()Z
invokestatic org.junit.Assert.assertTrue:(Z)V
10: iconst_2
invokestatic java.util.concurrent.Executors.newFixedThreadPool:(I)Ljava/util/concurrent/ExecutorService;
astore 9
start local 9 11: aload 9
new org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode
dup
aload 0
getfield org.graalvm.compiler.truffle.test.CodeInvalidationTest.context:Lorg/graalvm/polyglot/Context;
aload 5
aconst_null
invokespecial org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode.<init>:(Lorg/graalvm/polyglot/Context;Lorg/graalvm/polyglot/Source;Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$NodeToInvalidate;)V
invokeinterface java.util.concurrent.ExecutorService.submit:(Ljava/lang/Runnable;)Ljava/util/concurrent/Future;
astore 6
start local 6 12: aload 2
getfield org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate.latch:Ljava/util/concurrent/CountDownLatch;
invokevirtual java.util.concurrent.CountDownLatch.await:()V
13: aload 9
new org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode
dup
aload 0
getfield org.graalvm.compiler.truffle.test.CodeInvalidationTest.context:Lorg/graalvm/polyglot/Context;
aload 5
aload 2
invokespecial org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode.<init>:(Lorg/graalvm/polyglot/Context;Lorg/graalvm/polyglot/Source;Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$NodeToInvalidate;)V
invokeinterface java.util.concurrent.ExecutorService.submit:(Ljava/lang/Runnable;)Ljava/util/concurrent/Future;
astore 7
start local 7 14: aload 6
invokeinterface java.util.concurrent.Future.get:()Ljava/lang/Object;
pop
15: aload 7
invokeinterface java.util.concurrent.Future.get:()Ljava/lang/Object;
pop
16: invokestatic org.junit.Assert.fail:()V
end local 7 end local 6 17: goto 27
StackMap locals: org.graalvm.compiler.truffle.test.CodeInvalidationTest java.util.concurrent.CountDownLatch org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode com.oracle.truffle.api.nodes.LoopNode org.graalvm.polyglot.Source top top org.graalvm.compiler.truffle.runtime.OptimizedCallTarget java.util.concurrent.ExecutorService
StackMap stack: java.util.concurrent.ExecutionException
18: astore 10
start local 10 19: aload 10
invokevirtual java.util.concurrent.ExecutionException.getCause:()Ljava/lang/Throwable;
instanceof org.graalvm.polyglot.PolyglotException
invokestatic org.junit.Assert.assertTrue:(Z)V
20: ldc "java.lang.RuntimeException: Node replace successful!"
aload 10
invokevirtual java.util.concurrent.ExecutionException.getCause:()Ljava/lang/Throwable;
invokevirtual java.lang.Throwable.getMessage:()Ljava/lang/String;
invokestatic org.junit.Assert.assertEquals:(Ljava/lang/Object;Ljava/lang/Object;)V
end local 10 21: aload 9
invokeinterface java.util.concurrent.ExecutorService.shutdownNow:()Ljava/util/List;
pop
22: aload 9
ldc 100
getstatic java.util.concurrent.TimeUnit.SECONDS:Ljava/util/concurrent/TimeUnit;
invokeinterface java.util.concurrent.ExecutorService.awaitTermination:(JLjava/util/concurrent/TimeUnit;)Z
pop
goto 29
23: StackMap locals:
StackMap stack: java.lang.Throwable
astore 11
24: aload 9
invokeinterface java.util.concurrent.ExecutorService.shutdownNow:()Ljava/util/List;
pop
25: aload 9
ldc 100
getstatic java.util.concurrent.TimeUnit.SECONDS:Ljava/util/concurrent/TimeUnit;
invokeinterface java.util.concurrent.ExecutorService.awaitTermination:(JLjava/util/concurrent/TimeUnit;)Z
pop
26: aload 11
athrow
27: StackMap locals:
StackMap stack:
aload 9
invokeinterface java.util.concurrent.ExecutorService.shutdownNow:()Ljava/util/List;
pop
28: aload 9
ldc 100
getstatic java.util.concurrent.TimeUnit.SECONDS:Ljava/util/concurrent/TimeUnit;
invokeinterface java.util.concurrent.ExecutorService.awaitTermination:(JLjava/util/concurrent/TimeUnit;)Z
pop
29: StackMap locals:
StackMap stack:
return
end local 9 end local 8 end local 5 end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 30 0 this Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest;
1 30 1 latch Ljava/util/concurrent/CountDownLatch;
2 30 2 nodeToInvalidate Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$NodeToInvalidate;
3 30 3 testedCode Lorg/graalvm/compiler/truffle/test/CodeInvalidationTest$WhileLoopNode;
4 30 4 loopNode Lcom/oracle/truffle/api/nodes/LoopNode;
6 30 5 source Lorg/graalvm/polyglot/Source;
12 17 6 future1 Ljava/util/concurrent/Future<*>;
14 17 7 future2 Ljava/util/concurrent/Future<*>;
8 30 8 loopCallTarget Lorg/graalvm/compiler/truffle/runtime/OptimizedCallTarget;
11 30 9 executor Ljava/util/concurrent/ExecutorService;
19 21 10 e Ljava/util/concurrent/ExecutionException;
Exception table:
from to target type
11 17 18 Class java.util.concurrent.ExecutionException
11 21 23 any
Exceptions:
throws java.io.IOException, java.lang.InterruptedException
RuntimeVisibleAnnotations:
org.junit.Test()
private static java.lang.Boolean lambda$0();
descriptor: ()Ljava/lang/Boolean;
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=0, args_size=0
0: iconst_1
invokestatic java.lang.Boolean.valueOf:(Z)Ljava/lang/Boolean;
areturn
LocalVariableTable:
Start End Slot Name Signature
}
SourceFile: "CodeInvalidationTest.java"
NestMembers:
org.graalvm.compiler.truffle.test.CodeInvalidationTest$1 org.graalvm.compiler.truffle.test.CodeInvalidationTest$1$1 org.graalvm.compiler.truffle.test.CodeInvalidationTest$AlwaysThrowNode org.graalvm.compiler.truffle.test.CodeInvalidationTest$BaseNode org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode$LoopConditionNode
InnerClasses:
public final Lookup = java.lang.invoke.MethodHandles$Lookup of java.lang.invoke.MethodHandles
org.graalvm.compiler.truffle.test.CodeInvalidationTest$1
final AlwaysThrowNode = org.graalvm.compiler.truffle.test.CodeInvalidationTest$AlwaysThrowNode of org.graalvm.compiler.truffle.test.CodeInvalidationTest
abstract BaseNode = org.graalvm.compiler.truffle.test.CodeInvalidationTest$BaseNode of org.graalvm.compiler.truffle.test.CodeInvalidationTest
final NodeToInvalidate = org.graalvm.compiler.truffle.test.CodeInvalidationTest$NodeToInvalidate of org.graalvm.compiler.truffle.test.CodeInvalidationTest
private RunCode = org.graalvm.compiler.truffle.test.CodeInvalidationTest$RunCode of org.graalvm.compiler.truffle.test.CodeInvalidationTest
final WhileLoopNode = org.graalvm.compiler.truffle.test.CodeInvalidationTest$WhileLoopNode of org.graalvm.compiler.truffle.test.CodeInvalidationTest
public Builder = org.graalvm.polyglot.Source$Builder of org.graalvm.polyglot.Source