public abstract class jdk.internal.foreign.AbstractMemorySegmentImpl extends jdk.internal.access.foreign.MemorySegmentProxy implements jdk.incubator.foreign.MemorySegment
minor version: 0
major version: 59
flags: flags: (0x0421) ACC_PUBLIC, ACC_SUPER, ACC_ABSTRACT
this_class: jdk.internal.foreign.AbstractMemorySegmentImpl
super_class: jdk.internal.access.foreign.MemorySegmentProxy
{
private static final jdk.internal.misc.ScopedMemoryAccess SCOPED_MEMORY_ACCESS;
descriptor: Ljdk/internal/misc/ScopedMemoryAccess;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
private static final boolean enableSmallSegments;
descriptor: Z
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
static final int FIRST_RESERVED_FLAG;
descriptor: I
flags: (0x0018) ACC_STATIC, ACC_FINAL
ConstantValue: 65536
static final int SMALL;
descriptor: I
flags: (0x0018) ACC_STATIC, ACC_FINAL
ConstantValue: 65536
static final long NONCE;
descriptor: J
flags: (0x0018) ACC_STATIC, ACC_FINAL
static final jdk.internal.access.JavaNioAccess nioAccess;
descriptor: Ljdk/internal/access/JavaNioAccess;
flags: (0x0018) ACC_STATIC, ACC_FINAL
final long length;
descriptor: J
flags: (0x0010) ACC_FINAL
final int mask;
descriptor: I
flags: (0x0010) ACC_FINAL
final jdk.internal.foreign.MemoryScope scope;
descriptor: Ljdk/internal/foreign/MemoryScope;
flags: (0x0010) ACC_FINAL
static final boolean $assertionsDisabled;
descriptor: Z
flags: (0x1018) ACC_STATIC, ACC_FINAL, ACC_SYNTHETIC
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=2, locals=0, args_size=0
0: ldc Ljdk/internal/foreign/AbstractMemorySegmentImpl;
invokevirtual java.lang.Class.desiredAssertionStatus:()Z
ifne 1
iconst_1
goto 2
StackMap locals:
StackMap stack:
1: iconst_0
StackMap locals:
StackMap stack: int
2: putstatic jdk.internal.foreign.AbstractMemorySegmentImpl.$assertionsDisabled:Z
3: invokestatic jdk.internal.misc.ScopedMemoryAccess.getScopedMemoryAccess:()Ljdk/internal/misc/ScopedMemoryAccess;
putstatic jdk.internal.foreign.AbstractMemorySegmentImpl.SCOPED_MEMORY_ACCESS:Ljdk/internal/misc/ScopedMemoryAccess;
4: ldc "jdk.incubator.foreign.SmallSegments"
ldc "true"
invokestatic sun.security.action.GetPropertyAction.privilegedGetProperty:(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
invokestatic java.lang.Boolean.parseBoolean:(Ljava/lang/String;)Z
5: putstatic jdk.internal.foreign.AbstractMemorySegmentImpl.enableSmallSegments:Z
6: new java.util.Random
dup
invokespecial java.util.Random.<init>:()V
invokevirtual java.util.Random.nextLong:()J
putstatic jdk.internal.foreign.AbstractMemorySegmentImpl.NONCE:J
7: invokestatic jdk.internal.access.SharedSecrets.getJavaNioAccess:()Ljdk/internal/access/JavaNioAccess;
putstatic jdk.internal.foreign.AbstractMemorySegmentImpl.nioAccess:Ljdk/internal/access/JavaNioAccess;
return
LocalVariableTable:
Start End Slot Name Signature
void <init>(long, int, jdk.internal.foreign.MemoryScope);
descriptor: (JILjdk/internal/foreign/MemoryScope;)V
flags: (0x0000)
Code:
stack=3, locals=5, args_size=4
start local 0 start local 1 start local 3 start local 4 0: aload 0
invokespecial jdk.internal.access.foreign.MemorySegmentProxy.<init>:()V
1: aload 0
lload 1
putfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
2: aload 0
iload 3
putfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
3: aload 0
aload 4
putfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
4: return
end local 4 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 5 1 length J
0 5 3 mask I
0 5 4 scope Ljdk/internal/foreign/MemoryScope;
RuntimeVisibleAnnotations:
jdk.internal.vm.annotation.ForceInline()
MethodParameters:
Name Flags
length
mask
scope
abstract long min();
descriptor: ()J
flags: (0x0400) ACC_ABSTRACT
abstract java.lang.Object base();
descriptor: ()Ljava/lang/Object;
flags: (0x0400) ACC_ABSTRACT
abstract jdk.internal.foreign.AbstractMemorySegmentImpl dup(long, long, int, jdk.internal.foreign.MemoryScope);
descriptor: (JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0400) ACC_ABSTRACT
MethodParameters:
Name Flags
offset
size
mask
scope
abstract java.nio.ByteBuffer makeByteBuffer();
descriptor: ()Ljava/nio/ByteBuffer;
flags: (0x0400) ACC_ABSTRACT
static int defaultAccessModes(long);
descriptor: (J)I
flags: (0x0008) ACC_STATIC
Code:
stack=4, locals=2, args_size=1
start local 0 0: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.enableSmallSegments:Z
ifeq 2
lload 0
ldc 2147483647
lcmp
ifge 2
1: ldc 65567
goto 3
2: StackMap locals:
StackMap stack:
bipush 31
3: StackMap locals:
StackMap stack: int
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 size J
MethodParameters:
Name Flags
size
public jdk.internal.foreign.AbstractMemorySegmentImpl asSlice(long, long);
descriptor: (JJ)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=5, args_size=3
start local 0 start local 1 start local 3 0: aload 0
lload 1
lload 3
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkBounds:(JJ)V
1: aload 0
lload 1
lload 3
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.asSliceNoCheck:(JJ)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 2 1 offset J
0 2 3 newSize J
MethodParameters:
Name Flags
offset
newSize
public jdk.internal.foreign.AbstractMemorySegmentImpl asSlice(long);
descriptor: (J)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=3, args_size=2
start local 0 start local 1 0: aload 0
lload 1
lconst_0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkBounds:(JJ)V
1: aload 0
lload 1
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
lload 1
lsub
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.asSliceNoCheck:(JJ)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 2 1 offset J
MethodParameters:
Name Flags
offset
private jdk.internal.foreign.AbstractMemorySegmentImpl asSliceNoCheck(long, long);
descriptor: (JJ)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0002) ACC_PRIVATE
Code:
stack=7, locals=5, args_size=3
start local 0 start local 1 start local 3 0: aload 0
lload 1
lload 3
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.dup:(JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 1 1 offset J
0 1 3 newSize J
MethodParameters:
Name Flags
offset
newSize
public java.util.Spliterator<jdk.incubator.foreign.MemorySegment> spliterator(jdk.incubator.foreign.SequenceLayout);
descriptor: (Ljdk/incubator/foreign/SequenceLayout;)Ljava/util/Spliterator;
flags: (0x0001) ACC_PUBLIC
Code:
stack=9, locals=2, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
pop
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
2: aload 1
invokevirtual jdk.incubator.foreign.SequenceLayout.byteSize:()J
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.byteSize:()J
lcmp
ifeq 4
3: new java.lang.IllegalArgumentException
dup
invokespecial java.lang.IllegalArgumentException.<init>:()V
athrow
4: StackMap locals:
StackMap stack:
new jdk.internal.foreign.AbstractMemorySegmentImpl$SegmentSplitter
dup
aload 1
invokevirtual jdk.incubator.foreign.SequenceLayout.elementLayout:()Ljdk/incubator/foreign/MemoryLayout;
invokeinterface jdk.incubator.foreign.MemoryLayout.byteSize:()J
aload 1
invokevirtual jdk.incubator.foreign.SequenceLayout.elementCount:()Ljava/util/OptionalLong;
invokevirtual java.util.OptionalLong.getAsLong:()J
5: aload 0
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.accessModes:()I
bipush -5
iand
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.withAccessModes:(I)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
6: invokespecial jdk.internal.foreign.AbstractMemorySegmentImpl$SegmentSplitter.<init>:(JJLjdk/internal/foreign/AbstractMemorySegmentImpl;)V
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 7 1 sequenceLayout Ljdk/incubator/foreign/SequenceLayout;
Signature: (Ljdk/incubator/foreign/SequenceLayout;)Ljava/util/Spliterator<Ljdk/incubator/foreign/MemorySegment;>;
MethodParameters:
Name Flags
sequenceLayout
public final jdk.incubator.foreign.MemorySegment fill(byte);
descriptor: (B)Ljdk/incubator/foreign/MemorySegment;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=8, locals=2, args_size=2
start local 0 start local 1 0: aload 0
lconst_0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
iconst_0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
1: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.SCOPED_MEMORY_ACCESS:Ljdk/internal/misc/ScopedMemoryAccess;
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
iload 1
invokevirtual jdk.internal.misc.ScopedMemoryAccess.setMemory:(Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljava/lang/Object;JJB)V
2: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 value B
MethodParameters:
Name Flags
value
public void copyFrom(jdk.incubator.foreign.MemorySegment);
descriptor: (Ljdk/incubator/foreign/MemorySegment;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=11, locals=5, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
checkcast jdk.internal.foreign.AbstractMemorySegmentImpl
astore 2
start local 2 1: aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.byteSize:()J
lstore 3
start local 3 2: aload 0
lconst_0
lload 3
iconst_0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
3: aload 2
lconst_0
lload 3
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
4: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.SCOPED_MEMORY_ACCESS:Ljdk/internal/misc/ScopedMemoryAccess;
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 2
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
5: aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
6: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
lload 3
7: invokevirtual jdk.internal.misc.ScopedMemoryAccess.copyMemory:(Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljava/lang/Object;JLjava/lang/Object;JJ)V
8: return
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 9 1 src Ljdk/incubator/foreign/MemorySegment;
1 9 2 that Ljdk/internal/foreign/AbstractMemorySegmentImpl;
2 9 3 size J
MethodParameters:
Name Flags
src
public void copyFromSwap(jdk.incubator.foreign.MemorySegment, long);
descriptor: (Ljdk/incubator/foreign/MemorySegment;J)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=13, locals=7, args_size=3
start local 0 start local 1 start local 2 0: aload 1
checkcast jdk.internal.foreign.AbstractMemorySegmentImpl
astore 4
start local 4 1: aload 4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.byteSize:()J
lstore 5
start local 5 2: aload 0
lconst_0
lload 5
iconst_0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
3: aload 4
lconst_0
lload 5
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
4: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.SCOPED_MEMORY_ACCESS:Ljdk/internal/misc/ScopedMemoryAccess;
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 4
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
5: aload 4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
6: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
lload 5
lload 2
7: invokevirtual jdk.internal.misc.ScopedMemoryAccess.copySwapMemory:(Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljava/lang/Object;JLjava/lang/Object;JJJ)V
8: return
end local 5 end local 4 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 9 1 src Ljdk/incubator/foreign/MemorySegment;
0 9 2 elemSize J
1 9 4 that Ljdk/internal/foreign/AbstractMemorySegmentImpl;
2 9 5 size J
MethodParameters:
Name Flags
src
elemSize
public long mismatch(jdk.incubator.foreign.MemorySegment);
descriptor: (Ljdk/incubator/foreign/MemorySegment;)J
flags: (0x0001) ACC_PUBLIC
Code:
stack=10, locals=13, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
checkcast jdk.internal.foreign.AbstractMemorySegmentImpl
astore 2
start local 2 1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.byteSize:()J
lstore 3
start local 3 2: aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.byteSize:()J
lstore 5
start local 5 3: lload 3
lload 5
invokestatic java.lang.Math.min:(JJ)J
lstore 7
start local 7 4: aload 0
lconst_0
lload 7
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
5: aload 2
lconst_0
lload 7
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
6: aload 0
aload 1
if_acmpne 9
7: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
8: ldc -1
lreturn
9: StackMap locals: jdk.internal.foreign.AbstractMemorySegmentImpl jdk.incubator.foreign.MemorySegment jdk.internal.foreign.AbstractMemorySegmentImpl long long long
StackMap stack:
lconst_0
lstore 9
start local 9 10: lload 7
ldc 7
lcmp
ifle 27
11: aload 0
invokestatic jdk.incubator.foreign.MemoryAccess.getByte:(Ljdk/incubator/foreign/MemorySegment;)B
aload 2
invokestatic jdk.incubator.foreign.MemoryAccess.getByte:(Ljdk/incubator/foreign/MemorySegment;)B
if_icmpeq 13
12: lconst_0
lreturn
13: StackMap locals: long
StackMap stack:
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 2
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
14: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
15: aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
16: lload 7
17: invokestatic jdk.internal.foreign.AbstractMemorySegmentImpl.vectorizedMismatchLargeForBytes:(Ljdk/internal/foreign/MemoryScope;Ljdk/internal/foreign/MemoryScope;Ljava/lang/Object;JLjava/lang/Object;JJ)J
lstore 9
18: lload 9
lconst_0
lcmp
iflt 20
19: lload 9
lreturn
20: StackMap locals:
StackMap stack:
lload 9
ldc -1
lxor
lstore 11
start local 11 21: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.$assertionsDisabled:Z
ifne 22
lload 11
ldc 8
lcmp
iflt 22
new java.lang.AssertionError
dup
new java.lang.StringBuilder
dup
ldc "remaining greater than 7: "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
lload 11
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokespecial java.lang.AssertionError.<init>:(Ljava/lang/Object;)V
athrow
22: StackMap locals: long
StackMap stack:
lload 7
lload 11
lsub
lstore 9
end local 11 23: goto 27
24: StackMap locals:
StackMap stack:
aload 0
lload 9
invokestatic jdk.incubator.foreign.MemoryAccess.getByteAtOffset:(Ljdk/incubator/foreign/MemorySegment;J)B
aload 2
lload 9
invokestatic jdk.incubator.foreign.MemoryAccess.getByteAtOffset:(Ljdk/incubator/foreign/MemorySegment;J)B
if_icmpeq 26
25: lload 9
lreturn
26: StackMap locals:
StackMap stack:
lload 9
lconst_1
ladd
lstore 9
StackMap locals:
StackMap stack:
27: lload 9
lload 7
lcmp
iflt 24
28: lload 3
lload 5
lcmp
ifeq 29
lload 7
goto 30
StackMap locals:
StackMap stack:
29: ldc -1
StackMap locals:
StackMap stack: long
30: lreturn
end local 9 end local 7 end local 5 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 31 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 31 1 other Ljdk/incubator/foreign/MemorySegment;
1 31 2 that Ljdk/internal/foreign/AbstractMemorySegmentImpl;
2 31 3 thisSize J
3 31 5 thatSize J
4 31 7 length J
10 31 9 i J
21 23 11 remaining J
MethodParameters:
Name Flags
other
private static long vectorizedMismatchLargeForBytes(jdk.internal.foreign.MemoryScope, jdk.internal.foreign.MemoryScope, java.lang.Object, long, java.lang.Object, long, long);
descriptor: (Ljdk/internal/foreign/MemoryScope;Ljdk/internal/foreign/MemoryScope;Ljava/lang/Object;JLjava/lang/Object;JJ)J
flags: (0x000a) ACC_PRIVATE, ACC_STATIC
Code:
stack=11, locals=17, args_size=7
start local 0 start local 1 start local 2 start local 3 start local 5 start local 6 start local 8 0: lconst_0
lstore 10
start local 10 1: lload 8
lstore 12
start local 12 2: iconst_0
istore 16
start local 16 3: goto 19
4: StackMap locals: jdk.internal.foreign.MemoryScope jdk.internal.foreign.MemoryScope java.lang.Object long java.lang.Object long long long long top top int
StackMap stack:
lload 12
ldc 2147483647
lcmp
ifle 7
5: ldc 2147483647
istore 15
start local 15 6: goto 9
end local 15 7: StackMap locals:
StackMap stack:
lload 12
l2i
istore 15
start local 15 8: iconst_1
istore 16
9: StackMap locals: jdk.internal.foreign.MemoryScope jdk.internal.foreign.MemoryScope java.lang.Object long java.lang.Object long long long long top int int
StackMap stack:
getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.SCOPED_MEMORY_ACCESS:Ljdk/internal/misc/ScopedMemoryAccess;
aload 0
aload 1
10: aload 2
lload 3
lload 10
ladd
11: aload 5
lload 6
lload 10
ladd
12: iload 15
getstatic jdk.internal.util.ArraysSupport.LOG2_ARRAY_BYTE_INDEX_SCALE:I
13: invokevirtual jdk.internal.misc.ScopedMemoryAccess.vectorizedMismatch:(Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljdk/internal/misc/ScopedMemoryAccess$Scope;Ljava/lang/Object;JLjava/lang/Object;JII)I
istore 14
start local 14 14: iload 14
iflt 16
15: lload 10
iload 14
i2l
ladd
lreturn
16: StackMap locals: jdk.internal.foreign.MemoryScope jdk.internal.foreign.MemoryScope java.lang.Object long java.lang.Object long long long long int int int
StackMap stack:
iload 15
iload 14
iconst_m1
ixor
isub
istore 14
17: lload 10
iload 14
i2l
ladd
lstore 10
18: lload 12
iload 14
i2l
lsub
lstore 12
end local 15 end local 14 19: StackMap locals: jdk.internal.foreign.MemoryScope jdk.internal.foreign.MemoryScope java.lang.Object long java.lang.Object long long long long top top int
StackMap stack:
lload 12
ldc 7
lcmp
ifle 20
iload 16
ifeq 4
20: StackMap locals:
StackMap stack:
lload 12
ldc -1
lxor
lreturn
end local 16 end local 12 end local 10 end local 8 end local 6 end local 5 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 21 0 aScope Ljdk/internal/foreign/MemoryScope;
0 21 1 bScope Ljdk/internal/foreign/MemoryScope;
0 21 2 a Ljava/lang/Object;
0 21 3 aOffset J
0 21 5 b Ljava/lang/Object;
0 21 6 bOffset J
0 21 8 length J
1 21 10 off J
2 21 12 remaining J
14 19 14 i I
6 7 15 size I
8 19 15 size I
3 21 16 lastSubRange Z
MethodParameters:
Name Flags
aScope
bScope
a
aOffset
b
bOffset
length
public final jdk.incubator.foreign.MemoryAddress address();
descriptor: ()Ljdk/incubator/foreign/MemoryAddress;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
1: new jdk.internal.foreign.MemoryAddressImpl
dup
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
invokespecial jdk.internal.foreign.MemoryAddressImpl.<init>:(Ljava/lang/Object;J)V
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
RuntimeVisibleAnnotations:
jdk.internal.vm.annotation.ForceInline()
public final java.nio.ByteBuffer asByteBuffer();
descriptor: ()Ljava/nio/ByteBuffer;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=3, locals=2, args_size=1
start local 0 0: aload 0
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 2
1: aload 0
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
2: StackMap locals:
StackMap stack:
aload 0
ldc "ByteBuffer"
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkArraySize:(Ljava/lang/String;I)I
pop
3: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.makeByteBuffer:()Ljava/nio/ByteBuffer;
astore 1
start local 1 4: aload 0
iconst_2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 6
5: aload 1
invokevirtual java.nio.ByteBuffer.asReadOnlyBuffer:()Ljava/nio/ByteBuffer;
astore 1
6: StackMap locals: java.nio.ByteBuffer
StackMap stack:
aload 1
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
4 7 1 _bb Ljava/nio/ByteBuffer;
public final int accessModes();
descriptor: ()I
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
bipush 31
iand
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final long byteSize();
descriptor: ()J
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final boolean isAlive();
descriptor: ()Z
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.MemoryScope.isAlive:()Z
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public java.lang.Thread ownerThread();
descriptor: ()Ljava/lang/Thread;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.MemoryScope.ownerThread:()Ljava/lang/Thread;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public jdk.internal.foreign.AbstractMemorySegmentImpl withAccessModes(int);
descriptor: (I)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=2, args_size=2
start local 0 start local 1 0: aload 0
iload 1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccessModes:(I)V
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.accessModes:()I
iconst_m1
ixor
iload 1
iand
ifeq 3
2: new java.lang.IllegalArgumentException
dup
ldc "Cannot acquire more access modes"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
3: StackMap locals:
StackMap stack:
aload 0
lconst_0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
bipush -32
iand
iload 1
ior
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.dup:(JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 4 1 accessModes I
MethodParameters:
Name Flags
accessModes
public boolean hasAccessModes(int);
descriptor: (I)Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
iload 1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccessModes:(I)V
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.accessModes:()I
iload 1
iand
iload 1
if_icmpne 2
iconst_1
ireturn
StackMap locals:
StackMap stack:
2: iconst_0
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 accessModes I
MethodParameters:
Name Flags
accessModes
private void checkAccessModes(int);
descriptor: (I)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: iload 1
bipush -32
iand
ifeq 2
1: new java.lang.IllegalArgumentException
dup
ldc "Invalid access modes"
invokespecial java.lang.IllegalArgumentException.<init>:(Ljava/lang/String;)V
athrow
2: StackMap locals:
StackMap stack:
return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 accessModes I
MethodParameters:
Name Flags
accessModes
public jdk.incubator.foreign.MemorySegment handoff(java.lang.Thread);
descriptor: (Ljava/lang/Thread;)Ljdk/incubator/foreign/MemorySegment;
flags: (0x0001) ACC_PUBLIC
Code:
stack=8, locals=4, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
pop
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
2: aload 0
bipush 16
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 4
3: aload 0
bipush 16
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
4: StackMap locals:
StackMap stack:
aload 0
lconst_0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 1
invokevirtual jdk.internal.foreign.MemoryScope.confineTo:(Ljava/lang/Thread;)Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.dup:(JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
astore 3
5: invokestatic java.lang.invoke.VarHandle.fullFence:()V
6: aload 3
areturn
7: StackMap locals:
StackMap stack: java.lang.Throwable
astore 2
8: invokestatic java.lang.invoke.VarHandle.fullFence:()V
9: aload 2
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 10 1 thread Ljava/lang/Thread;
Exception table:
from to target type
4 5 7 any
MethodParameters:
Name Flags
thread
public jdk.incubator.foreign.MemorySegment share();
descriptor: ()Ljdk/incubator/foreign/MemorySegment;
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=3, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
1: aload 0
bipush 8
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 3
2: aload 0
bipush 8
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
3: StackMap locals:
StackMap stack:
aload 0
lconst_0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.MemoryScope.share:()Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.dup:(JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
astore 2
4: invokestatic java.lang.invoke.VarHandle.fullFence:()V
5: aload 2
areturn
6: StackMap locals:
StackMap stack: java.lang.Throwable
astore 1
7: invokestatic java.lang.invoke.VarHandle.fullFence:()V
8: aload 1
athrow
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
Exception table:
from to target type
3 4 6 any
public jdk.incubator.foreign.MemorySegment handoff(jdk.incubator.foreign.NativeScope);
descriptor: (Ljdk/incubator/foreign/NativeScope;)Ljdk/incubator/foreign/MemorySegment;
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=3, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
pop
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
2: aload 0
bipush 16
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 4
3: aload 0
bipush 16
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
4: StackMap locals:
StackMap stack:
aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 6
5: aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
6: StackMap locals:
StackMap stack:
aload 0
aload 1
invokeinterface jdk.incubator.foreign.NativeScope.ownerThread:()Ljava/lang/Thread;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.handoff:(Ljava/lang/Thread;)Ljdk/incubator/foreign/MemorySegment;
astore 2
start local 2 7: aload 1
checkcast jdk.internal.foreign.AbstractNativeScope
aload 2
invokevirtual jdk.internal.foreign.AbstractNativeScope.register:(Ljdk/incubator/foreign/MemorySegment;)V
8: aload 2
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.accessModes:()I
iconst_3
iand
invokeinterface jdk.incubator.foreign.MemorySegment.withAccessModes:(I)Ljdk/incubator/foreign/MemorySegment;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 9 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 9 1 scope Ljdk/incubator/foreign/NativeScope;
7 9 2 dup Ljdk/incubator/foreign/MemorySegment;
MethodParameters:
Name Flags
scope
public jdk.incubator.foreign.MemorySegment registerCleaner(java.lang.ref.Cleaner);
descriptor: (Ljava/lang/ref/Cleaner;)Ljdk/incubator/foreign/MemorySegment;
flags: (0x0001) ACC_PUBLIC
Code:
stack=8, locals=2, args_size=2
start local 0 start local 1 0: aload 1
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
pop
1: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
2: aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 4
3: aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
4: StackMap locals:
StackMap stack:
aload 0
lconst_0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
aload 1
invokevirtual jdk.internal.foreign.MemoryScope.cleanable:(Ljava/lang/ref/Cleaner;)Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.dup:(JJILjdk/internal/foreign/MemoryScope;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 5 1 cleaner Ljava/lang/ref/Cleaner;
MethodParameters:
Name Flags
cleaner
public final void close();
descriptor: ()V
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
1: aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 3
2: aload 0
iconst_4
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
3: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.MemoryScope.close:()V
4: return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public boolean isMapped();
descriptor: ()Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: iconst_0
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final byte[] toByteArray();
descriptor: ()[B
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [B
iconst_1
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$0(I)[B (6)
(I)[B
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([B)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([B)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast byte[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final short[] toShortArray();
descriptor: ()[S
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [S
iconst_2
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$2(I)[S (6)
(I)[S
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([S)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([S)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast short[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final char[] toCharArray();
descriptor: ()[C
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [C
iconst_2
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$4(I)[C (6)
(I)[C
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([C)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([C)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast char[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final int[] toIntArray();
descriptor: ()[I
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [I
iconst_4
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$6(I)[I (6)
(I)[I
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([I)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([I)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast int[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final float[] toFloatArray();
descriptor: ()[F
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [F
iconst_4
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$8(I)[F (6)
(I)[F
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([F)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([F)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast float[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final long[] toLongArray();
descriptor: ()[J
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [J
bipush 8
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$10(I)[J (6)
(I)[J
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([J)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([J)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast long[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public final double[] toDoubleArray();
descriptor: ()[D
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
ldc [D
bipush 8
invokedynamic apply()Ljava/util/function/IntFunction;
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:
(I)Ljava/lang/Object;
jdk/internal/foreign/AbstractMemorySegmentImpl.lambda$12(I)[D (6)
(I)[D
invokedynamic apply()Ljava/util/function/Function;
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;)Ljava/lang/Object;
jdk/incubator/foreign/MemorySegment.ofArray([D)Ljdk/incubator/foreign/MemorySegment; (6 itf)
([D)Ljdk/incubator/foreign/MemorySegment;
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.toArray:(Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
checkcast double[]
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
private <Z> Z toArray(java.lang.Class<Z>, int, java.util.function.IntFunction<Z>, java.util.function.Function<Z, jdk.incubator.foreign.MemorySegment>);
descriptor: (Ljava/lang/Class;ILjava/util/function/IntFunction;Ljava/util/function/Function;)Ljava/lang/Object;
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=8, args_size=5
start local 0 start local 1 start local 2 start local 3 start local 4 0: aload 0
aload 1
invokevirtual java.lang.Class.getSimpleName:()Ljava/lang/String;
iload 2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkArraySize:(Ljava/lang/String;I)I
istore 5
start local 5 1: aload 3
iload 5
invokeinterface java.util.function.IntFunction.apply:(I)Ljava/lang/Object;
astore 6
start local 6 2: aload 4
aload 6
invokeinterface java.util.function.Function.apply:(Ljava/lang/Object;)Ljava/lang/Object;
checkcast jdk.incubator.foreign.MemorySegment
astore 7
start local 7 3: aload 7
aload 0
invokeinterface jdk.incubator.foreign.MemorySegment.copyFrom:(Ljdk/incubator/foreign/MemorySegment;)V
4: aload 6
areturn
end local 7 end local 6 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 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 5 1 arrayClass Ljava/lang/Class<TZ;>;
0 5 2 elemSize I
0 5 3 arrayFactory Ljava/util/function/IntFunction<TZ;>;
0 5 4 segmentFactory Ljava/util/function/Function<TZ;Ljdk/incubator/foreign/MemorySegment;>;
1 5 5 size I
2 5 6 arr TZ;
3 5 7 arrSegment Ljdk/incubator/foreign/MemorySegment;
Signature: <Z:Ljava/lang/Object;>(Ljava/lang/Class<TZ;>;ILjava/util/function/IntFunction<TZ;>;Ljava/util/function/Function<TZ;Ljdk/incubator/foreign/MemorySegment;>;)TZ;
MethodParameters:
Name Flags
arrayClass
elemSize
arrayFactory
segmentFactory
public boolean isSmall();
descriptor: ()Z
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
ldc 65536
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public void checkAccess(long, long, boolean);
descriptor: (JJZ)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=6, args_size=4
start local 0 start local 1 start local 3 start local 5 0: iload 5
ifne 2
aload 0
iconst_2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 2
1: aload 0
iconst_2
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
2: StackMap locals:
StackMap stack:
iload 5
ifeq 4
aload 0
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSet:(I)Z
ifne 4
3: aload 0
iconst_1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.unsupportedAccessMode:(I)Ljava/lang/UnsupportedOperationException;
athrow
4: StackMap locals:
StackMap stack:
aload 0
lload 1
lload 3
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkBounds:(JJ)V
5: return
end local 5 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 6 1 offset J
0 6 3 length J
0 6 5 readOnly Z
MethodParameters:
Name Flags
offset
length
readOnly
private void checkAccessAndScope(long, long, boolean);
descriptor: (JJZ)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=6, args_size=4
start local 0 start local 1 start local 3 start local 5 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkValidState:()V
1: aload 0
lload 1
lload 3
iload 5
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkAccess:(JJZ)V
2: return
end local 5 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 offset J
0 3 3 length J
0 3 5 readOnly Z
MethodParameters:
Name Flags
offset
length
readOnly
private void checkValidState();
descriptor: ()V
flags: (0x0002) ACC_PRIVATE
Code:
stack=3, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
invokevirtual jdk.internal.foreign.MemoryScope.checkValidState:()V
1: goto 4
StackMap locals:
StackMap stack: jdk.internal.misc.ScopedMemoryAccess$Scope$ScopedAccessError
2: pop
3: new java.lang.IllegalStateException
dup
ldc "This segment is already closed"
invokespecial java.lang.IllegalStateException.<init>:(Ljava/lang/String;)V
athrow
4: StackMap locals:
StackMap stack:
return
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
Exception table:
from to target type
0 1 2 Class jdk.internal.misc.ScopedMemoryAccess$Scope$ScopedAccessError
public long unsafeGetOffset();
descriptor: ()J
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
lreturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public java.lang.Object unsafeGetBase();
descriptor: ()Ljava/lang/Object;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
private boolean isSet(int);
descriptor: (I)Z
flags: (0x0002) ACC_PRIVATE
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
iload 1
iand
ifeq 1
iconst_1
ireturn
StackMap locals:
StackMap stack:
1: iconst_0
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 2 1 mask I
MethodParameters:
Name Flags
mask
private int checkArraySize(java.lang.String, int);
descriptor: (Ljava/lang/String;I)I
flags: (0x0002) ACC_PRIVATE
Code:
stack=8, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
iload 2
i2l
lrem
lconst_0
lcmp
ifeq 2
1: new java.lang.UnsupportedOperationException
dup
ldc "Segment size is not a multiple of %d. Size: %d"
iconst_2
anewarray java.lang.Object
dup
iconst_0
iload 2
invokestatic java.lang.Integer.valueOf:(I)Ljava/lang/Integer;
aastore
dup
iconst_1
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.UnsupportedOperationException.<init>:(Ljava/lang/String;)V
athrow
2: StackMap locals:
StackMap stack:
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
iload 2
i2l
ldiv
lstore 3
start local 3 3: lload 3
ldc 2147483639
lcmp
ifle 5
4: new java.lang.UnsupportedOperationException
dup
ldc "Segment is too large to wrap as %s. Size: %d"
iconst_2
anewarray java.lang.Object
dup
iconst_0
aload 1
aastore
dup
iconst_1
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.UnsupportedOperationException.<init>:(Ljava/lang/String;)V
athrow
5: StackMap locals: long
StackMap stack:
lload 3
l2i
ireturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 6 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 6 1 typeName Ljava/lang/String;
0 6 2 elemSize I
3 6 3 arraySize J
MethodParameters:
Name Flags
typeName
elemSize
private void checkBounds(long, long);
descriptor: (JJ)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=6, locals=5, args_size=3
start local 0 start local 1 start local 3 0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.isSmall:()Z
ifeq 3
1: aload 0
lload 1
l2i
lload 3
l2i
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.checkBoundsSmall:(II)V
2: goto 7
3: StackMap locals:
StackMap stack:
lload 3
lconst_0
lcmp
iflt 6
4: lload 1
lconst_0
lcmp
iflt 6
5: lload 1
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
lload 3
lsub
lcmp
ifle 7
6: StackMap locals:
StackMap stack:
aload 0
lload 1
lload 3
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.outOfBoundException:(JJ)Ljava/lang/IndexOutOfBoundsException;
athrow
7: StackMap locals:
StackMap stack:
return
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 8 1 offset J
0 8 3 length J
MethodParameters:
Name Flags
offset
length
public jdk.internal.foreign.MemoryScope scope();
descriptor: ()Ljdk/internal/foreign/MemoryScope;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
private void checkBoundsSmall(int, int);
descriptor: (II)V
flags: (0x0002) ACC_PRIVATE
Code:
stack=5, locals=3, args_size=3
start local 0 start local 1 start local 2 0: iload 2
iflt 3
1: iload 1
iflt 3
2: iload 1
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
l2i
iload 2
isub
if_icmple 4
3: StackMap locals:
StackMap stack:
aload 0
iload 1
i2l
iload 2
i2l
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.outOfBoundException:(JJ)Ljava/lang/IndexOutOfBoundsException;
athrow
4: StackMap locals:
StackMap stack:
return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 5 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 5 1 offset I
0 5 2 length I
MethodParameters:
Name Flags
offset
length
java.lang.UnsupportedOperationException unsupportedAccessMode(int);
descriptor: (I)Ljava/lang/UnsupportedOperationException;
flags: (0x0000)
Code:
stack=8, locals=2, args_size=2
start local 0 start local 1 0: new java.lang.UnsupportedOperationException
dup
ldc "Required access mode %s ; current access modes: %s"
iconst_2
anewarray java.lang.Object
dup
iconst_0
1: aload 0
iload 1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.modeStrings:(I)Ljava/util/List;
iconst_0
invokeinterface java.util.List.get:(I)Ljava/lang/Object;
aastore
dup
iconst_1
aload 0
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.modeStrings:(I)Ljava/util/List;
aastore
2: invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.UnsupportedOperationException.<init>:(Ljava/lang/String;)V
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 expected I
MethodParameters:
Name Flags
expected
private java.util.List<java.lang.String> modeStrings(int);
descriptor: (I)Ljava/util/List;
flags: (0x0002) ACC_PRIVATE
Code:
stack=2, locals=3, args_size=2
start local 0 start local 1 0: new java.util.ArrayList
dup
invokespecial java.util.ArrayList.<init>:()V
astore 2
start local 2 1: iload 1
iconst_1
iand
ifeq 3
2: aload 2
ldc "READ"
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
3: StackMap locals: java.util.List
StackMap stack:
iload 1
iconst_2
iand
ifeq 5
4: aload 2
ldc "WRITE"
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
5: StackMap locals:
StackMap stack:
iload 1
iconst_4
iand
ifeq 7
6: aload 2
ldc "CLOSE"
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
7: StackMap locals:
StackMap stack:
iload 1
bipush 8
iand
ifeq 9
8: aload 2
ldc "SHARE"
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
9: StackMap locals:
StackMap stack:
iload 1
bipush 16
iand
ifeq 11
10: aload 2
ldc "HANDOFF"
invokeinterface java.util.List.add:(Ljava/lang/Object;)Z
pop
11: StackMap locals:
StackMap stack:
aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 12 1 mode I
1 12 2 modes Ljava/util/List<Ljava/lang/String;>;
Signature: (I)Ljava/util/List<Ljava/lang/String;>;
MethodParameters:
Name Flags
mode
private java.lang.IndexOutOfBoundsException outOfBoundException(long, long);
descriptor: (JJ)Ljava/lang/IndexOutOfBoundsException;
flags: (0x0002) ACC_PRIVATE
Code:
stack=8, locals=5, args_size=3
start local 0 start local 1 start local 3 0: new java.lang.IndexOutOfBoundsException
dup
ldc "Out of bound access on segment %s; new offset = %d; new length = %d"
iconst_3
anewarray java.lang.Object
dup
iconst_0
1: aload 0
aastore
dup
iconst_1
lload 1
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_2
lload 3
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
2: invokestatic java.lang.String.format:(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;
invokespecial java.lang.IndexOutOfBoundsException.<init>:(Ljava/lang/String;)V
areturn
end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
0 3 1 offset J
0 3 3 length J
MethodParameters:
Name Flags
offset
length
protected int id();
descriptor: ()I
flags: (0x0004) ACC_PROTECTED
Code:
stack=5, locals=1, args_size=1
start local 0 0: iconst_3
anewarray java.lang.Object
dup
iconst_0
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.base:()Ljava/lang/Object;
aastore
dup
iconst_1
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.min:()J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
dup
iconst_2
getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.NONCE:J
invokestatic java.lang.Long.valueOf:(J)Ljava/lang/Long;
aastore
invokestatic java.util.Objects.hash:([Ljava/lang/Object;)I
invokestatic java.lang.Math.abs:(I)I
ireturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public java.lang.String toString();
descriptor: ()Ljava/lang/String;
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=1, args_size=1
start local 0 0: new java.lang.StringBuilder
dup
ldc "MemorySegment{ id=0x"
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.id:()I
i2l
invokestatic java.lang.Long.toHexString:(J)Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " limit: "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
aload 0
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.length:J
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
ldc " }"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Ljdk/internal/foreign/AbstractMemorySegmentImpl;
public static jdk.internal.foreign.AbstractMemorySegmentImpl ofBuffer(java.nio.ByteBuffer);
descriptor: (Ljava/nio/ByteBuffer;)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=9, locals=11, args_size=1
start local 0 0: aload 0
invokestatic java.util.Objects.requireNonNull:(Ljava/lang/Object;)Ljava/lang/Object;
pop
1: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.nioAccess:Ljdk/internal/access/JavaNioAccess;
aload 0
invokeinterface jdk.internal.access.JavaNioAccess.getBufferAddress:(Ljava/nio/ByteBuffer;)J
lstore 1
start local 1 2: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.nioAccess:Ljdk/internal/access/JavaNioAccess;
aload 0
invokeinterface jdk.internal.access.JavaNioAccess.getBufferBase:(Ljava/nio/ByteBuffer;)Ljava/lang/Object;
astore 3
start local 3 3: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.nioAccess:Ljdk/internal/access/JavaNioAccess;
aload 0
invokeinterface jdk.internal.access.JavaNioAccess.unmapper:(Ljava/nio/ByteBuffer;)Ljdk/internal/access/foreign/UnmapperProxy;
astore 4
start local 4 4: aload 0
invokevirtual java.nio.ByteBuffer.position:()I
istore 5
start local 5 5: aload 0
invokevirtual java.nio.ByteBuffer.limit:()I
istore 6
start local 6 6: iload 6
iload 5
isub
istore 7
start local 7 7: getstatic jdk.internal.foreign.AbstractMemorySegmentImpl.nioAccess:Ljdk/internal/access/JavaNioAccess;
aload 0
invokeinterface jdk.internal.access.JavaNioAccess.bufferSegment:(Ljava/nio/Buffer;)Ljdk/internal/access/foreign/MemorySegmentProxy;
checkcast jdk.internal.foreign.AbstractMemorySegmentImpl
astore 8
start local 8 8: aload 8
ifnull 12
9: aload 8
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.scope:Ljdk/internal/foreign/MemoryScope;
astore 9
start local 9 10: aload 8
getfield jdk.internal.foreign.AbstractMemorySegmentImpl.mask:I
istore 10
start local 10 11: goto 14
end local 10 end local 9 12: StackMap locals: java.nio.ByteBuffer long java.lang.Object jdk.internal.access.foreign.UnmapperProxy int int int jdk.internal.foreign.AbstractMemorySegmentImpl
StackMap stack:
aload 0
getstatic jdk.internal.foreign.MemoryScope.DUMMY_CLEANUP_ACTION:Ljava/lang/Runnable;
aconst_null
invokestatic jdk.internal.foreign.MemoryScope.createConfined:(Ljava/lang/Object;Ljava/lang/Runnable;Ljava/lang/ref/Cleaner;)Ljdk/internal/foreign/MemoryScope;
astore 9
start local 9 13: iload 7
i2l
invokestatic jdk.internal.foreign.AbstractMemorySegmentImpl.defaultAccessModes:(J)I
istore 10
start local 10 14: StackMap locals: jdk.internal.foreign.MemoryScope int
StackMap stack:
aload 0
invokevirtual java.nio.ByteBuffer.isReadOnly:()Z
ifeq 16
15: iload 10
bipush -3
iand
istore 10
16: StackMap locals:
StackMap stack:
aload 3
ifnull 18
17: new jdk.internal.foreign.HeapMemorySegmentImpl$OfByte
dup
lload 1
iload 5
i2l
ladd
aload 3
checkcast byte[]
iload 7
i2l
iload 10
aload 9
invokespecial jdk.internal.foreign.HeapMemorySegmentImpl$OfByte.<init>:(J[BJILjdk/internal/foreign/MemoryScope;)V
areturn
18: StackMap locals:
StackMap stack:
aload 4
ifnonnull 20
19: new jdk.internal.foreign.NativeMemorySegmentImpl
dup
lload 1
iload 5
i2l
ladd
iload 7
i2l
iload 10
aload 9
invokespecial jdk.internal.foreign.NativeMemorySegmentImpl.<init>:(JJILjdk/internal/foreign/MemoryScope;)V
areturn
20: StackMap locals:
StackMap stack:
new jdk.internal.foreign.MappedMemorySegmentImpl
dup
lload 1
iload 5
i2l
ladd
aload 4
iload 7
i2l
iload 10
aload 9
invokespecial jdk.internal.foreign.MappedMemorySegmentImpl.<init>:(JLjdk/internal/access/foreign/UnmapperProxy;JILjdk/internal/foreign/MemoryScope;)V
areturn
end local 10 end local 9 end local 8 end local 7 end local 6 end local 5 end local 4 end local 3 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 21 0 bb Ljava/nio/ByteBuffer;
2 21 1 bbAddress J
3 21 3 base Ljava/lang/Object;
4 21 4 unmapper Ljdk/internal/access/foreign/UnmapperProxy;
5 21 5 pos I
6 21 6 limit I
7 21 7 size I
8 21 8 bufferSegment Ljdk/internal/foreign/AbstractMemorySegmentImpl;
10 12 9 bufferScope Ljdk/internal/foreign/MemoryScope;
13 21 9 bufferScope Ljdk/internal/foreign/MemoryScope;
11 12 10 modes I
14 21 10 modes I
MethodParameters:
Name Flags
bb
public jdk.incubator.foreign.MemorySegment withAccessModes(int);
descriptor: (I)Ljdk/incubator/foreign/MemorySegment;
flags: (0x1041) ACC_PUBLIC, ACC_BRIDGE, ACC_SYNTHETIC
Code:
stack=2, locals=2, args_size=2
0: aload 0
iload 1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.withAccessModes:(I)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
LocalVariableTable:
Start End Slot Name Signature
public jdk.internal.misc.ScopedMemoryAccess$Scope scope();
descriptor: ()Ljdk/internal/misc/ScopedMemoryAccess$Scope;
flags: (0x1041) ACC_PUBLIC, ACC_BRIDGE, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: aload 0
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.scope:()Ljdk/internal/foreign/MemoryScope;
areturn
LocalVariableTable:
Start End Slot Name Signature
public jdk.incubator.foreign.MemorySegment asSlice(long);
descriptor: (J)Ljdk/incubator/foreign/MemorySegment;
flags: (0x1041) ACC_PUBLIC, ACC_BRIDGE, ACC_SYNTHETIC
Code:
stack=3, locals=3, args_size=2
0: aload 0
lload 1
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.asSlice:(J)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
LocalVariableTable:
Start End Slot Name Signature
public jdk.incubator.foreign.MemorySegment asSlice(long, long);
descriptor: (JJ)Ljdk/incubator/foreign/MemorySegment;
flags: (0x1041) ACC_PUBLIC, ACC_BRIDGE, ACC_SYNTHETIC
Code:
stack=5, locals=5, args_size=3
0: aload 0
lload 1
lload 3
invokevirtual jdk.internal.foreign.AbstractMemorySegmentImpl.asSlice:(JJ)Ljdk/internal/foreign/AbstractMemorySegmentImpl;
areturn
LocalVariableTable:
Start End Slot Name Signature
private static byte[] lambda$0(int);
descriptor: (I)[B
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 8
areturn
LocalVariableTable:
Start End Slot Name Signature
private static short[] lambda$2(int);
descriptor: (I)[S
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 9
areturn
LocalVariableTable:
Start End Slot Name Signature
private static char[] lambda$4(int);
descriptor: (I)[C
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 5
areturn
LocalVariableTable:
Start End Slot Name Signature
private static int[] lambda$6(int);
descriptor: (I)[I
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 10
areturn
LocalVariableTable:
Start End Slot Name Signature
private static float[] lambda$8(int);
descriptor: (I)[F
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 6
areturn
LocalVariableTable:
Start End Slot Name Signature
private static long[] lambda$10(int);
descriptor: (I)[J
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 11
areturn
LocalVariableTable:
Start End Slot Name Signature
private static double[] lambda$12(int);
descriptor: (I)[D
flags: (0x100a) ACC_PRIVATE, ACC_STATIC, ACC_SYNTHETIC
Code:
stack=1, locals=1, args_size=1
0: iload 0
newarray 7
areturn
LocalVariableTable:
Start End Slot Name Signature
}
SourceFile: "AbstractMemorySegmentImpl.java"
NestMembers:
jdk.internal.foreign.AbstractMemorySegmentImpl$SegmentSplitter
InnerClasses:
public final Lookup = java.lang.invoke.MethodHandles$Lookup of java.lang.invoke.MethodHandles
SegmentSplitter = jdk.internal.foreign.AbstractMemorySegmentImpl$SegmentSplitter of jdk.internal.foreign.AbstractMemorySegmentImpl
public OfByte = jdk.internal.foreign.HeapMemorySegmentImpl$OfByte of jdk.internal.foreign.HeapMemorySegmentImpl
public abstract Scope = jdk.internal.misc.ScopedMemoryAccess$Scope of jdk.internal.misc.ScopedMemoryAccess
public final ScopedAccessError = jdk.internal.misc.ScopedMemoryAccess$Scope$ScopedAccessError of jdk.internal.misc.ScopedMemoryAccess$Scope