abstract class io.netty.buffer.PoolThreadCache$MemoryRegionCache<T>
minor version: 0
major version: 59
flags: flags: (0x0420) ACC_SUPER, ACC_ABSTRACT
this_class: io.netty.buffer.PoolThreadCache$MemoryRegionCache
super_class: java.lang.Object
{
private final int size;
descriptor: I
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
private final java.util.Queue<io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry<T>> queue;
descriptor: Ljava/util/Queue;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Ljava/util/Queue<Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry<TT;>;>;
private final io.netty.buffer.PoolArena$SizeClass sizeClass;
descriptor: Lio/netty/buffer/PoolArena$SizeClass;
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
Signature: Lio/netty/buffer/PoolArena$SizeClass;
private int allocations;
descriptor: I
flags: (0x0002) ACC_PRIVATE
private static final io.netty.util.Recycler<io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry> RECYCLER;
descriptor: Lio/netty/util/Recycler;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Lio/netty/util/Recycler<Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;>;
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=2, locals=0, args_size=0
0: new io.netty.buffer.PoolThreadCache$MemoryRegionCache$1
dup
invokespecial io.netty.buffer.PoolThreadCache$MemoryRegionCache$1.<init>:()V
putstatic io.netty.buffer.PoolThreadCache$MemoryRegionCache.RECYCLER:Lio/netty/util/Recycler;
1: return
LocalVariableTable:
Start End Slot Name Signature
void <init>(int, io.netty.buffer.PoolArena$SizeClass);
descriptor: (ILio/netty/buffer/PoolArena$SizeClass;)V
flags: (0x0000)
Code:
stack=2, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokespecial java.lang.Object.<init>:()V
1: aload 0
iload 1
invokestatic io.netty.util.internal.MathUtil.safeFindNextPositivePowerOfTwo:(I)I
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.size:I
2: aload 0
aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.size:I
invokestatic io.netty.util.internal.PlatformDependent.newFixedMpscQueue:(I)Ljava/util/Queue;
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.queue:Ljava/util/Queue;
3: aload 0
aload 2
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.sizeClass:Lio/netty/buffer/PoolArena$SizeClass;
4: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
0 5 1 size I
0 5 2 sizeClass Lio/netty/buffer/PoolArena$SizeClass;
Signature: (ILio/netty/buffer/PoolArena$SizeClass;)V
MethodParameters:
Name Flags
size
sizeClass
protected abstract void initBuf(io.netty.buffer.PoolChunk<T>, long, io.netty.buffer.PooledByteBuf<T>, );
descriptor: (Lio/netty/buffer/PoolChunk;JLio/netty/buffer/PooledByteBuf;I)V
flags: (0x0404) ACC_PROTECTED, ACC_ABSTRACT
Signature: (Lio/netty/buffer/PoolChunk<TT;>;JLio/netty/buffer/PooledByteBuf<TT;>;I)V
MethodParameters:
Name Flags
chunk
handle
buf
reqCapacity
public final boolean add(io.netty.buffer.PoolChunk<T>, );
descriptor: (Lio/netty/buffer/PoolChunk;J)Z
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=3, locals=6, args_size=3
start local 0 start local 1 start local 2 0: aload 1
lload 2
invokestatic io.netty.buffer.PoolThreadCache$MemoryRegionCache.newEntry:(Lio/netty/buffer/PoolChunk;J)Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;
astore 4
start local 4 1: aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.queue:Ljava/util/Queue;
aload 4
invokeinterface java.util.Queue.offer:(Ljava/lang/Object;)Z
istore 5
start local 5 2: iload 5
ifne 4
3: aload 4
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.recycle:()V
4: StackMap locals: io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry int
StackMap stack:
iload 5
ireturn
end local 5 end local 4 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
0 5 1 chunk Lio/netty/buffer/PoolChunk<TT;>;
0 5 2 handle J
1 5 4 entry Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry<TT;>;
2 5 5 queued Z
Signature: (Lio/netty/buffer/PoolChunk<TT;>;J)Z
MethodParameters:
Name Flags
chunk
handle
public final boolean allocate(io.netty.buffer.PooledByteBuf<T>, );
descriptor: (Lio/netty/buffer/PooledByteBuf;I)Z
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=6, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.queue:Ljava/util/Queue;
invokeinterface java.util.Queue.poll:()Ljava/lang/Object;
checkcast io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry
astore 3
start local 3 1: aload 3
ifnonnull 3
2: iconst_0
ireturn
3: StackMap locals: io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry
StackMap stack:
aload 0
aload 3
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.chunk:Lio/netty/buffer/PoolChunk;
aload 3
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.handle:J
aload 1
iload 2
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache.initBuf:(Lio/netty/buffer/PoolChunk;JLio/netty/buffer/PooledByteBuf;I)V
4: aload 3
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.recycle:()V
5: aload 0
dup
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.allocations:I
iconst_1
iadd
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.allocations:I
6: iconst_1
ireturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
0 7 1 buf Lio/netty/buffer/PooledByteBuf<TT;>;
0 7 2 reqCapacity I
1 7 3 entry Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry<TT;>;
Signature: (Lio/netty/buffer/PooledByteBuf<TT;>;I)Z
MethodParameters:
Name Flags
buf
reqCapacity
public final int free();
descriptor: ()I
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
ldc 2147483647
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache.free:(I)I
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
private int free(int);
descriptor: (I)I
flags: (0x0002) ACC_PRIVATE
Code:
stack=2, locals=4, args_size=2
start local 0 start local 1 0: iconst_0
istore 2
start local 2 1: goto 8
2: StackMap locals: int
StackMap stack:
aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.queue:Ljava/util/Queue;
invokeinterface java.util.Queue.poll:()Ljava/lang/Object;
checkcast io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry
astore 3
start local 3 3: aload 3
ifnull 6
4: aload 0
aload 3
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache.freeEntry:(Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;)V
5: goto 7
6: StackMap locals: io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry
StackMap stack:
iload 2
ireturn
end local 3 7: StackMap locals:
StackMap stack:
iinc 2 1
StackMap locals:
StackMap stack:
8: iload 2
iload 1
if_icmplt 2
9: iload 2
ireturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
0 10 1 max I
1 10 2 numFreed I
3 7 3 entry Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry<TT;>;
MethodParameters:
Name Flags
max
public final void trim();
descriptor: ()V
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=2, locals=2, args_size=1
start local 0 0: aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.size:I
aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.allocations:I
isub
istore 1
start local 1 1: aload 0
iconst_0
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.allocations:I
2: iload 1
ifle 4
3: aload 0
iload 1
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache.free:(I)I
pop
4: StackMap locals: int
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
1 5 1 free I
private void freeEntry(io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry);
descriptor: (Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=5, locals=5, args_size=2
start local 0 start local 1 0: aload 1
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.chunk:Lio/netty/buffer/PoolChunk;
astore 2
start local 2 1: aload 1
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.handle:J
lstore 3
start local 3 2: aload 1
invokevirtual io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.recycle:()V
3: aload 2
getfield io.netty.buffer.PoolChunk.arena:Lio/netty/buffer/PoolArena;
aload 2
lload 3
aload 0
getfield io.netty.buffer.PoolThreadCache$MemoryRegionCache.sizeClass:Lio/netty/buffer/PoolArena$SizeClass;
invokevirtual io.netty.buffer.PoolArena.freeChunk:(Lio/netty/buffer/PoolChunk;JLio/netty/buffer/PoolArena$SizeClass;)V
4: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Lio/netty/buffer/PoolThreadCache$MemoryRegionCache<TT;>;
0 5 1 entry Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;
1 5 2 chunk Lio/netty/buffer/PoolChunk;
2 5 3 handle J
MethodParameters:
Name Flags
entry
private static io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry newEntry(io.netty.buffer.PoolChunk<?>, long);
descriptor: (Lio/netty/buffer/PoolChunk;J)Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=3, locals=4, args_size=2
start local 0 start local 1 0: getstatic io.netty.buffer.PoolThreadCache$MemoryRegionCache.RECYCLER:Lio/netty/util/Recycler;
invokevirtual io.netty.util.Recycler.get:()Ljava/lang/Object;
checkcast io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry
astore 3
start local 3 1: aload 3
aload 0
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.chunk:Lio/netty/buffer/PoolChunk;
2: aload 3
lload 1
putfield io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry.handle:J
3: aload 3
areturn
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 chunk Lio/netty/buffer/PoolChunk<*>;
0 4 1 handle J
1 4 3 entry Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;
Signature: (Lio/netty/buffer/PoolChunk<*>;J)Lio/netty/buffer/PoolThreadCache$MemoryRegionCache$Entry;
MethodParameters:
Name Flags
chunk
handle
}
Signature: <T:Ljava/lang/Object;>Ljava/lang/Object;
SourceFile: "PoolThreadCache.java"
NestHost: io.netty.buffer.PoolThreadCache
InnerClasses:
final SizeClass = io.netty.buffer.PoolArena$SizeClass of io.netty.buffer.PoolArena
private abstract MemoryRegionCache = io.netty.buffer.PoolThreadCache$MemoryRegionCache of io.netty.buffer.PoolThreadCache
io.netty.buffer.PoolThreadCache$MemoryRegionCache$1
final Entry = io.netty.buffer.PoolThreadCache$MemoryRegionCache$Entry of io.netty.buffer.PoolThreadCache$MemoryRegionCache