public class com.google.common.base.internal.Finalizer implements java.lang.Runnable
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: com.google.common.base.internal.Finalizer
super_class: java.lang.Object
{
private static final java.util.logging.Logger logger;
descriptor: Ljava/util/logging/Logger;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final java.lang.String FINALIZABLE_REFERENCE;
descriptor: Ljava/lang/String;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
ConstantValue: "com.google.common.base.FinalizableReference"
private final java.lang.ref.WeakReference<java.lang.Class<?>> finalizableReferenceClassReference;
descriptor: Ljava/lang/ref/WeakReference;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Ljava/lang/ref/WeakReference<Ljava/lang/Class<*>;>;
private final java.lang.ref.PhantomReference<java.lang.Object> frqReference;
descriptor: Ljava/lang/ref/PhantomReference;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Ljava/lang/ref/PhantomReference<Ljava/lang/Object;>;
private final java.lang.ref.ReferenceQueue<java.lang.Object> queue;
descriptor: Ljava/lang/ref/ReferenceQueue;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Ljava/lang/ref/ReferenceQueue<Ljava/lang/Object;>;
private static final java.lang.reflect.Constructor<java.lang.Thread> bigThreadConstructor;
descriptor: Ljava/lang/reflect/Constructor;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/lang/reflect/Constructor<Ljava/lang/Thread;>;
RuntimeVisibleTypeAnnotations:
FIELD
org.checkerframework.checker.nullness.qual.Nullable()
private static final java.lang.reflect.Field inheritableThreadLocals;
descriptor: Ljava/lang/reflect/Field;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
RuntimeVisibleTypeAnnotations:
FIELD
org.checkerframework.checker.nullness.qual.Nullable()
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=1, locals=0, args_size=0
0: ldc Lcom/google/common/base/internal/Finalizer;
invokevirtual java.lang.Class.getName:()Ljava/lang/String;
invokestatic java.util.logging.Logger.getLogger:(Ljava/lang/String;)Ljava/util/logging/Logger;
putstatic com.google.common.base.internal.Finalizer.logger:Ljava/util/logging/Logger;
1: invokestatic com.google.common.base.internal.Finalizer.getBigThreadConstructor:()Ljava/lang/reflect/Constructor;
2: putstatic com.google.common.base.internal.Finalizer.bigThreadConstructor:Ljava/lang/reflect/Constructor;
3: getstatic com.google.common.base.internal.Finalizer.bigThreadConstructor:Ljava/lang/reflect/Constructor;
ifnonnull 4
invokestatic com.google.common.base.internal.Finalizer.getInheritableThreadLocalsField:()Ljava/lang/reflect/Field;
goto 5
StackMap locals:
StackMap stack:
4: aconst_null
5: StackMap locals:
StackMap stack: java.lang.reflect.Field
putstatic com.google.common.base.internal.Finalizer.inheritableThreadLocals:Ljava/lang/reflect/Field;
6: return
LocalVariableTable:
Start End Slot Name Signature
public static void startFinalizer(java.lang.Class<?>, java.lang.ref.ReferenceQueue<java.lang.Object>, java.lang.ref.PhantomReference<java.lang.Object>);
descriptor: (Ljava/lang/Class;Ljava/lang/ref/ReferenceQueue;Ljava/lang/ref/PhantomReference;)V
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=6, locals=9, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokevirtual java.lang.Class.getName:()Ljava/lang/String;
ldc "com.google.common.base.FinalizableReference"
invokevirtual java.lang.String.equals:(Ljava/lang/Object;)Z
ifne 2
1: new java.lang.IllegalArgumentException
dup
ldc "Expected com.google.common.base.FinalizableReference."
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
2: StackMap locals:
StackMap stack:
new com.google.common.base.internal.Finalizer
dup
aload 0
aload 1
aload 2
invokespecial com.google.common.base.internal.Finalizer.<init>:(Ljava/lang/Class;Ljava/lang/ref/ReferenceQueue;Ljava/lang/ref/PhantomReference;)V
astore 3
start local 3 3: ldc Lcom/google/common/base/internal/Finalizer;
invokevirtual java.lang.Class.getName:()Ljava/lang/String;
astore 4
start local 4 4: aconst_null
astore 5
start local 5 5: getstatic com.google.common.base.internal.Finalizer.bigThreadConstructor:Ljava/lang/reflect/Constructor;
ifnull 17
6: iconst_0
istore 6
start local 6 7: lconst_0
lstore 7
start local 7 8: getstatic com.google.common.base.internal.Finalizer.bigThreadConstructor:Ljava/lang/reflect/Constructor;
iconst_5
anewarray java.lang.Object
dup
iconst_0
9: aconst_null
aastore
dup
iconst_1
aload 3
aastore
dup
iconst_2
aload 4
aastore
dup
iconst_3
lload 7
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_4
iload 6
invokestatic java.lang.Boolean.valueOf:(Z)Ljava/lang/Boolean;
aastore
10: invokevirtual java.lang.reflect.Constructor.newInstance:([Ljava/lang/Object;)Ljava/lang/Object;
checkcast java.lang.Thread
11: astore 5
end local 7 end local 6 12: goto 17
StackMap locals: java.lang.Class java.lang.ref.ReferenceQueue java.lang.ref.PhantomReference com.google.common.base.internal.Finalizer java.lang.String java.lang.Thread
StackMap stack: java.lang.Throwable
13: astore 6
start local 6 14: getstatic com.google.common.base.internal.Finalizer.logger:Ljava/util/logging/Logger;
15: getstatic java.util.logging.Level.INFO:Ljava/util/logging/Level;
ldc "Failed to create a thread without inherited thread-local values"
aload 6
16: invokevirtual java.util.logging.Logger.log:(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/Throwable;)V
end local 6 17: StackMap locals:
StackMap stack:
aload 5
ifnonnull 19
18: new java.lang.Thread
dup
aconst_null
aload 3
aload 4
invokespecial java.lang.Thread.<init>:(Ljava/lang/ThreadGroup;Ljava/lang/Runnable;Ljava/lang/String;)V
astore 5
19: StackMap locals:
StackMap stack:
aload 5
iconst_1
invokevirtual java.lang.Thread.setDaemon:(Z)V
20: getstatic com.google.common.base.internal.Finalizer.inheritableThreadLocals:Ljava/lang/reflect/Field;
ifnull 29
21: getstatic com.google.common.base.internal.Finalizer.inheritableThreadLocals:Ljava/lang/reflect/Field;
aload 5
aconst_null
invokevirtual java.lang.reflect.Field.set:(Ljava/lang/Object;Ljava/lang/Object;)V
22: goto 29
StackMap locals:
StackMap stack: java.lang.Throwable
23: astore 6
start local 6 24: getstatic com.google.common.base.internal.Finalizer.logger:Ljava/util/logging/Logger;
25: getstatic java.util.logging.Level.INFO:Ljava/util/logging/Level;
26: ldc "Failed to clear thread local values inherited by reference finalizer thread."
27: aload 6
28: invokevirtual java.util.logging.Logger.log:(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/Throwable;)V
end local 6 29: StackMap locals:
StackMap stack:
aload 5
invokevirtual java.lang.Thread.start:()V
30: return
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 31 0 finalizableReferenceClass Ljava/lang/Class<*>;
0 31 1 queue Ljava/lang/ref/ReferenceQueue<Ljava/lang/Object;>;
0 31 2 frqReference Ljava/lang/ref/PhantomReference<Ljava/lang/Object;>;
3 31 3 finalizer Lcom/google/common/base/internal/Finalizer;
4 31 4 threadName Ljava/lang/String;
5 31 5 thread Ljava/lang/Thread;
7 12 6 inheritThreadLocals Z
8 12 7 defaultStackSize J
14 17 6 t Ljava/lang/Throwable;
24 29 6 t Ljava/lang/Throwable;
Exception table:
from to target type
6 12 13 Class java.lang.Throwable
20 22 23 Class java.lang.Throwable
Signature: (Ljava/lang/Class<*>;Ljava/lang/ref/ReferenceQueue<Ljava/lang/Object;>;Ljava/lang/ref/PhantomReference<Ljava/lang/Object;>;)V
MethodParameters:
Name Flags
finalizableReferenceClass
queue
frqReference
private void <init>(java.lang.Class<?>, java.lang.ref.ReferenceQueue<java.lang.Object>, java.lang.ref.PhantomReference<java.lang.Object>);
descriptor: (Ljava/lang/Class;Ljava/lang/ref/ReferenceQueue;Ljava/lang/ref/PhantomReference;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=4, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
aload 2
putfield com.google.common.base.internal.Finalizer.queue:Ljava/lang/ref/ReferenceQueue;
2: aload 0
3: new java.lang.ref.WeakReference
dup
aload 1
invokespecial java.lang.ref.WeakReference.<init>:(Ljava/lang/Object;)V
4: putfield com.google.common.base.internal.Finalizer.finalizableReferenceClassReference:Ljava/lang/ref/WeakReference;
5: aload 0
aload 3
putfield com.google.common.base.internal.Finalizer.frqReference:Ljava/lang/ref/PhantomReference;
6: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lcom/google/common/base/internal/Finalizer;
0 7 1 finalizableReferenceClass Ljava/lang/Class<*>;
0 7 2 queue Ljava/lang/ref/ReferenceQueue<Ljava/lang/Object;>;
0 7 3 frqReference Ljava/lang/ref/PhantomReference<Ljava/lang/Object;>;
Signature: (Ljava/lang/Class<*>;Ljava/lang/ref/ReferenceQueue<Ljava/lang/Object;>;Ljava/lang/ref/PhantomReference<Ljava/lang/Object;>;)V
MethodParameters:
Name Flags
finalizableReferenceClass
queue
frqReference
public void run();
descriptor: ()V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: StackMap locals:
StackMap stack:
aload 0
aload 0
getfield com.google.common.base.internal.Finalizer.queue:Ljava/lang/ref/ReferenceQueue;
invokevirtual java.lang.ref.ReferenceQueue.remove:()Ljava/lang/ref/Reference;
invokevirtual com.google.common.base.internal.Finalizer.cleanUp:(Ljava/lang/ref/Reference;)Z
ifne 0
1: goto 4
2: StackMap locals:
StackMap stack: java.lang.InterruptedException
pop
3: goto 0
4: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lcom/google/common/base/internal/Finalizer;
Exception table:
from to target type
0 1 2 Class java.lang.InterruptedException
private boolean cleanUp(java.lang.ref.Reference<?>);
descriptor: (Ljava/lang/ref/Reference;)Z
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual com.google.common.base.internal.Finalizer.getFinalizeReferentMethod:()Ljava/lang/reflect/Method;
astore 2
start local 2 1: aload 2
ifnonnull 3
2: iconst_0
ireturn
3: StackMap locals: java.lang.reflect.Method
StackMap stack:
aload 1
invokevirtual java.lang.ref.Reference.clear:()V
4: aload 1
aload 0
getfield com.google.common.base.internal.Finalizer.frqReference:Ljava/lang/ref/PhantomReference;
if_acmpne 6
5: iconst_0
ireturn
6: StackMap locals:
StackMap stack:
aload 2
aload 1
iconst_0
anewarray java.lang.Object
invokevirtual java.lang.reflect.Method.invoke:(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;
pop
7: goto 10
StackMap locals:
StackMap stack: java.lang.Throwable
8: astore 3
start local 3 9: getstatic com.google.common.base.internal.Finalizer.logger:Ljava/util/logging/Logger;
getstatic java.util.logging.Level.SEVERE:Ljava/util/logging/Level;
ldc "Error cleaning up after reference."
aload 3
invokevirtual java.util.logging.Logger.log:(Ljava/util/logging/Level;Ljava/lang/String;Ljava/lang/Throwable;)V
end local 3 10: StackMap locals:
StackMap stack:
aload 0
getfield com.google.common.base.internal.Finalizer.queue:Ljava/lang/ref/ReferenceQueue;
invokevirtual java.lang.ref.ReferenceQueue.poll:()Ljava/lang/ref/Reference;
dup
astore 1
ifnonnull 3
11: iconst_1
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 this Lcom/google/common/base/internal/Finalizer;
0 12 1 reference Ljava/lang/ref/Reference<*>;
1 12 2 finalizeReferentMethod Ljava/lang/reflect/Method;
9 10 3 t Ljava/lang/Throwable;
Exception table:
from to target type
6 7 8 Class java.lang.Throwable
Signature: (Ljava/lang/ref/Reference<*>;)Z
MethodParameters:
Name Flags
reference
private java.lang.reflect.Method getFinalizeReferentMethod();
descriptor: ()Ljava/lang/reflect/Method;
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=3, args_size=1
start local 0 0: aload 0
getfield com.google.common.base.internal.Finalizer.finalizableReferenceClassReference:Ljava/lang/ref/WeakReference;
invokevirtual java.lang.ref.WeakReference.get:()Ljava/lang/Object;
checkcast java.lang.Class
astore 1
start local 1 1: aload 1
ifnonnull 3
2: aconst_null
areturn
3: StackMap locals: java.lang.Class
StackMap stack:
aload 1
ldc "finalizeReferent"
iconst_0
anewarray java.lang.Class
invokevirtual java.lang.Class.getMethod:(Ljava/lang/String;[Ljava/lang/Class;)Ljava/lang/reflect/Method;
4: areturn
5: StackMap locals:
StackMap stack: java.lang.NoSuchMethodException
astore 2
start local 2 6: new java.lang.AssertionError
dup
aload 2
invokespecial java.lang.AssertionError.<init>:(Ljava/lang/Object;)V
athrow
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lcom/google/common/base/internal/Finalizer;
1 7 1 finalizableReferenceClass Ljava/lang/Class<*>;
6 7 2 e Ljava/lang/NoSuchMethodException;
Exception table:
from to target type
3 4 5 Class java.lang.NoSuchMethodException
RuntimeVisibleTypeAnnotations:
METHOD_RETURN
org.checkerframework.checker.nullness.qual.Nullable()
private static java.lang.reflect.Field getInheritableThreadLocalsField();
descriptor: ()Ljava/lang/reflect/Field;
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=3, locals=1, args_size=0
0: ldc Ljava/lang/Thread;
ldc "inheritableThreadLocals"
invokevirtual java.lang.Class.getDeclaredField:(Ljava/lang/String;)Ljava/lang/reflect/Field;
astore 0
start local 0 1: aload 0
iconst_1
invokevirtual java.lang.reflect.Field.setAccessible:(Z)V
2: aload 0
3: areturn
end local 0 4: StackMap locals:
StackMap stack: java.lang.Throwable
pop
5: getstatic com.google.common.base.internal.Finalizer.logger:Ljava/util/logging/Logger;
6: getstatic java.util.logging.Level.INFO:Ljava/util/logging/Level;
7: ldc "Couldn't access Thread.inheritableThreadLocals. Reference finalizer threads will inherit thread local values."
8: invokevirtual java.util.logging.Logger.log:(Ljava/util/logging/Level;Ljava/lang/String;)V
9: aconst_null
areturn
LocalVariableTable:
Start End Slot Name Signature
1 4 0 inheritableThreadLocals Ljava/lang/reflect/Field;
Exception table:
from to target type
0 3 4 Class java.lang.Throwable
RuntimeVisibleTypeAnnotations:
METHOD_RETURN
org.checkerframework.checker.nullness.qual.Nullable()
private static java.lang.reflect.Constructor<java.lang.Thread> getBigThreadConstructor();
descriptor: ()Ljava/lang/reflect/Constructor;
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=5, locals=0, args_size=0
0: ldc Ljava/lang/Thread;
iconst_5
anewarray java.lang.Class
dup
iconst_0
1: ldc Ljava/lang/ThreadGroup;
aastore
dup
iconst_1
ldc Ljava/lang/Runnable;
aastore
dup
iconst_2
ldc Ljava/lang/String;
aastore
dup
iconst_3
getstatic java.lang.Long.TYPE:Ljava/lang/Class;
aastore
dup
iconst_4
getstatic java.lang.Boolean.TYPE:Ljava/lang/Class;
aastore
2: invokevirtual java.lang.Class.getConstructor:([Ljava/lang/Class;)Ljava/lang/reflect/Constructor;
3: areturn
4: StackMap locals:
StackMap stack: java.lang.Throwable
pop
5: aconst_null
areturn
LocalVariableTable:
Start End Slot Name Signature
Exception table:
from to target type
0 3 4 Class java.lang.Throwable
Signature: ()Ljava/lang/reflect/Constructor<Ljava/lang/Thread;>;
RuntimeVisibleTypeAnnotations:
METHOD_RETURN
org.checkerframework.checker.nullness.qual.Nullable()
}
SourceFile: "Finalizer.java"