Home | History | Annotate | Download | only in x86
      1 %default { "isrange":"0", "routine":"NoRange" }
      2 %verify "executed"
      3 %verify "unknown method"
      4 %verify "null object"
      5     /*
      6      * Handle an interface method call.
      7      *
      8      * for: invoke-interface, invoke-interface/range
      9      */
     10     /* op vB, {vD, vE, vF, vG, vA}, class@CCCC */
     11     /* op {vCCCC..v(CCCC+AA-1)}, meth@BBBB */
     12     movzwl     4(rPC),%eax              # eax<- FEDC or CCCC
     13     movl       rSELF,%ecx
     14     .if        (!$isrange)
     15     andl       $$0xf,%eax               # eax<- C (or stays CCCC)
     16     .endif
     17     GET_VREG_R   %eax %eax              # eax<- "this"
     18     EXPORT_PC
     19     testl      %eax,%eax                # null this?
     20     je         common_errNullObject     # yes, fail
     21     movl       %eax, TMP_SPILL1(%ebp)
     22     movl       offObject_clazz(%eax),%eax# eax<- thisPtr->clazz
     23     movl       %eax,OUT_ARG0(%esp)                 # arg0<- class
     24     movl       offThread_methodClassDex(%ecx),%eax   # eax<- methodClassDex
     25     movl       offThread_method(%ecx),%ecx           # ecx<- method
     26     movl       %eax,OUT_ARG3(%esp)                 # arg3<- dex
     27     movzwl     2(rPC),%eax                         # eax<- BBBB
     28     movl       %ecx,OUT_ARG2(%esp)                 # arg2<- method
     29     movl       %eax,OUT_ARG1(%esp)                 # arg1<- BBBB
     30     call       dvmFindInterfaceMethodInCache # eax<- call(class, ref, method, dex)
     31     testl      %eax,%eax
     32     je         common_exceptionThrown
     33     movl       TMP_SPILL1(%ebp), %ecx
     34     jmp        common_invokeMethod${routine}
     35