Home | History | Annotate | Download | only in armv5te
      1 %default { "barrier":"@ no-op " }
      2 %verify "executed"
      3 %verify "field already resolved"
      4 %verify "field not yet resolved"
      5 %verify "field cannot be resolved"
      6     /*
      7      * General 32-bit SGET handler.
      8      *
      9      * for: sget, sget-object, sget-boolean, sget-byte, sget-char, sget-short
     10      */
     11     /* op vAA, field@BBBB */
     12     ldr     r2, [rGLUE, #offGlue_methodClassDex]    @ r2<- DvmDex
     13     FETCH(r1, 1)                        @ r1<- field ref BBBB
     14     ldr     r2, [r2, #offDvmDex_pResFields] @ r2<- dvmDex->pResFields
     15     ldr     r0, [r2, r1, lsl #2]        @ r0<- resolved StaticField ptr
     16     cmp     r0, #0                      @ is resolved entry null?
     17     beq     .L${opcode}_resolve         @ yes, do resolve
     18 .L${opcode}_finish: @ field ptr in r0
     19     ldr     r1, [r0, #offStaticField_value] @ r1<- field value
     20     $barrier                            @ acquiring load
     21     mov     r2, rINST, lsr #8           @ r2<- AA
     22     FETCH_ADVANCE_INST(2)               @ advance rPC, load rINST
     23     SET_VREG(r1, r2)                    @ fp[AA]<- r1
     24     GET_INST_OPCODE(ip)                 @ extract opcode from rINST
     25     GOTO_OPCODE(ip)                     @ jump to next instruction
     26 %break
     27 
     28     /*
     29      * Continuation if the field has not yet been resolved.
     30      *  r1: BBBB field ref
     31      */
     32 .L${opcode}_resolve:
     33     ldr     r2, [rGLUE, #offGlue_method]    @ r2<- current method
     34     EXPORT_PC()                         @ resolve() could throw, so export now
     35     ldr     r0, [r2, #offMethod_clazz]  @ r0<- method->clazz
     36     bl      dvmResolveStaticField       @ r0<- resolved StaticField ptr
     37     cmp     r0, #0                      @ success?
     38     bne     .L${opcode}_finish          @ yes, finish
     39     b       common_exceptionThrown      @ no, handle exception
     40