• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1%default { "is_object":"0", "helper":"MterpGet32Static" }
2    /*
3     * General SGET handler.
4     *
5     * for: sget, sget-object, sget-boolean, sget-byte, sget-char, sget-short
6     */
7    /* op vAA, field@BBBB */
8    .extern $helper
9    EXPORT_PC()
10    FETCH(a0, 1)                           # a0 <- field ref BBBB
11    lw    a1, OFF_FP_METHOD(rFP)           # a1 <- method
12    move  a2, rSELF                        # a2 <- self
13    JAL($helper)
14    lw    a3, THREAD_EXCEPTION_OFFSET(rSELF)
15    GET_OPA(a2)                            # a2 <- AA
16    PREFETCH_INST(2)
17    bnez  a3, MterpException               # bail out
18    ADVANCE(2)
19    GET_INST_OPCODE(t0)                    # extract opcode from rINST
20.if $is_object
21    SET_VREG_OBJECT_GOTO(v0, a2, t0)       # fp[AA] <- v0
22.else
23    SET_VREG_GOTO(v0, a2, t0)              # fp[AA] <- v0
24.endif
25