public class org.jruby.ext.ffi.Struct extends org.jruby.ext.ffi.MemoryObject implements org.jruby.ext.ffi.StructLayout$Storage
minor version: 0
major version: 59
flags: flags: (0x0021) ACC_PUBLIC, ACC_SUPER
this_class: org.jruby.ext.ffi.Struct
super_class: org.jruby.ext.ffi.MemoryObject
{
private org.jruby.ext.ffi.StructLayout layout;
descriptor: Lorg/jruby/ext/ffi/StructLayout;
flags: (0x0002) ACC_PRIVATE
private org.jruby.ext.ffi.AbstractMemory memory;
descriptor: Lorg/jruby/ext/ffi/AbstractMemory;
flags: (0x0002) ACC_PRIVATE
private volatile java.lang.Object[] referenceCache;
descriptor: [Ljava/lang/Object;
flags: (0x0042) ACC_PRIVATE, ACC_VOLATILE
private volatile org.jruby.runtime.builtin.IRubyObject[] valueCache;
descriptor: [Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0042) ACC_PRIVATE, ACC_VOLATILE
private static final java.util.concurrent.atomic.AtomicReferenceFieldUpdater<org.jruby.ext.ffi.Struct, org.jruby.runtime.builtin.IRubyObject[]> valueCacheUpdater;
descriptor: Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater<Lorg/jruby/ext/ffi/Struct;[Lorg/jruby/runtime/builtin/IRubyObject;>;
private static final java.util.concurrent.atomic.AtomicReferenceFieldUpdater<org.jruby.ext.ffi.Struct, java.lang.Object[]> referenceCacheUpdater;
descriptor: Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Signature: Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater<Lorg/jruby/ext/ffi/Struct;[Ljava/lang/Object;>;
static void <clinit>();
descriptor: ()V
flags: (0x0008) ACC_STATIC
Code:
stack=3, locals=0, args_size=0
0: ldc Lorg/jruby/ext/ffi/Struct;
ldc [Lorg/jruby/runtime/builtin/IRubyObject;
ldc "valueCache"
invokestatic java.util.concurrent.atomic.AtomicReferenceFieldUpdater.newUpdater:(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
1: putstatic org.jruby.ext.ffi.Struct.valueCacheUpdater:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
2: ldc Lorg/jruby/ext/ffi/Struct;
ldc [Ljava/lang/Object;
ldc "referenceCache"
invokestatic java.util.concurrent.atomic.AtomicReferenceFieldUpdater.newUpdater:(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
3: putstatic org.jruby.ext.ffi.Struct.referenceCacheUpdater:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
4: return
LocalVariableTable:
Start End Slot Name Signature
public static org.jruby.RubyClass createStructClass(org.jruby.Ruby, org.jruby.RubyModule);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/RubyModule;)Lorg/jruby/RubyClass;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=6, locals=3, args_size=2
start local 0 start local 1 0: aload 0
ldc "Struct"
aload 0
invokevirtual org.jruby.Ruby.getObject:()Lorg/jruby/RubyClass;
1: getstatic org.jruby.util.cli.Options.REIFY_FFI:Lcom/headius/options/Option;
invokevirtual com.headius.options.Option.load:()Ljava/lang/Object;
checkcast java.lang.Boolean
invokevirtual java.lang.Boolean.booleanValue:()Z
ifeq 2
new org.jruby.ext.ffi.ReifyingAllocator
dup
ldc Lorg/jruby/ext/ffi/Struct;
invokespecial org.jruby.ext.ffi.ReifyingAllocator.<init>:(Ljava/lang/Class;)V
goto 3
StackMap locals: org.jruby.Ruby org.jruby.RubyModule
StackMap stack: org.jruby.Ruby java.lang.String org.jruby.RubyClass
2: getstatic org.jruby.ext.ffi.Struct$Allocator.INSTANCE:Lorg/jruby/runtime/ObjectAllocator;
StackMap locals: org.jruby.Ruby org.jruby.RubyModule
StackMap stack: org.jruby.Ruby java.lang.String org.jruby.RubyClass org.jruby.runtime.ObjectAllocator
3: aload 1
4: invokevirtual org.jruby.Ruby.defineClassUnder:(Ljava/lang/String;Lorg/jruby/RubyClass;Lorg/jruby/runtime/ObjectAllocator;Lorg/jruby/RubyModule;)Lorg/jruby/RubyClass;
astore 2
start local 2 5: aload 2
ldc Lorg/jruby/ext/ffi/Struct;
invokevirtual org.jruby.RubyClass.defineAnnotatedMethods:(Ljava/lang/Class;)V
6: aload 2
ldc Lorg/jruby/ext/ffi/Struct;
invokevirtual org.jruby.RubyClass.defineAnnotatedConstants:(Ljava/lang/Class;)V
7: aload 2
ldc Lorg/jruby/ext/ffi/Struct;
invokevirtual org.jruby.RubyClass.setReifiedClass:(Ljava/lang/Class;)V
8: aload 2
new org.jruby.ext.ffi.Struct$1
dup
invokespecial org.jruby.ext.ffi.Struct$1.<init>:()V
putfield org.jruby.RubyClass.kindOf:Lorg/jruby/RubyModule$KindOf;
9: aload 2
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 runtime Lorg/jruby/Ruby;
0 10 1 module Lorg/jruby/RubyModule;
5 10 2 structClass Lorg/jruby/RubyClass;
MethodParameters:
Name Flags
runtime
module
void <init>(org.jruby.Ruby);
descriptor: (Lorg/jruby/Ruby;)V
flags: (0x0000)
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
aload 1
invokevirtual org.jruby.Ruby.getFFI:()Lorg/jruby/ext/ffi/FFI;
getfield org.jruby.ext.ffi.FFI.structClass:Lorg/jruby/RubyClass;
invokespecial org.jruby.ext.ffi.Struct.<init>:(Lorg/jruby/Ruby;Lorg/jruby/RubyClass;)V
1: return
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 runtime Lorg/jruby/Ruby;
MethodParameters:
Name Flags
runtime
public void <init>(org.jruby.Ruby, org.jruby.RubyClass);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/RubyClass;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
aload 2
aload 1
aload 2
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
aconst_null
invokespecial org.jruby.ext.ffi.Struct.<init>:(Lorg/jruby/Ruby;Lorg/jruby/RubyClass;Lorg/jruby/ext/ffi/StructLayout;Lorg/jruby/runtime/builtin/IRubyObject;)V
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 runtime Lorg/jruby/Ruby;
0 2 2 klass Lorg/jruby/RubyClass;
MethodParameters:
Name Flags
runtime
klass
void <init>(org.jruby.Ruby, org.jruby.RubyClass, org.jruby.ext.ffi.StructLayout, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/RubyClass;Lorg/jruby/ext/ffi/StructLayout;Lorg/jruby/runtime/builtin/IRubyObject;)V
flags: (0x0000)
Code:
stack=4, locals=5, args_size=5
start local 0 start local 1 start local 2 start local 3 start local 4 0: aload 0
aload 1
aload 2
invokespecial org.jruby.ext.ffi.MemoryObject.<init>:(Lorg/jruby/Ruby;Lorg/jruby/RubyClass;)V
1: aload 0
aload 3
putfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
2: aload 4
ifnull 6
aload 4
instanceof org.jruby.ext.ffi.AbstractMemory
ifne 6
3: aload 1
new java.lang.StringBuilder
dup
ldc "wrong argument type "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
4: aload 4
invokeinterface org.jruby.runtime.builtin.IRubyObject.getMetaClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " (expected Pointer or Buffer)"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
5: invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
6: StackMap locals: org.jruby.ext.ffi.Struct org.jruby.Ruby org.jruby.RubyClass org.jruby.ext.ffi.StructLayout org.jruby.runtime.builtin.IRubyObject
StackMap stack:
aload 0
aload 4
checkcast org.jruby.ext.ffi.AbstractMemory
putfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
7: return
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 8 0 this Lorg/jruby/ext/ffi/Struct;
0 8 1 runtime Lorg/jruby/Ruby;
0 8 2 klass Lorg/jruby/RubyClass;
0 8 3 layout Lorg/jruby/ext/ffi/StructLayout;
0 8 4 memory Lorg/jruby/runtime/builtin/IRubyObject;
MethodParameters:
Name Flags
runtime
klass
layout
memory
static final boolean isStruct(org.jruby.Ruby, org.jruby.RubyClass);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/RubyClass;)Z
flags: (0x0018) ACC_STATIC, ACC_FINAL
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 1
aload 0
invokevirtual org.jruby.Ruby.getFFI:()Lorg/jruby/ext/ffi/FFI;
getfield org.jruby.ext.ffi.FFI.structClass:Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.isKindOfModule:(Lorg/jruby/RubyModule;)Z
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 runtime Lorg/jruby/Ruby;
0 1 1 klass Lorg/jruby/RubyClass;
MethodParameters:
Name Flags
runtime
klass
static final int getStructSize(org.jruby.Ruby, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)I
flags: (0x0018) ACC_STATIC, ACC_FINAL
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
ireturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 runtime Lorg/jruby/Ruby;
0 1 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
MethodParameters:
Name Flags
runtime
structClass
static final org.jruby.ext.ffi.StructLayout getStructLayout(org.jruby.Ruby, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
flags: (0x0018) ACC_STATIC, ACC_FINAL
Code:
stack=4, locals=4, args_size=2
start local 0 start local 1 0: aload 1
checkcast org.jruby.RubyClass
invokevirtual org.jruby.RubyClass.getFFIHandle:()Ljava/lang/Object;
astore 2
start local 2 1: aload 2
instanceof org.jruby.ext.ffi.StructLayout
ifeq 4
2: aload 2
checkcast org.jruby.ext.ffi.StructLayout
3: areturn
4: StackMap locals: java.lang.Object
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
astore 3
start local 3 5: goto 7
6: StackMap locals: org.jruby.RubyClass
StackMap stack:
aload 3
invokevirtual org.jruby.RubyClass.getSuperClass:()Lorg/jruby/RubyClass;
astore 3
7: StackMap locals:
StackMap stack:
aload 3
aload 0
invokevirtual org.jruby.Ruby.getObject:()Lorg/jruby/RubyClass;
if_acmpeq 8
aload 3
ldc "@layout"
invokevirtual org.jruby.RubyClass.getInstanceVariable:(Ljava/lang/String;)Lorg/jruby/runtime/builtin/IRubyObject;
dup
astore 2
instanceof org.jruby.ext.ffi.StructLayout
ifeq 6
8: StackMap locals:
StackMap stack:
aload 2
instanceof org.jruby.ext.ffi.StructLayout
ifne 10
9: aload 0
new java.lang.StringBuilder
dup
ldc "no valid struct layout for "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 1
checkcast org.jruby.RubyClass
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual org.jruby.Ruby.newRuntimeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
10: StackMap locals:
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
aload 2
invokevirtual org.jruby.RubyClass.setFFIHandle:(Ljava/lang/Object;)V
11: aload 2
checkcast org.jruby.ext.ffi.StructLayout
12: areturn
end local 3 end local 2 13: StackMap locals: org.jruby.Ruby org.jruby.runtime.builtin.IRubyObject
StackMap stack: java.lang.ClassCastException
pop
14: aload 1
instanceof org.jruby.RubyClass
ifne 18
15: aload 0
new java.lang.StringBuilder
dup
ldc "wrong argument type "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
16: aload 1
invokeinterface org.jruby.runtime.builtin.IRubyObject.getMetaClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " (expected subclass of Struct)"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
17: invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
18: StackMap locals:
StackMap stack:
aload 0
new java.lang.StringBuilder
dup
ldc "invalid layout set for struct "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
aload 1
checkcast org.jruby.RubyClass
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
invokevirtual org.jruby.Ruby.newRuntimeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 19 0 runtime Lorg/jruby/Ruby;
0 19 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
1 13 2 layout Ljava/lang/Object;
5 13 3 klass Lorg/jruby/RubyClass;
Exception table:
from to target type
0 3 13 Class java.lang.ClassCastException
4 12 13 Class java.lang.ClassCastException
MethodParameters:
Name Flags
runtime
structClass
public org.jruby.runtime.builtin.IRubyObject initialize(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
iconst_1
iconst_1
invokestatic org.jruby.ext.ffi.MemoryPointer.allocate:(Lorg/jruby/Ruby;IIZ)Lorg/jruby/ext/ffi/MemoryPointer;
putfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
1: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"initialize"}, visibility = org.jruby.runtime.Visibility.PRIVATE:Lorg/jruby/runtime/Visibility;)
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject initialize(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 2
instanceof org.jruby.ext.ffi.AbstractMemory
ifne 6
1: aload 2
invokeinterface org.jruby.runtime.builtin.IRubyObject.isNil:()Z
ifeq 3
2: aload 0
aload 1
invokevirtual org.jruby.ext.ffi.Struct.initialize:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
3: StackMap locals:
StackMap stack:
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
new java.lang.StringBuilder
dup
ldc "wrong argument type "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
4: aload 2
invokeinterface org.jruby.runtime.builtin.IRubyObject.getMetaClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
ldc " (expected Pointer or Buffer)"
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
5: invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
6: StackMap locals:
StackMap stack:
aload 2
checkcast org.jruby.ext.ffi.AbstractMemory
invokevirtual org.jruby.ext.ffi.AbstractMemory.getSize:()J
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
i2l
lcmp
ifge 10
7: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
new java.lang.StringBuilder
dup
ldc "memory object has insufficient space for "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
8: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMetaClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.RubyClass.getName:()Ljava/lang/String;
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
9: invokevirtual org.jruby.Ruby.newArgumentError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
10: StackMap locals:
StackMap stack:
aload 0
aload 2
checkcast org.jruby.ext.ffi.AbstractMemory
putfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
11: aload 0
aload 0
getfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.AbstractMemory.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
invokevirtual org.jruby.ext.ffi.Struct.setMemoryIO:(Lorg/jruby/ext/ffi/MemoryIO;)Lorg/jruby/ext/ffi/MemoryIO;
pop
12: aload 0
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 13 0 this Lorg/jruby/ext/ffi/Struct;
0 13 1 context Lorg/jruby/runtime/ThreadContext;
0 13 2 ptr Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"initialize"}, visibility = org.jruby.runtime.Visibility.PRIVATE:Lorg/jruby/runtime/Visibility;)
MethodParameters:
Name Flags
context
ptr
public org.jruby.runtime.builtin.IRubyObject initialize(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject[]);
descriptor: (Lorg/jruby/runtime/ThreadContext;[Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 2
arraylength
tableswitch { // 0 - 1
0: 9
1: 8
default: 1
}
1: StackMap locals:
StackMap stack:
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMetaClass:()Lorg/jruby/RubyClass;
aload 1
ldc "layout"
aload 2
iconst_1
aaload
instanceof org.jruby.RubyArray
ifeq 3
2: aload 2
iconst_1
aaload
checkcast org.jruby.RubyArray
invokevirtual org.jruby.RubyArray.toJavaArrayUnsafe:()[Lorg/jruby/runtime/builtin/IRubyObject;
goto 4
3: StackMap locals: org.jruby.ext.ffi.Struct org.jruby.runtime.ThreadContext org.jruby.runtime.builtin.IRubyObject[]
StackMap stack: org.jruby.RubyClass org.jruby.runtime.ThreadContext java.lang.String
aload 2
iconst_1
aload 2
arraylength
invokestatic java.util.Arrays.copyOfRange:([Ljava/lang/Object;II)[Ljava/lang/Object;
checkcast org.jruby.runtime.builtin.IRubyObject[]
4: StackMap locals: org.jruby.ext.ffi.Struct org.jruby.runtime.ThreadContext org.jruby.runtime.builtin.IRubyObject[]
StackMap stack: org.jruby.RubyClass org.jruby.runtime.ThreadContext java.lang.String org.jruby.runtime.builtin.IRubyObject[]
invokevirtual org.jruby.RubyClass.callMethod:(Lorg/jruby/runtime/ThreadContext;Ljava/lang/String;[Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
astore 3
start local 3 5: aload 3
instanceof org.jruby.ext.ffi.StructLayout
ifne 7
6: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
ldc "Struct.layout did not return a FFI::StructLayout instance"
invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
7: StackMap locals: org.jruby.runtime.builtin.IRubyObject
StackMap stack:
aload 0
aload 3
checkcast org.jruby.ext.ffi.StructLayout
putfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
end local 3 8: StackMap locals:
StackMap stack:
aload 0
aload 1
aload 2
iconst_0
aaload
invokevirtual org.jruby.ext.ffi.Struct.initialize:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
9: StackMap locals:
StackMap stack:
aload 0
aload 1
invokevirtual org.jruby.ext.ffi.Struct.initialize:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 this Lorg/jruby/ext/ffi/Struct;
0 10 1 context Lorg/jruby/runtime/ThreadContext;
0 10 2 args [Lorg/jruby/runtime/builtin/IRubyObject;
5 8 3 result Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"initialize"}, visibility = org.jruby.runtime.Visibility.PRIVATE:Lorg/jruby/runtime/Visibility;, rest = true)
MethodParameters:
Name Flags
context
args
public org.jruby.runtime.builtin.IRubyObject initialize_copy(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=7, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 2
aload 0
if_acmpne 2
1: aload 0
areturn
2: StackMap locals:
StackMap stack:
aload 2
instanceof org.jruby.ext.ffi.Struct
ifne 4
3: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
ldc "not an instance of Struct"
invokevirtual org.jruby.Ruby.newTypeError:(Ljava/lang/String;)Lorg/jruby/exceptions/RaiseException;
athrow
4: StackMap locals:
StackMap stack:
aload 2
checkcast org.jruby.ext.ffi.Struct
astore 3
start local 3 5: aload 0
aload 3
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
lconst_0
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
i2l
invokevirtual org.jruby.ext.ffi.AbstractMemory.slice:(Lorg/jruby/Ruby;JJ)Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.AbstractMemory.dup:()Lorg/jruby/runtime/builtin/IRubyObject;
checkcast org.jruby.ext.ffi.AbstractMemory
putfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
6: aload 3
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
ifnull 9
7: aload 0
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getReferenceFieldCount:()I
anewarray java.lang.Object
putfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
8: aload 3
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
iconst_0
aload 0
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
iconst_0
aload 0
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
arraylength
invokestatic java.lang.System.arraycopy:(Ljava/lang/Object;ILjava/lang/Object;II)V
9: StackMap locals: org.jruby.ext.ffi.Struct
StackMap stack:
aload 0
aload 0
getfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.AbstractMemory.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
invokevirtual org.jruby.ext.ffi.Struct.setMemoryIO:(Lorg/jruby/ext/ffi/MemoryIO;)Lorg/jruby/ext/ffi/MemoryIO;
pop
10: aload 0
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 11 0 this Lorg/jruby/ext/ffi/Struct;
0 11 1 context Lorg/jruby/runtime/ThreadContext;
0 11 2 other Lorg/jruby/runtime/builtin/IRubyObject;
5 11 3 orig Lorg/jruby/ext/ffi/Struct;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"initialize_copy"}, visibility = org.jruby.runtime.Visibility.PRIVATE:Lorg/jruby/runtime/Visibility;)
MethodParameters:
Name Flags
context
other
private static final org.jruby.ext.ffi.Struct allocateStruct(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, int);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
flags: (0x001a) ACC_PRIVATE, ACC_STATIC, ACC_FINAL
Code:
stack=10, locals=5, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
astore 3
start local 3 1: aload 3
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
astore 4
start local 4 2: new org.jruby.ext.ffi.Struct
dup
aload 3
aload 1
checkcast org.jruby.RubyClass
aload 4
new org.jruby.ext.ffi.Buffer
dup
aload 3
aload 4
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
iload 2
invokespecial org.jruby.ext.ffi.Buffer.<init>:(Lorg/jruby/Ruby;II)V
invokespecial org.jruby.ext.ffi.Struct.<init>:(Lorg/jruby/Ruby;Lorg/jruby/RubyClass;Lorg/jruby/ext/ffi/StructLayout;Lorg/jruby/runtime/builtin/IRubyObject;)V
areturn
end local 4 end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 context Lorg/jruby/runtime/ThreadContext;
0 3 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
0 3 2 flags I
1 3 3 runtime Lorg/jruby/Ruby;
2 3 4 layout Lorg/jruby/ext/ffi/StructLayout;
MethodParameters:
Name Flags
context
klass
flags
public static org.jruby.runtime.builtin.IRubyObject allocateIn(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
iconst_1
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_in", "alloc_in"}, meta = true)
MethodParameters:
Name Flags
context
klass
public static org.jruby.runtime.builtin.IRubyObject allocateIn(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
iconst_1
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
0 1 2 clearArg Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_in", "alloc_in"}, meta = true)
MethodParameters:
Name Flags
context
klass
clearArg
public static org.jruby.runtime.builtin.IRubyObject allocateOut(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
iconst_2
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_out", "alloc_out"}, meta = true)
MethodParameters:
Name Flags
context
klass
public static org.jruby.runtime.builtin.IRubyObject allocateOut(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
iconst_2
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
0 1 2 clearArg Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_out", "alloc_out"}, meta = true)
MethodParameters:
Name Flags
context
klass
clearArg
public static org.jruby.runtime.builtin.IRubyObject allocateInOut(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
aload 1
iconst_3
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_inout", "alloc_inout"}, meta = true)
MethodParameters:
Name Flags
context
klass
public static org.jruby.runtime.builtin.IRubyObject allocateInOut(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
aload 1
iconst_3
invokestatic org.jruby.ext.ffi.Struct.allocateStruct:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;I)Lorg/jruby/ext/ffi/Struct;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 klass Lorg/jruby/runtime/builtin/IRubyObject;
0 1 2 clearArg Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"new_inout", "alloc_inout"}, meta = true)
MethodParameters:
Name Flags
context
klass
clearArg
public static org.jruby.runtime.builtin.IRubyObject size(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=4, args_size=2
start local 0 start local 1 0: aload 1
instanceof org.jruby.RubyClass
ifne 2
1: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
invokevirtual org.jruby.Ruby.getClassClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.Ruby.newTypeError:(Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/RubyClass;)Lorg/jruby/exceptions/RaiseException;
athrow
2: StackMap locals:
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
astore 2
start local 2 3: aload 2
invokevirtual org.jruby.RubyClass.getFFIHandle:()Ljava/lang/Object;
astore 3
start local 3 4: aload 3
instanceof org.jruby.ext.ffi.StructLayout
ifeq 6
5: aload 3
checkcast org.jruby.ext.ffi.StructLayout
aload 0
invokevirtual org.jruby.ext.ffi.StructLayout.size:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
6: StackMap locals: org.jruby.RubyClass java.lang.Object
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
ldc "@layout"
invokevirtual org.jruby.RubyClass.getInstanceVariable:(Ljava/lang/String;)Lorg/jruby/runtime/builtin/IRubyObject;
dup
astore 3
instanceof org.jruby.ext.ffi.StructLayout
ifeq 8
7: aload 3
checkcast org.jruby.ext.ffi.StructLayout
aload 0
invokevirtual org.jruby.ext.ffi.StructLayout.size:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
8: StackMap locals:
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
ldc "@size"
invokevirtual org.jruby.RubyClass.getInstanceVariable:(Ljava/lang/String;)Lorg/jruby/runtime/builtin/IRubyObject;
astore 3
9: aload 3
instanceof org.jruby.RubyFixnum
ifeq 10
aload 3
checkcast org.jruby.RubyFixnum
goto 11
StackMap locals:
StackMap stack:
10: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
invokestatic org.jruby.RubyFixnum.zero:(Lorg/jruby/Ruby;)Lorg/jruby/RubyFixnum;
StackMap locals:
StackMap stack: org.jruby.RubyFixnum
11: areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 12 0 context Lorg/jruby/runtime/ThreadContext;
0 12 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
3 12 2 klass Lorg/jruby/RubyClass;
4 12 3 obj Ljava/lang/Object;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"size"}, meta = true)
MethodParameters:
Name Flags
context
structClass
public static org.jruby.runtime.builtin.IRubyObject alignment(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
aload 0
invokevirtual org.jruby.ext.ffi.StructLayout.alignment:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"alignment", "align"}, meta = true)
MethodParameters:
Name Flags
context
structClass
public static org.jruby.runtime.builtin.IRubyObject set_layout(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=4, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 1
instanceof org.jruby.RubyClass
ifne 2
1: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
invokevirtual org.jruby.Ruby.getClassClass:()Lorg/jruby/RubyClass;
invokevirtual org.jruby.Ruby.newTypeError:(Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/RubyClass;)Lorg/jruby/exceptions/RaiseException;
athrow
2: StackMap locals:
StackMap stack:
aload 2
instanceof org.jruby.ext.ffi.StructLayout
ifne 6
3: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 2
4: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
ldc "FFI"
invokevirtual org.jruby.Ruby.getModule:(Ljava/lang/String;)Lorg/jruby/RubyModule;
ldc "StructLayout"
invokevirtual org.jruby.RubyModule.getClass:(Ljava/lang/String;)Lorg/jruby/RubyClass;
5: invokevirtual org.jruby.Ruby.newTypeError:(Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/RubyClass;)Lorg/jruby/exceptions/RaiseException;
athrow
6: StackMap locals:
StackMap stack:
aload 1
checkcast org.jruby.RubyClass
astore 3
start local 3 7: aload 3
aload 2
invokevirtual org.jruby.RubyClass.setFFIHandle:(Ljava/lang/Object;)V
8: aload 3
ldc "@layout"
aload 2
invokevirtual org.jruby.RubyClass.setInstanceVariable:(Ljava/lang/String;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
pop
9: aload 1
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 10 0 context Lorg/jruby/runtime/ThreadContext;
0 10 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
0 10 2 layout Lorg/jruby/runtime/builtin/IRubyObject;
7 10 3 klass Lorg/jruby/RubyClass;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"layout="}, meta = true)
MethodParameters:
Name Flags
context
structClass
layout
public static org.jruby.runtime.builtin.IRubyObject members(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
aload 0
invokevirtual org.jruby.ext.ffi.StructLayout.members:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"members"}, meta = true)
MethodParameters:
Name Flags
context
structClass
public static org.jruby.runtime.builtin.IRubyObject offsets(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
aload 0
invokevirtual org.jruby.ext.ffi.StructLayout.offsets:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"offsets"}, meta = true)
MethodParameters:
Name Flags
context
structClass
public static org.jruby.runtime.builtin.IRubyObject offset_of(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0009) ACC_PUBLIC, ACC_STATIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 1
invokestatic org.jruby.ext.ffi.Struct.getStructLayout:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout;
aload 0
aload 2
invokevirtual org.jruby.ext.ffi.StructLayout.offset_of:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 context Lorg/jruby/runtime/ThreadContext;
0 1 1 structClass Lorg/jruby/runtime/builtin/IRubyObject;
0 1 2 fieldName Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"offset_of"}, meta = true)
MethodParameters:
Name Flags
context
structClass
fieldName
public org.jruby.runtime.builtin.IRubyObject getFieldValue(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=4, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 2
invokevirtual org.jruby.ext.ffi.StructLayout.getMember:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout$Member;
aload 1
aload 0
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.StructLayout$Member.get:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/ext/ffi/StructLayout$Storage;Lorg/jruby/ext/ffi/AbstractMemory;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
0 1 2 fieldName Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"[]"})
MethodParameters:
Name Flags
context
fieldName
public org.jruby.runtime.builtin.IRubyObject setFieldValue(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=5, locals=4, args_size=4
start local 0 start local 1 start local 2 start local 3 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 2
invokevirtual org.jruby.ext.ffi.StructLayout.getMember:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/ext/ffi/StructLayout$Member;
aload 1
aload 0
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
aload 3
invokevirtual org.jruby.ext.ffi.StructLayout$Member.put:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/ext/ffi/StructLayout$Storage;Lorg/jruby/ext/ffi/AbstractMemory;Lorg/jruby/runtime/builtin/IRubyObject;)V
1: aload 3
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 context Lorg/jruby/runtime/ThreadContext;
0 2 2 fieldName Lorg/jruby/runtime/builtin/IRubyObject;
0 2 3 fieldValue Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"[]="})
MethodParameters:
Name Flags
context
fieldName
fieldValue
public org.jruby.runtime.builtin.IRubyObject getLayout(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"cspec", "layout"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject pointer(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=1, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"pointer", "to_ptr"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject members(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.members:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"members"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject values(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=6, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getFieldCount:()I
anewarray org.jruby.runtime.builtin.IRubyObject
astore 2
start local 2 1: iconst_0
istore 3
start local 3 2: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getMembers:()Ljava/util/Collection;
invokeinterface java.util.Collection.iterator:()Ljava/util/Iterator;
astore 5
goto 5
StackMap locals: org.jruby.ext.ffi.Struct org.jruby.runtime.ThreadContext org.jruby.runtime.builtin.IRubyObject[] int top java.util.Iterator
StackMap stack:
3: aload 5
invokeinterface java.util.Iterator.next:()Ljava/lang/Object;
checkcast org.jruby.ext.ffi.StructLayout$Member
astore 4
start local 4 4: aload 2
iload 3
iinc 3 1
aload 4
aload 1
aload 0
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.StructLayout$Member.get:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/ext/ffi/StructLayout$Storage;Lorg/jruby/ext/ffi/AbstractMemory;)Lorg/jruby/runtime/builtin/IRubyObject;
aastore
end local 4 5: StackMap locals:
StackMap stack:
aload 5
invokeinterface java.util.Iterator.hasNext:()Z
ifne 3
6: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 2
invokestatic org.jruby.RubyArray.newArrayMayCopy:(Lorg/jruby/Ruby;[Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/RubyArray;
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 7 0 this Lorg/jruby/ext/ffi/Struct;
0 7 1 context Lorg/jruby/runtime/ThreadContext;
1 7 2 values [Lorg/jruby/runtime/builtin/IRubyObject;
2 7 3 i I
4 5 4 m Lorg/jruby/ext/ffi/StructLayout$Member;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"values"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject offsets(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.offsets:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"offsets"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject offset_of(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
aload 2
invokevirtual org.jruby.ext.ffi.StructLayout.offset_of:(Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
0 1 2 fieldName Lorg/jruby/runtime/builtin/IRubyObject;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"offset_of"})
MethodParameters:
Name Flags
context
fieldName
public org.jruby.runtime.builtin.IRubyObject size(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.size:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"size"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject alignment(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.alignment:(Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"alignment"})
MethodParameters:
Name Flags
context
public org.jruby.runtime.builtin.IRubyObject null_p(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 start local 1 0: aload 1
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.AbstractMemory.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
invokevirtual org.jruby.ext.ffi.MemoryIO.isNull:()Z
invokestatic org.jruby.RubyBoolean.newBoolean:(Lorg/jruby/runtime/ThreadContext;Z)Lorg/jruby/RubyBoolean;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
0 1 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"null?"})
MethodParameters:
Name Flags
context
public final org.jruby.runtime.builtin.IRubyObject order(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
invokevirtual org.jruby.ext.ffi.MemoryIO.order:()Ljava/nio/ByteOrder;
getstatic java.nio.ByteOrder.LITTLE_ENDIAN:Ljava/nio/ByteOrder;
invokevirtual java.lang.Object.equals:(Ljava/lang/Object;)Z
ifeq 1
ldc "little"
goto 2
StackMap locals:
StackMap stack: org.jruby.Ruby
1: ldc "big"
StackMap locals: org.jruby.ext.ffi.Struct org.jruby.runtime.ThreadContext
StackMap stack: org.jruby.Ruby java.lang.String
2: invokevirtual org.jruby.Ruby.newSymbol:(Ljava/lang/String;)Lorg/jruby/RubySymbol;
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jruby/ext/ffi/Struct;
0 3 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"order"}, required = 0)
MethodParameters:
Name Flags
context
public final org.jruby.runtime.builtin.IRubyObject order(org.jruby.runtime.ThreadContext, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/runtime/ThreadContext;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=8, locals=4, args_size=3
start local 0 start local 1 start local 2 0: aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 2
invokestatic org.jruby.ext.ffi.Util.parseByteOrder:(Lorg/jruby/Ruby;Lorg/jruby/runtime/builtin/IRubyObject;)Ljava/nio/ByteOrder;
astore 3
start local 3 1: new org.jruby.ext.ffi.Struct
dup
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMetaClass:()Lorg/jruby/RubyClass;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
2: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
aload 1
getfield org.jruby.runtime.ThreadContext.runtime:Lorg/jruby/Ruby;
aload 3
invokevirtual org.jruby.ext.ffi.AbstractMemory.order:(Lorg/jruby/Ruby;Ljava/nio/ByteOrder;)Lorg/jruby/ext/ffi/AbstractMemory;
3: invokespecial org.jruby.ext.ffi.Struct.<init>:(Lorg/jruby/Ruby;Lorg/jruby/RubyClass;Lorg/jruby/ext/ffi/StructLayout;Lorg/jruby/runtime/builtin/IRubyObject;)V
areturn
end local 3 end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 4 0 this Lorg/jruby/ext/ffi/Struct;
0 4 1 context Lorg/jruby/runtime/ThreadContext;
0 4 2 byte_order Lorg/jruby/runtime/builtin/IRubyObject;
1 4 3 order Ljava/nio/ByteOrder;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"order"}, required = 1)
MethodParameters:
Name Flags
context
byte_order
public org.jruby.runtime.builtin.IRubyObject clear(org.jruby.runtime.ThreadContext);
descriptor: (Lorg/jruby/runtime/ThreadContext;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=2, args_size=2
start local 0 start local 1 0: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
lconst_0
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
getfield org.jruby.ext.ffi.StructLayout.size:I
i2l
iconst_0
invokevirtual org.jruby.ext.ffi.MemoryIO.setMemory:(JJB)V
1: aload 0
areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 context Lorg/jruby/runtime/ThreadContext;
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyMethod(name = {"clear"})
MethodParameters:
Name Flags
context
public final org.jruby.ext.ffi.AbstractMemory getMemory();
descriptor: ()Lorg/jruby/ext/ffi/AbstractMemory;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=5, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
ifnull 1
aload 0
getfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
goto 2
StackMap locals:
StackMap stack:
1: aload 0
aload 0
invokevirtual org.jruby.ext.ffi.Struct.getRuntime:()Lorg/jruby/Ruby;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getSize:()I
iconst_1
iconst_1
invokestatic org.jruby.ext.ffi.MemoryPointer.allocate:(Lorg/jruby/Ruby;IIZ)Lorg/jruby/ext/ffi/MemoryPointer;
dup_x1
putfield org.jruby.ext.ffi.Struct.memory:Lorg/jruby/ext/ffi/AbstractMemory;
StackMap locals:
StackMap stack: org.jruby.ext.ffi.AbstractMemory
2: areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jruby/ext/ffi/Struct;
protected final org.jruby.ext.ffi.MemoryIO allocateMemoryIO();
descriptor: ()Lorg/jruby/ext/ffi/MemoryIO;
flags: (0x0014) ACC_PROTECTED, ACC_FINAL
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getMemory:()Lorg/jruby/ext/ffi/AbstractMemory;
invokevirtual org.jruby.ext.ffi.AbstractMemory.getMemoryIO:()Lorg/jruby/ext/ffi/MemoryIO;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 1 0 this Lorg/jruby/ext/ffi/Struct;
public final org.jruby.runtime.builtin.IRubyObject getCachedValue(org.jruby.ext.ffi.StructLayout$Member);
descriptor: (Lorg/jruby/ext/ffi/StructLayout$Member;)Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=3, locals=2, args_size=2
start local 0 start local 1 0: aload 0
getfield org.jruby.ext.ffi.Struct.valueCache:[Lorg/jruby/runtime/builtin/IRubyObject;
ifnull 1
aload 0
getfield org.jruby.ext.ffi.Struct.valueCache:[Lorg/jruby/runtime/builtin/IRubyObject;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.getCacheableFieldIndex:(Lorg/jruby/ext/ffi/StructLayout$Member;)I
aaload
goto 2
StackMap locals:
StackMap stack:
1: aconst_null
StackMap locals:
StackMap stack: org.jruby.runtime.builtin.IRubyObject
2: areturn
end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jruby/ext/ffi/Struct;
0 3 1 member Lorg/jruby/ext/ffi/StructLayout$Member;
MethodParameters:
Name Flags
member
public final void putCachedValue(org.jruby.ext.ffi.StructLayout$Member, org.jruby.runtime.builtin.IRubyObject);
descriptor: (Lorg/jruby/ext/ffi/StructLayout$Member;Lorg/jruby/runtime/builtin/IRubyObject;)V
flags: (0x0011) ACC_PUBLIC, ACC_FINAL
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getValueCacheForWrite:()[Lorg/jruby/runtime/builtin/IRubyObject;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.getCacheableFieldIndex:(Lorg/jruby/ext/ffi/StructLayout$Member;)I
aload 2
aastore
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 member Lorg/jruby/ext/ffi/StructLayout$Member;
0 2 2 value Lorg/jruby/runtime/builtin/IRubyObject;
MethodParameters:
Name Flags
member
value
private org.jruby.runtime.builtin.IRubyObject[] getValueCacheForWrite();
descriptor: ()[Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0002) ACC_PRIVATE
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.ext.ffi.Struct.valueCache:[Lorg/jruby/runtime/builtin/IRubyObject;
ifnull 1
aload 0
getfield org.jruby.ext.ffi.Struct.valueCache:[Lorg/jruby/runtime/builtin/IRubyObject;
goto 2
StackMap locals:
StackMap stack:
1: aload 0
invokevirtual org.jruby.ext.ffi.Struct.initValueCache:()[Lorg/jruby/runtime/builtin/IRubyObject;
StackMap locals:
StackMap stack: org.jruby.runtime.builtin.IRubyObject[]
2: areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jruby/ext/ffi/Struct;
private org.jruby.runtime.builtin.IRubyObject[] initValueCache();
descriptor: ()[Lorg/jruby/runtime/builtin/IRubyObject;
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=1, args_size=1
start local 0 0: getstatic org.jruby.ext.ffi.Struct.valueCacheUpdater:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
aload 0
aconst_null
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getCacheableFieldCount:()I
anewarray org.jruby.runtime.builtin.IRubyObject
invokevirtual java.util.concurrent.atomic.AtomicReferenceFieldUpdater.compareAndSet:(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)Z
pop
1: aload 0
getfield org.jruby.ext.ffi.Struct.valueCache:[Lorg/jruby/runtime/builtin/IRubyObject;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
private java.lang.Object[] getReferenceCache();
descriptor: ()[Ljava/lang/Object;
flags: (0x0002) ACC_PRIVATE
Code:
stack=1, locals=1, args_size=1
start local 0 0: aload 0
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
ifnull 1
aload 0
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
goto 2
StackMap locals:
StackMap stack:
1: aload 0
invokevirtual org.jruby.ext.ffi.Struct.initReferenceCache:()[Ljava/lang/Object;
StackMap locals:
StackMap stack: java.lang.Object[]
2: areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lorg/jruby/ext/ffi/Struct;
private java.lang.Object[] initReferenceCache();
descriptor: ()[Ljava/lang/Object;
flags: (0x0002) ACC_PRIVATE
Code:
stack=4, locals=1, args_size=1
start local 0 0: getstatic org.jruby.ext.ffi.Struct.referenceCacheUpdater:Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;
aload 0
aconst_null
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
invokevirtual org.jruby.ext.ffi.StructLayout.getReferenceFieldCount:()I
anewarray java.lang.Object
invokevirtual java.util.concurrent.atomic.AtomicReferenceFieldUpdater.compareAndSet:(Ljava/lang/Object;Ljava/lang/Object;Ljava/lang/Object;)Z
pop
1: aload 0
getfield org.jruby.ext.ffi.Struct.referenceCache:[Ljava/lang/Object;
areturn
end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
public void putReference(org.jruby.ext.ffi.StructLayout$Member, java.lang.Object);
descriptor: (Lorg/jruby/ext/ffi/StructLayout$Member;Ljava/lang/Object;)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=3, locals=3, args_size=3
start local 0 start local 1 start local 2 0: aload 0
invokevirtual org.jruby.ext.ffi.Struct.getReferenceCache:()[Ljava/lang/Object;
aload 0
getfield org.jruby.ext.ffi.Struct.layout:Lorg/jruby/ext/ffi/StructLayout;
aload 1
invokevirtual org.jruby.ext.ffi.StructLayout.getReferenceFieldIndex:(Lorg/jruby/ext/ffi/StructLayout$Member;)I
aload 2
aastore
1: return
end local 2 end local 1 end local 0 LocalVariableTable:
Start End Slot Name Signature
0 2 0 this Lorg/jruby/ext/ffi/Struct;
0 2 1 member Lorg/jruby/ext/ffi/StructLayout$Member;
0 2 2 value Ljava/lang/Object;
MethodParameters:
Name Flags
member
value
}
SourceFile: "Struct.java"
NestMembers:
org.jruby.ext.ffi.Struct$1 org.jruby.ext.ffi.Struct$Allocator
InnerClasses:
org.jruby.ext.ffi.Struct$1
private final Allocator = org.jruby.ext.ffi.Struct$Allocator of org.jruby.ext.ffi.Struct
public final Member = org.jruby.ext.ffi.StructLayout$Member of org.jruby.ext.ffi.StructLayout
public abstract Storage = org.jruby.ext.ffi.StructLayout$Storage of org.jruby.ext.ffi.StructLayout
RuntimeVisibleAnnotations:
org.jruby.anno.JRubyClass(name = {"FFI::Struct"}, parent = "Object")