1%default { "is_object":"0", "helper":"artGet32InstanceFromCode"}
2/*
3 * General instance field get.
4 *
5 * for: iget, iget-object, iget-boolean, iget-byte, iget-char, iget-short
6 */
7    EXPORT_PC
8    movzwl  2(rPC), %eax                    # eax <- 0000CCCC
9    movl    %eax, OUT_ARG0(%esp)            # field ref CCCC
10    movzbl  rINSTbl, %ecx                   # ecx <- BA
11    sarl    $$4, %ecx                       # ecx <- B
12    GET_VREG %ecx, %ecx
13    movl    %ecx, OUT_ARG1(%esp)            # the object pointer
14    movl    OFF_FP_METHOD(rFP), %eax
15    movl    %eax, OUT_ARG2(%esp)            # referrer
16    mov     rSELF, %ecx
17    movl    %ecx, OUT_ARG3(%esp)            # self
18    call    SYMBOL($helper)
19    movl    rSELF, %ecx
20    RESTORE_IBASE_FROM_SELF %ecx
21    cmpl    $$0, THREAD_EXCEPTION_OFFSET(%ecx)
22    jnz     MterpException                  # bail out
23    andb    $$0xf, rINSTbl                  # rINST <- A
24    .if $is_object
25    SET_VREG_OBJECT %eax, rINST             # fp[A] <-value
26    .else
27    SET_VREG %eax, rINST                    # fp[A] <-value
28    .endif
29    ADVANCE_PC_FETCH_AND_GOTO_NEXT 2
30